mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 09:21:04 +00:00
Companion for substrate/6782 (#1523)
* Fix test-runtime * Remove duplicate tests
This commit is contained in:
@@ -1336,16 +1336,3 @@ sp_api::impl_runtime_apis! {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
|
||||||
mod tests {
|
|
||||||
use super::Runtime;
|
|
||||||
|
|
||||||
#[test]
|
|
||||||
fn slash_defer_less_than_bonding_duration() {
|
|
||||||
assert!(
|
|
||||||
<Runtime as staking::Trait>::SlashDeferDuration::get()
|
|
||||||
< <Runtime as staking::Trait>::BondingDuration::get()
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -1474,16 +1474,3 @@ sp_api::impl_runtime_apis! {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
|
||||||
mod tests {
|
|
||||||
use super::Runtime;
|
|
||||||
|
|
||||||
#[test]
|
|
||||||
fn slash_defer_less_than_bonding_duration() {
|
|
||||||
assert!(
|
|
||||||
<Runtime as staking::Trait>::SlashDeferDuration::get()
|
|
||||||
< <Runtime as staking::Trait>::BondingDuration::get()
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -303,8 +303,8 @@ parameter_types! {
|
|||||||
pub storage SessionsPerEra: SessionIndex = 6;
|
pub storage SessionsPerEra: SessionIndex = 6;
|
||||||
// 28 eras for unbonding (7 days).
|
// 28 eras for unbonding (7 days).
|
||||||
pub storage BondingDuration: staking::EraIndex = 28;
|
pub storage BondingDuration: staking::EraIndex = 28;
|
||||||
// 28 eras in which slashes can be cancelled (7 days).
|
// 27 eras in which slashes can be cancelled (a bit less than 7 days).
|
||||||
pub storage SlashDeferDuration: staking::EraIndex = 28;
|
pub storage SlashDeferDuration: staking::EraIndex = 27;
|
||||||
pub const RewardCurve: &'static PiecewiseLinear<'static> = &REWARD_CURVE;
|
pub const RewardCurve: &'static PiecewiseLinear<'static> = &REWARD_CURVE;
|
||||||
pub storage MaxNominatorRewardedPerValidator: u32 = 64;
|
pub storage MaxNominatorRewardedPerValidator: u32 = 64;
|
||||||
pub storage ElectionLookahead: BlockNumber = 0;
|
pub storage ElectionLookahead: BlockNumber = 0;
|
||||||
|
|||||||
@@ -1113,15 +1113,3 @@ sp_api::impl_runtime_apis! {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
|
||||||
mod tests {
|
|
||||||
use super::Runtime;
|
|
||||||
|
|
||||||
#[test]
|
|
||||||
fn slash_defer_less_than_bonding_duration() {
|
|
||||||
assert!(
|
|
||||||
<Runtime as staking::Trait>::SlashDeferDuration::get()
|
|
||||||
< <Runtime as staking::Trait>::BondingDuration::get()
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|||||||
Reference in New Issue
Block a user