diff --git a/libs/mocks/src/data.rs b/libs/mocks/src/data.rs index a3e4b711f0..bf0019cf3f 100644 --- a/libs/mocks/src/data.rs +++ b/libs/mocks/src/data.rs @@ -51,7 +51,7 @@ pub mod pallet { } pub fn mock_feed_value( - f: impl Fn(T::AccountId, T::DataId, T::DataElem) -> DispatchResult + 'static, + f: impl Fn(Option, T::DataId, T::DataElem) -> DispatchResult + 'static, ) { register_call!(move |(a, b, c)| f(a, b, c)); } diff --git a/libs/test-utils/src/mocks/accountant.rs b/libs/test-utils/src/mocks/accountant.rs index f0a25589b7..a85d8f479e 100644 --- a/libs/test-utils/src/mocks/accountant.rs +++ b/libs/test-utils/src/mocks/accountant.rs @@ -143,7 +143,7 @@ macro_rules! impl_mock_accountant { ) -> Result<(), Self::Error> { let _ = __private_STATE.with(|s| s.borrow().info(&id))?; - Tokens::transfer(id.into(), source, dest, amount, Preservation::Protect) + Tokens::transfer(id.into(), source, dest, amount, Preservation::Expendable) .map(|_| ()) } diff --git a/pallets/block-rewards/src/tests.rs b/pallets/block-rewards/src/tests.rs index 79b6be6794..0de70d9570 100644 --- a/pallets/block-rewards/src/tests.rs +++ b/pallets/block-rewards/src/tests.rs @@ -5,7 +5,7 @@ use sp_runtime::traits::BadOrigin; use super::*; use crate::mock::*; -const REWARD: u128 = 100 * crate::mock::ExistentialDeposit::get(); +const REWARD: u128 = 100 + crate::mock::ExistentialDeposit::get(); #[test] fn check_special_privileges() { diff --git a/pallets/loans/src/benchmarking.rs b/pallets/loans/src/benchmarking.rs index f131546121..137e0981f2 100644 --- a/pallets/loans/src/benchmarking.rs +++ b/pallets/loans/src/benchmarking.rs @@ -231,7 +231,7 @@ where } fn propose_policy(pool_id: T::PoolId) -> T::Hash { - let pool_admin = account::("pool_admin", 0, 0); + let pool_admin = account("pool_admin", 0, 0); let policy = Pallet::::worst_case_policy(); Pallet::::propose_write_off_policy( RawOrigin::Signed(pool_admin).into(), @@ -249,7 +249,7 @@ where fn set_policy(pool_id: T::PoolId) { let change_id = Self::propose_policy(pool_id); - let any = account::("any", 0, 0); + let any = account("any", 0, 0); Pallet::::apply_write_off_policy(RawOrigin::Signed(any).into(), pool_id, change_id) .unwrap(); } @@ -276,7 +276,7 @@ where // This restriction no longer exists once // https://github.com/open-web3-stack/open-runtime-module-library/pull/920 is merged let feeder = account("feeder", i, 0); - T::PriceRegistry::feed_value(feeder, price_id, Default::default()).unwrap(); + T::PriceRegistry::feed_value(Some(feeder), price_id, Default::default()).unwrap(); T::PriceRegistry::register_id(&price_id, &pool_id).unwrap(); }