mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 09:51:10 +00:00
Rename pallet trait Trait to Config (#7599)
* rename Trait to Config * add test asserting using Trait is still valid. * fix ui tests
This commit is contained in:
committed by
GitHub
parent
dd3c84c362
commit
1cbfc9257f
@@ -45,7 +45,7 @@ impl_outer_dispatch! {
|
||||
#[derive(Clone, Eq, PartialEq, Debug)]
|
||||
pub struct Test;
|
||||
|
||||
impl frame_system::Trait for Test {
|
||||
impl frame_system::Config for Test {
|
||||
type BaseCallFilter = ();
|
||||
type Origin = Origin;
|
||||
type Index = AccountIndex;
|
||||
@@ -75,7 +75,7 @@ impl frame_system::Trait for Test {
|
||||
parameter_types! {
|
||||
pub const ExistentialDeposit: Balance = 10;
|
||||
}
|
||||
impl pallet_balances::Trait for Test {
|
||||
impl pallet_balances::Config for Test {
|
||||
type MaxLocks = ();
|
||||
type Balance = Balance;
|
||||
type Event = ();
|
||||
@@ -88,13 +88,13 @@ impl pallet_balances::Trait for Test {
|
||||
parameter_types! {
|
||||
pub const MinimumPeriod: u64 = 5;
|
||||
}
|
||||
impl pallet_timestamp::Trait for Test {
|
||||
impl pallet_timestamp::Config for Test {
|
||||
type Moment = u64;
|
||||
type OnTimestampSet = ();
|
||||
type MinimumPeriod = MinimumPeriod;
|
||||
type WeightInfo = ();
|
||||
}
|
||||
impl pallet_session::historical::Trait for Test {
|
||||
impl pallet_session::historical::Config for Test {
|
||||
type FullIdentification = pallet_staking::Exposure<AccountId, Balance>;
|
||||
type FullIdentificationOf = pallet_staking::ExposureOf<Test>;
|
||||
}
|
||||
@@ -120,7 +120,7 @@ impl pallet_session::SessionHandler<AccountId> for TestSessionHandler {
|
||||
fn on_disabled(_: usize) {}
|
||||
}
|
||||
|
||||
impl pallet_session::Trait for Test {
|
||||
impl pallet_session::Config for Test {
|
||||
type SessionManager = pallet_session::historical::NoteHistoricalRoot<Test, Staking>;
|
||||
type Keys = SessionKeys;
|
||||
type ShouldEndSession = pallet_session::PeriodicSessions<(), ()>;
|
||||
@@ -157,7 +157,7 @@ impl<C> frame_system::offchain::SendTransactionTypes<C> for Test where
|
||||
type Extrinsic = Extrinsic;
|
||||
}
|
||||
|
||||
impl pallet_staking::Trait for Test {
|
||||
impl pallet_staking::Config for Test {
|
||||
type Currency = Balances;
|
||||
type UnixTime = pallet_timestamp::Module<Self>;
|
||||
type CurrencyToVote = frame_support::traits::SaturatingCurrencyToVote;
|
||||
@@ -182,7 +182,7 @@ impl pallet_staking::Trait for Test {
|
||||
type WeightInfo = ();
|
||||
}
|
||||
|
||||
impl crate::Trait for Test {}
|
||||
impl crate::Config for Test {}
|
||||
|
||||
pub fn new_test_ext() -> sp_io::TestExternalities {
|
||||
let t = frame_system::GenesisConfig::default().build_storage::<Test>().unwrap();
|
||||
|
||||
Reference in New Issue
Block a user