mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 14:01:06 +00:00
migrate babe and authorship to use derive-impl (#1790)
Moving a babe and authorship pallets to the latest and greatest derive_impl. Part of https://github.com/paritytech/polkadot-sdk/issues/171 --------- Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
This commit is contained in:
@@ -97,16 +97,10 @@ mod tests {
|
||||
use super::*;
|
||||
use crate as pallet_authorship;
|
||||
use codec::{Decode, Encode};
|
||||
use frame_support::{
|
||||
traits::{ConstU32, ConstU64},
|
||||
ConsensusEngineId,
|
||||
};
|
||||
use frame_support::{derive_impl, ConsensusEngineId};
|
||||
use sp_core::H256;
|
||||
use sp_runtime::{
|
||||
generic::DigestItem,
|
||||
testing::Header,
|
||||
traits::{BlakeTwo256, Header as HeaderT, IdentityLookup},
|
||||
BuildStorage,
|
||||
generic::DigestItem, testing::Header, traits::Header as HeaderT, BuildStorage,
|
||||
};
|
||||
|
||||
type Block = frame_system::mocking::MockBlock<Test>;
|
||||
@@ -119,30 +113,9 @@ mod tests {
|
||||
}
|
||||
);
|
||||
|
||||
#[derive_impl(frame_system::config_preludes::TestDefaultConfig as frame_system::DefaultConfig)]
|
||||
impl frame_system::Config for Test {
|
||||
type BaseCallFilter = frame_support::traits::Everything;
|
||||
type BlockWeights = ();
|
||||
type BlockLength = ();
|
||||
type DbWeight = ();
|
||||
type RuntimeOrigin = RuntimeOrigin;
|
||||
type Nonce = u64;
|
||||
type RuntimeCall = RuntimeCall;
|
||||
type Hash = H256;
|
||||
type Hashing = BlakeTwo256;
|
||||
type AccountId = u64;
|
||||
type Lookup = IdentityLookup<Self::AccountId>;
|
||||
type Block = Block;
|
||||
type RuntimeEvent = RuntimeEvent;
|
||||
type BlockHashCount = ConstU64<250>;
|
||||
type Version = ();
|
||||
type PalletInfo = PalletInfo;
|
||||
type AccountData = ();
|
||||
type OnNewAccount = ();
|
||||
type OnKilledAccount = ();
|
||||
type SystemWeightInfo = ();
|
||||
type SS58Prefix = ();
|
||||
type OnSetCode = ();
|
||||
type MaxConsumers = ConstU32<16>;
|
||||
}
|
||||
|
||||
impl pallet::Config for Test {
|
||||
|
||||
Reference in New Issue
Block a user