Skip to content
Snippets Groups Projects
Commit 3351cb88 authored by Xiliang Chen's avatar Xiliang Chen Committed by GitHub
Browse files

expose set_timestamp for runtime benchmarks (#8601)


* expose set_timestamp for runtime benchmarks

* Update frame/timestamp/src/lib.rs

Co-authored-by: default avatarGuillaume Thiolliere <gui.thiolliere@gmail.com>

Co-authored-by: default avatarGuillaume Thiolliere <gui.thiolliere@gmail.com>
parent f8541941
No related merge requests found
......@@ -258,7 +258,7 @@ impl<T: Config> Pallet<T> {
}
/// Set the timestamp to something in particular. Only used for tests.
#[cfg(feature = "std")]
#[cfg(any(feature = "runtime-benchmarks", feature = "std"))]
pub fn set_timestamp(now: T::Moment) {
Now::<T>::put(now);
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment