mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 02:21:04 +00:00
Custom Benchmark Errors and Override (#9517)
* initial idea * update benchmark test to frame v2 * fix some errors * fixes for elec phrag * fix tests * update extrinsic time and docs * fix import * undo extra changes * helper function * wrong way * Update frame/benchmarking/src/utils.rs Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com> * doesnt need encode/decode * fix benchmark return Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
This commit is contained in:
@@ -82,7 +82,8 @@ benchmarks! {
|
||||
let (input_heartbeat, signature) = create_heartbeat::<T>(k, e)?;
|
||||
let call = Call::heartbeat(input_heartbeat, signature);
|
||||
}: {
|
||||
ImOnline::<T>::validate_unsigned(TransactionSource::InBlock, &call)?;
|
||||
ImOnline::<T>::validate_unsigned(TransactionSource::InBlock, &call)
|
||||
.map_err(|e| -> &'static str { e.into() })?;
|
||||
}
|
||||
|
||||
validate_unsigned_and_then_heartbeat {
|
||||
@@ -91,7 +92,8 @@ benchmarks! {
|
||||
let (input_heartbeat, signature) = create_heartbeat::<T>(k, e)?;
|
||||
let call = Call::heartbeat(input_heartbeat, signature);
|
||||
}: {
|
||||
ImOnline::<T>::validate_unsigned(TransactionSource::InBlock, &call)?;
|
||||
ImOnline::<T>::validate_unsigned(TransactionSource::InBlock, &call)
|
||||
.map_err(|e| -> &'static str { e.into() })?;
|
||||
call.dispatch_bypass_filter(RawOrigin::None.into())?;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user