Dont Convert Benchmark Error Too Early (#9743)

* dont convert benchmark error

* fix warning

* fix more warnings

* more fixes

* more fixes

* add missing feature deps

* Update frame/election-provider-multi-phase/src/benchmarking.rs

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* Update frame/election-provider-multi-phase/src/benchmarking.rs

Co-authored-by: Alexander Theißen <alex.theissen@me.com>

* use from

Co-authored-by: Alexander Theißen <alex.theissen@me.com>
This commit is contained in:
Shawn Tabrizi
2021-09-10 08:06:24 -04:00
committed by GitHub
parent a36e881783
commit 250f9fc1ae
10 changed files with 34 additions and 13 deletions
@@ -1213,7 +1213,7 @@ benchmarks! {
for addr in &addresses {
if let Some(_) = ContractInfoOf::<T>::get(&addr) {
return Err("Expected that contract does not exist at this point.");
return Err("Expected that contract does not exist at this point.".into());
}
}
}: call(origin, callee, 0u32.into(), Weight::max_value(), vec![])
@@ -2241,7 +2241,7 @@ benchmarks! {
);
}
#[cfg(not(feature = "std"))]
return Err("Run this bench with a native runtime in order to see the schedule.");
return Err("Run this bench with a native runtime in order to see the schedule.".into());
}: {}
// Execute one erc20 transfer using the ink! erc20 example contract.