More tests for message pallet weights (#1870)

* more tests for message pallet weights

* move tests to ensure_weights_are_correct

* removed extra tests
This commit is contained in:
Svyatoslav Nikolsky
2023-02-13 15:26:25 +03:00
committed by Bastian Köcher
parent 47e045d55e
commit 89bb368e45
3 changed files with 235 additions and 89 deletions
+3 -2
View File
@@ -34,7 +34,7 @@ use codec::{Decode, Encode};
use frame_support::{
parameter_types,
traits::ConstU64,
weights::{RuntimeDbWeight, Weight},
weights::{constants::RocksDbWeight, Weight},
};
use scale_info::TypeInfo;
use sp_core::H256;
@@ -92,9 +92,10 @@ parameter_types! {
pub const MaximumBlockWeight: Weight = Weight::from_ref_time(1024);
pub const MaximumBlockLength: u32 = 2 * 1024;
pub const AvailableBlockRatio: Perbill = Perbill::one();
pub const DbWeight: RuntimeDbWeight = RuntimeDbWeight { read: 1, write: 2 };
}
pub type DbWeight = RocksDbWeight;
impl frame_system::Config for TestRuntime {
type RuntimeOrigin = RuntimeOrigin;
type Index = u64;