New root_testing pallet (#12451)

* Move fill_block to RootOffences

* docs

* new pallet

* new line

* fix

* Update frame/root-testing/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update frame/root-testing/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update bin/node/runtime/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update frame/root-testing/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update frame/root-testing/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update frame/root-testing/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* fixes

* problem solved

* revert

* fix dependency

* hopefully making the CI happy

* ...

* dummy call

* remove dummy

* fix warning

Co-authored-by: Bastian Köcher <git@kchr.de>
This commit is contained in:
Sergej Sakac
2022-11-13 19:48:11 +01:00
committed by GitHub
parent 8c423baf32
commit e5910d971e
16 changed files with 134 additions and 33 deletions
+1
View File
@@ -38,6 +38,7 @@ pallet-sudo = { version = "4.0.0-dev", path = "../../../frame/sudo" }
pallet-timestamp = { version = "4.0.0-dev", path = "../../../frame/timestamp" }
pallet-treasury = { version = "4.0.0-dev", path = "../../../frame/treasury" }
pallet-transaction-payment = { version = "4.0.0-dev", path = "../../../frame/transaction-payment" }
pallet-root-testing = { version = "1.0.0-dev", path = "../../../frame/root-testing" }
sp-application-crypto = { version = "6.0.0", path = "../../../primitives/application-crypto" }
sp-consensus-babe = { version = "0.10.0-dev", path = "../../../primitives/consensus/babe" }
sp-externalities = { version = "0.12.0", path = "../../../primitives/externalities" }
+3 -3
View File
@@ -60,9 +60,9 @@ fn fee_multiplier_increases_and_decreases_on_big_weight() {
CheckedExtrinsic {
signed: Some((charlie(), signed_extra(0, 0))),
function: RuntimeCall::Sudo(pallet_sudo::Call::sudo {
call: Box::new(RuntimeCall::System(frame_system::Call::fill_block {
ratio: Perbill::from_percent(60),
})),
call: Box::new(RuntimeCall::RootTesting(
pallet_root_testing::Call::fill_block { ratio: Perbill::from_percent(60) },
)),
}),
},
],
+3
View File
@@ -89,6 +89,7 @@ pallet-ranked-collective = { version = "4.0.0-dev", default-features = false, pa
pallet-recovery = { version = "4.0.0-dev", default-features = false, path = "../../../frame/recovery" }
pallet-referenda = { version = "4.0.0-dev", default-features = false, path = "../../../frame/referenda" }
pallet-remark = { version = "4.0.0-dev", default-features = false, path = "../../../frame/remark" }
pallet-root-testing = { version = "1.0.0-dev", default-features = false, path = "../../../frame/root-testing" }
pallet-session = { version = "4.0.0-dev", features = [ "historical" ], path = "../../../frame/session", default-features = false }
pallet-session-benchmarking = { version = "4.0.0-dev", path = "../../../frame/session/benchmarking", default-features = false, optional = true }
pallet-staking = { version = "4.0.0-dev", default-features = false, path = "../../../frame/staking" }
@@ -192,6 +193,7 @@ std = [
"pallet-ranked-collective/std",
"pallet-referenda/std",
"pallet-remark/std",
"pallet-root-testing/std",
"pallet-recovery/std",
"pallet-uniques/std",
"pallet-vesting/std",
@@ -292,6 +294,7 @@ try-runtime = [
"pallet-recovery/try-runtime",
"pallet-referenda/try-runtime",
"pallet-remark/try-runtime",
"pallet-root-testing/try-runtime",
"pallet-session/try-runtime",
"pallet-staking/try-runtime",
"pallet-state-trie-migration/try-runtime",
+3
View File
@@ -909,6 +909,8 @@ impl pallet_remark::Config for Runtime {
type RuntimeEvent = RuntimeEvent;
}
impl pallet_root_testing::Config for Runtime {}
parameter_types! {
pub const LaunchPeriod: BlockNumber = 28 * 24 * 60 * MINUTES;
pub const VotingPeriod: BlockNumber = 28 * 24 * 60 * MINUTES;
@@ -1670,6 +1672,7 @@ construct_runtime!(
ChildBounties: pallet_child_bounties,
Referenda: pallet_referenda,
Remark: pallet_remark,
RootTesting: pallet_root_testing,
ConvictionVoting: pallet_conviction_voting,
Whitelist: pallet_whitelist,
AllianceMotion: pallet_collective::<Instance3>,