Skip to content

Commit

Permalink
fix benchmarks
Browse files Browse the repository at this point in the history
  • Loading branch information
lemunozm committed Dec 1, 2023
1 parent 4c9d5f7 commit ba69e8c
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions runtime/common/src/changes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,15 +65,20 @@ pub struct FastDelay;

impl<T: Changeable> From<RuntimeChange<T, FastDelay>> for PoolChangeProposal {
fn from(runtime_change: RuntimeChange<T, FastDelay>) -> Self {
let new_requirements = runtime_change
.requirement_list()
.into_iter()
.map(|req| match req {
Requirement::DelayTime(_) => Requirement::DelayTime(60), // 1 min
req => req,
});
if cfg!(feature = "runtime-benchmarks") {
PoolChangeProposal::new([])
} else {
let new_requirements =
runtime_change
.requirement_list()
.into_iter()
.map(|req| match req {
Requirement::DelayTime(_) => Requirement::DelayTime(60), // 1 min
req => req,
});

PoolChangeProposal::new(new_requirements)
PoolChangeProposal::new(new_requirements)
}
}
}

Expand Down

0 comments on commit ba69e8c

Please sign in to comment.