[xcm-builder] Replaced deprecated CurrencyAdapter with FungibleAdapter (#3287)

I found out during the cleanup of this deprecation message in the
`polkadot-fellows` repository that we deprecated `CurrencyAdapter`
without making the recommended changes.


## TODO
- [ ] fix `polkadot-fellows` bump to 1.6.0
https://github.com/polkadot-fellows/runtimes/pull/159

---------

Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com>
This commit is contained in:
Branislav Kontur
2024-02-13 20:22:53 +01:00
committed by GitHub
parent b79bf4fb1f
commit e0c902e3df
41 changed files with 198 additions and 259 deletions
@@ -184,13 +184,13 @@ fn send_wnds_from_asset_hub_rococo_to_asset_hub_westend() {
vec![
// WND is withdrawn from AHR's SA on AHW
RuntimeEvent::Balances(
pallet_balances::Event::Withdraw { who, amount }
pallet_balances::Event::Burned { who, amount }
) => {
who: *who == sov_ahr_on_ahw,
amount: *amount == amount_to_send,
},
// WNDs deposited to beneficiary
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, .. }) => {
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, .. }) => {
who: *who == AssetHubWestendReceiver::get(),
},
// message processed successfully
@@ -68,7 +68,7 @@ pub(crate) fn assert_bridge_hub_rococo_message_accepted(expected_processed: bool
BridgeHubRococo,
vec![
// pay for bridge fees
RuntimeEvent::Balances(pallet_balances::Event::Withdraw { .. }) => {},
RuntimeEvent::Balances(pallet_balances::Event::Burned { .. }) => {},
// message exported
RuntimeEvent::BridgeWestendMessages(
pallet_bridge_messages::Event::MessageAccepted { .. }
@@ -478,7 +478,7 @@ fn send_weth_asset_from_asset_hub_to_ethereum() {
assert!(
events.iter().any(|event| matches!(
event,
RuntimeEvent::Balances(pallet_balances::Event::Deposit{ who, amount })
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, amount })
if *who == TREASURY_ACCOUNT.into() && *amount == 16903333
)),
"Snowbridge sovereign takes local fee."
@@ -487,7 +487,7 @@ fn send_weth_asset_from_asset_hub_to_ethereum() {
assert!(
events.iter().any(|event| matches!(
event,
RuntimeEvent::Balances(pallet_balances::Event::Deposit{ who, amount })
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, amount })
if *who == assethub_sovereign && *amount == 2680000000000,
)),
"AssetHub sovereign takes remote fee."
@@ -182,13 +182,13 @@ fn send_rocs_from_asset_hub_westend_to_asset_hub_rococo() {
vec![
// ROC is withdrawn from AHW's SA on AHR
RuntimeEvent::Balances(
pallet_balances::Event::Withdraw { who, amount }
pallet_balances::Event::Burned { who, amount }
) => {
who: *who == sov_ahw_on_ahr,
amount: *amount == amount_to_send,
},
// ROCs deposited to beneficiary
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, .. }) => {
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, .. }) => {
who: *who == AssetHubRococoReceiver::get(),
},
// message processed successfully
@@ -67,7 +67,7 @@ pub(crate) fn assert_bridge_hub_westend_message_accepted(expected_processed: boo
BridgeHubWestend,
vec![
// pay for bridge fees
RuntimeEvent::Balances(pallet_balances::Event::Withdraw { .. }) => {},
RuntimeEvent::Balances(pallet_balances::Event::Burned { .. }) => {},
// message exported
RuntimeEvent::BridgeRococoMessages(
pallet_bridge_messages::Event::MessageAccepted { .. }