mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 21:01:02 +00:00
[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:
+9
-9
@@ -70,7 +70,7 @@ fn para_receiver_assertions<Test>(_: Test) {
|
||||
assert_expected_events!(
|
||||
PenpalB,
|
||||
vec![
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { .. }) => {},
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { .. }) => {},
|
||||
RuntimeEvent::MessageQueue(
|
||||
pallet_message_queue::Event::Processed { success: true, .. }
|
||||
) => {},
|
||||
@@ -88,7 +88,7 @@ fn para_to_system_para_sender_assertions(t: ParaToSystemParaTest) {
|
||||
vec![
|
||||
// Amount to reserve transfer is transferred to Parachain's Sovereign account
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Withdraw { who, amount }
|
||||
pallet_balances::Event::Burned { who, amount }
|
||||
) => {
|
||||
who: *who == t.sender.account_id,
|
||||
amount: *amount == t.args.amount,
|
||||
@@ -109,12 +109,12 @@ fn para_to_system_para_receiver_assertions(t: ParaToSystemParaTest) {
|
||||
vec![
|
||||
// Amount to reserve transfer is transferred to Parachain's Sovereign account
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Withdraw { who, amount }
|
||||
pallet_balances::Event::Burned { who, amount }
|
||||
) => {
|
||||
who: *who == sov_penpal_on_ahw.clone().into(),
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { .. }) => {},
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { .. }) => {},
|
||||
RuntimeEvent::MessageQueue(
|
||||
pallet_message_queue::Event::Processed { success: true, .. }
|
||||
) => {},
|
||||
@@ -153,7 +153,7 @@ fn system_para_to_para_assets_receiver_assertions<Test>(_: Test) {
|
||||
assert_expected_events!(
|
||||
PenpalB,
|
||||
vec![
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { .. }) => {},
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { .. }) => {},
|
||||
RuntimeEvent::Assets(pallet_assets::Event::Issued { .. }) => {},
|
||||
RuntimeEvent::MessageQueue(
|
||||
pallet_message_queue::Event::Processed { success: true, .. }
|
||||
@@ -170,7 +170,7 @@ fn para_to_para_sender_assertions(t: ParaToParaTest) {
|
||||
vec![
|
||||
// Amount to reserve transfer is transferred to Parachain's Sovereign account
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Withdraw { who, amount }
|
||||
pallet_balances::Event::Burned { who, amount }
|
||||
) => {
|
||||
who: *who == t.sender.account_id,
|
||||
amount: *amount == t.args.amount,
|
||||
@@ -194,14 +194,14 @@ fn para_to_para_relay_hop_assertions(t: ParaToParaTest) {
|
||||
vec![
|
||||
// Withdrawn from sender parachain SA
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Withdraw { who, amount }
|
||||
pallet_balances::Event::Burned { who, amount }
|
||||
) => {
|
||||
who: *who == sov_penpal_b_on_westend,
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
// Deposited to receiver parachain SA
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Deposit { who, .. }
|
||||
pallet_balances::Event::Minted { who, .. }
|
||||
) => {
|
||||
who: *who == sov_penpal_a_on_westend,
|
||||
},
|
||||
@@ -217,7 +217,7 @@ fn para_to_para_receiver_assertions(_: ParaToParaTest) {
|
||||
assert_expected_events!(
|
||||
PenpalA,
|
||||
vec![
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { .. }) => {},
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { .. }) => {},
|
||||
RuntimeEvent::MessageQueue(
|
||||
pallet_message_queue::Event::Processed { success: true, .. }
|
||||
) => {},
|
||||
|
||||
+10
-10
@@ -28,12 +28,12 @@ fn relay_origin_assertions(t: RelayToSystemParaTest) {
|
||||
Westend,
|
||||
vec![
|
||||
// Amount to teleport is withdrawn from Sender
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Withdraw { who, amount }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Burned { who, amount }) => {
|
||||
who: *who == t.sender.account_id,
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
// Amount to teleport is deposited in Relay's `CheckAccount`
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, amount }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, amount }) => {
|
||||
who: *who == <Westend as WestendPallet>::XcmPallet::check_account(),
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
@@ -54,12 +54,12 @@ fn relay_dest_assertions(t: SystemParaToRelayTest) {
|
||||
Westend,
|
||||
vec![
|
||||
// Amount is withdrawn from Relay Chain's `CheckAccount`
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Withdraw { who, amount }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Burned { who, amount }) => {
|
||||
who: *who == <Westend as WestendPallet>::XcmPallet::check_account(),
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
// Amount minus fees are deposited in Receiver's account
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, .. }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, .. }) => {
|
||||
who: *who == t.receiver.account_id,
|
||||
},
|
||||
]
|
||||
@@ -88,7 +88,7 @@ fn para_origin_assertions(t: SystemParaToRelayTest) {
|
||||
AssetHubWestend,
|
||||
vec![
|
||||
// Amount is withdrawn from Sender's account
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Withdraw { who, amount }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Burned { who, amount }) => {
|
||||
who: *who == t.sender.account_id,
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
@@ -105,7 +105,7 @@ fn para_dest_assertions(t: RelayToSystemParaTest) {
|
||||
AssetHubWestend,
|
||||
vec![
|
||||
// Amount minus fees are deposited in Receiver's account
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, .. }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, .. }) => {
|
||||
who: *who == t.receiver.account_id,
|
||||
},
|
||||
]
|
||||
@@ -122,7 +122,7 @@ fn penpal_to_ah_foreign_assets_sender_assertions(t: ParaToSystemParaTest) {
|
||||
PenpalB,
|
||||
vec![
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Withdraw { who, amount }
|
||||
pallet_balances::Event::Burned { who, amount }
|
||||
) => {
|
||||
who: *who == t.sender.account_id,
|
||||
amount: *amount == t.args.amount,
|
||||
@@ -149,12 +149,12 @@ fn penpal_to_ah_foreign_assets_receiver_assertions(t: ParaToSystemParaTest) {
|
||||
vec![
|
||||
// native asset reserve transfer for paying fees, withdrawn from Penpal's sov account
|
||||
RuntimeEvent::Balances(
|
||||
pallet_balances::Event::Withdraw { who, amount }
|
||||
pallet_balances::Event::Burned { who, amount }
|
||||
) => {
|
||||
who: *who == sov_penpal_on_ahr.clone().into(),
|
||||
amount: *amount == t.args.amount,
|
||||
},
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, .. }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, .. }) => {
|
||||
who: *who == t.receiver.account_id,
|
||||
},
|
||||
RuntimeEvent::ForeignAssets(pallet_assets::Event::Issued { asset_id, owner, amount }) => {
|
||||
@@ -221,7 +221,7 @@ fn ah_to_penpal_foreign_assets_receiver_assertions(t: SystemParaToParaTest) {
|
||||
amount: *amount == expected_asset_amount,
|
||||
},
|
||||
// native asset for fee is deposited to receiver
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Deposit { who, .. }) => {
|
||||
RuntimeEvent::Balances(pallet_balances::Event::Minted { who, .. }) => {
|
||||
who: *who == t.receiver.account_id,
|
||||
},
|
||||
RuntimeEvent::MessageQueue(
|
||||
|
||||
Reference in New Issue
Block a user