Skip to content

Commit

Permalink
Benchmarks
Browse files Browse the repository at this point in the history
  • Loading branch information
Dinonard committed Dec 21, 2023
1 parent 6016046 commit 52fceb4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pallets/dapp-staking-migration/src/benchmarking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -105,15 +105,16 @@ mod benchmarks {
}
}


#[benchmark]
fn cleanup_old_storage_success() {
fn cleanup_old_storage_success(x: Linear<1, 5>) {
initial_config::<T>();

#[block]
{
// TODO: for some reason, tests always fail here, nothing gets removed from storage.
// When tested against real runtime, it works just fine.
let _ = Migration::<T>::cleanup_old_storage(1);
let _ = Migration::<T>::cleanup_old_storage(x.into());
}
}

Expand Down

0 comments on commit 52fceb4

Please sign in to comment.