mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-19 10:01:02 +00:00
Staking e2e test - Add case when ledger active balance falls below ED (#14247)
* Staking e2e test - case when ledger active balance falls below ED * Update frame/election-provider-multi-phase/test-staking-e2e/src/lib.rs Co-authored-by: Ankan <10196091+Ank4n@users.noreply.github.com> * Simplifies test assertions; tests events --------- Co-authored-by: Ankan <10196091+Ank4n@users.noreply.github.com> Co-authored-by: parity-processbot <>
This commit is contained in:
@@ -19,7 +19,8 @@
|
||||
|
||||
use _feps::ExtendedBalance;
|
||||
use frame_support::{
|
||||
dispatch::UnfilteredDispatchable, parameter_types, traits, traits::Hooks, weights::constants,
|
||||
assert_ok, dispatch::UnfilteredDispatchable, parameter_types, traits, traits::Hooks,
|
||||
weights::constants,
|
||||
};
|
||||
use frame_system::EnsureRoot;
|
||||
use sp_core::{ConstU32, Get};
|
||||
@@ -705,6 +706,12 @@ pub(crate) fn start_next_active_era_delayed_solution(
|
||||
start_active_era(active_era() + 1, pool, true)
|
||||
}
|
||||
|
||||
pub(crate) fn advance_eras(n: usize, pool: Arc<RwLock<PoolState>>) {
|
||||
for _ in 0..n {
|
||||
assert_ok!(start_next_active_era(pool.clone()));
|
||||
}
|
||||
}
|
||||
|
||||
/// Progress until the given era.
|
||||
pub(crate) fn start_active_era(
|
||||
era_index: EraIndex,
|
||||
|
||||
Reference in New Issue
Block a user