From dff4dab65eb46af50b38da713e65a7519e841a5f Mon Sep 17 00:00:00 2001 From: James Wilson Date: Mon, 20 Jan 2025 14:38:13 +0000 Subject: [PATCH] Tweak test to look at holds, not locks after polkadot-sdk@f5673cf (#1896) --- .../src/full_client/frame/balances.rs | 20 ++++++++----------- 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/testing/integration-tests/src/full_client/frame/balances.rs b/testing/integration-tests/src/full_client/frame/balances.rs index d721d8e58c..6da1ea0eeb 100644 --- a/testing/integration-tests/src/full_client/frame/balances.rs +++ b/testing/integration-tests/src/full_client/frame/balances.rs @@ -306,23 +306,19 @@ async fn storage_balance_lock() -> Result<(), subxt::Error> { .find_first::()? .expect("No ExtrinsicSuccess Event found"); - let locks_addr = node_runtime::storage().balances().locks(bob); + let holds_addr = node_runtime::storage().balances().holds(bob); - let locks = api + let holds = api .storage() .at_latest() .await? - .fetch_or_default(&locks_addr) - .await?; + .fetch_or_default(&holds_addr) + .await? + .0; - assert_eq!( - locks.0, - vec![runtime_types::pallet_balances::types::BalanceLock { - id: *b"staking ", - amount: 100_000_000_000_000, - reasons: runtime_types::pallet_balances::types::Reasons::All, - }] - ); + // There is now a hold on the balance being staked + assert_eq!(holds.len(), 1); + assert_eq!(holds[0].amount, 100_000_000_000_000); Ok(()) }