Skip to content

Commit

Permalink
deps: Update restricted-xtokens deps
Browse files Browse the repository at this point in the history
  • Loading branch information
cdamian committed Nov 28, 2023
1 parent b359850 commit bf0ea63
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 105 deletions.
37 changes: 0 additions & 37 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

68 changes: 0 additions & 68 deletions runtime/integration-tests/src/generic/cases/liquidity_pools.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ use crate::{
};

mod utils {
use polkadot_runtime_parachains::paras;

use super::*;

pub fn parachain_account(id: u32) -> AccountId {
Expand Down Expand Up @@ -1563,72 +1561,6 @@ mod centrifuge {
);
});
}

pub fn transfer_usdc_from_relay_chain<T: Runtime + FudgeSupport>(env: &mut FudgeEnv<T>) {
let alice_initial_usdc = usdc(1_000_000_000_000);
let transfer_amount: Balance = usdc(3_000_000_000);

env.parachain_state_mut(|| {
register_usdc::<T>();
assert_eq!(
orml_tokens::Pallet::<T>::free_balance(USDC, &Keyring::Alice.into()),
0
);
});

env.relay_state_mut(|| {
assert_ok!(
pallet_balances::Pallet::<FudgeRelayRuntime<T>>::force_set_balance(
<FudgeRelayRuntime<T> as frame_system::Config>::RuntimeOrigin::root(),
Keyring::Alice.to_account_id().into(),
alice_initial_usdc,
)
);

assert_ok!(
pallet_xcm::Pallet::<FudgeRelayRuntime<T>>::force_xcm_version(
<FudgeRelayRuntime<T> as frame_system::Config>::RuntimeOrigin::root(),
Box::new(MultiLocation::new(
0,
Junctions::X1(Junction::Parachain(T::FudgeHandle::PARA_ID)),
)),
XCM_VERSION,
)
);

assert_ok!(
pallet_xcm::Pallet::<FudgeRelayRuntime<T>>::reserve_transfer_assets(
RawOrigin::Signed(Keyring::Alice.into()).into(),
Box::new(Parachain(T::FudgeHandle::PARA_ID).into()),
Box::new(
Junction::AccountId32 {
network: None,
id: Keyring::Alice.into(),
}
.into()
),
Box::new((Here, transfer_amount).into()),
0
)
);

assert_eq!(
pallet_balances::Pallet::<FudgeRelayRuntime<T>>::free_balance(
&Keyring::Alice.into()
),
alice_initial_usdc - transfer_amount
);
});

env.pass(Blocks::ByNumber(1));

env.parachain_state(|| {
assert_eq!(
orml_tokens::Pallet::<T>::free_balance(USDC, &Keyring::Alice.into()),
transfer_amount - usdc_fee()
);
});
}
}

use utils::*;
Expand Down

0 comments on commit bf0ea63

Please sign in to comment.