difftreelog
test fix mocks
in: master
3 files changed
pallets/inflation/src/tests.rsdiffbeforeafterboth--- a/pallets/inflation/src/tests.rs
+++ b/pallets/inflation/src/tests.rs
@@ -6,7 +6,9 @@
traits::{Currency},
parameter_types,
};
-use frame_support::{traits::OnInitialize};
+use frame_support::{
+ traits::{OnInitialize, Everything},
+};
use sp_core::H256;
use sp_runtime::{
traits::{BlakeTwo256, IdentityLookup},
@@ -55,7 +57,7 @@
}
impl frame_system::Config for Test {
- type BaseCallFilter = ();
+ type BaseCallFilter = Everything;
type BlockWeights = ();
type BlockLength = ();
type DbWeight = ();
pallets/nft/src/mock.rsdiffbeforeafterboth--- a/pallets/nft/src/mock.rs
+++ b/pallets/nft/src/mock.rs
@@ -2,7 +2,7 @@
use crate as pallet_template;
use sp_core::H256;
-use frame_support::{parameter_types, weights::IdentityFee};
+use frame_support::{parameter_types, traits::Everything, weights::IdentityFee};
use sp_runtime::{
traits::{BlakeTwo256, IdentityLookup},
testing::Header,
@@ -12,6 +12,7 @@
use pallet_evm::AddressMapping;
use crate::{EvmBackwardsAddressMapping, CrossAccountId};
use codec::{Encode, Decode};
+use scale_info::TypeInfo;
type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic<Test>;
type Block = frame_system::mocking::MockBlock<Test>;
@@ -35,7 +36,7 @@
}
impl system::Config for Test {
- type BaseCallFilter = ();
+ type BaseCallFilter = Everything;
type BlockWeights = ();
type BlockLength = ();
type DbWeight = ();
@@ -79,6 +80,7 @@
parameter_types! {
pub const TransactionByteFee: u64 = 1;
+ pub const OperationalFeeMultiplier: u8 = 5;
}
impl pallet_transaction_payment::Config for Test {
@@ -86,6 +88,7 @@
type TransactionByteFee = TransactionByteFee;
type WeightToFee = IdentityFee<u64>;
type FeeMultiplierUpdate = ();
+ type OperationalFeeMultiplier = OperationalFeeMultiplier;
}
parameter_types! {
@@ -118,7 +121,7 @@
}
}
-#[derive(Encode, Decode, Clone, PartialEq, Eq, PartialOrd, Ord, Debug)]
+#[derive(Encode, Decode, Clone, PartialEq, Eq, PartialOrd, Ord, Debug, TypeInfo)]
pub struct TestCrossAccountId(u64, sp_core::H160);
impl CrossAccountId<u64> for TestCrossAccountId {
fn from_sub(sub: u64) -> Self {
pallets/scheduler/src/lib.rsdiffbeforeafterboth796796797 use frame_support::{797 use frame_support::{798 Hashable, assert_err, assert_noop, assert_ok, ord_parameter_types, parameter_types,798 Hashable, assert_err, assert_noop, assert_ok, ord_parameter_types, parameter_types,799 traits::{Contains, Filter, OnFinalize, OnInitialize},799 traits::{Contains, OnFinalize, OnInitialize},800 weights::constants::RocksDbWeight,800 weights::constants::RocksDbWeight,801 };801 };802 use sp_core::H256;802 use sp_core::H256;873 pub struct BaseFilter;873 pub struct BaseFilter;874 impl Contains<Call> for BaseFilter {874 impl Contains<Call> for BaseFilter {875 fn contains(call: &Call) -> bool {875 fn contains(call: &Call) -> bool {876 !matches!(call, Call::Logger(logger::Call::log(_, _)))876 !matches!(call, Call::Logger(logger::Call::log { .. }))877 }877 }878 }878 }879879