mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 08:11:03 +00:00
Pass transaction source to validate_transaction (#5366)
* WiP * Support source in the runtime API. * Finish implementation in txpool. * Fix warning. * Fix tests. * Apply suggestions from code review Co-Authored-By: Kian Paimani <5588131+kianenigma@users.noreply.github.com> Co-Authored-By: Nikolay Volf <nikvolf@gmail.com> * Extra changes. * Fix test and benches. * fix test * Fix test & benches again. * Fix tests. * Update bumpalo * Fix doc test. * Fix doctest. * Fix doctest. Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com> Co-authored-by: Nikolay Volf <nikvolf@gmail.com>
This commit is contained in:
@@ -24,6 +24,7 @@ use frame_system::RawOrigin;
|
||||
use frame_benchmarking::benchmarks;
|
||||
use sp_core::offchain::{OpaquePeerId, OpaqueMultiaddr};
|
||||
use sp_runtime::traits::{ValidateUnsigned, Zero};
|
||||
use sp_runtime::transaction_validity::TransactionSource;
|
||||
|
||||
use crate::Module as ImOnline;
|
||||
|
||||
@@ -72,7 +73,7 @@ benchmarks! {
|
||||
let (input_heartbeat, signature) = create_heartbeat::<T>(k, e)?;
|
||||
let call = Call::heartbeat(input_heartbeat, signature);
|
||||
}: {
|
||||
ImOnline::<T>::validate_unsigned(&call)?;
|
||||
ImOnline::<T>::validate_unsigned(TransactionSource::InBlock, &call)?;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user