Add tests to ensure session is set correctly in OnChainScrapingVotes (#4821)

Co-authored-by: Bernhard Schuster <bernhard@ahoi.io>
This commit is contained in:
Lldenaurois
2022-02-02 18:40:21 +01:00
committed by GitHub
parent 7e9a58fc99
commit f7564591e7
2 changed files with 150 additions and 7 deletions
+5 -1
View File
@@ -1313,6 +1313,10 @@ fn check_signature(
}
}
#[cfg(test)]
#[allow(unused_imports)]
pub(crate) use self::tests::run_to_block;
#[cfg(test)]
mod tests {
use super::*;
@@ -1363,7 +1367,7 @@ mod tests {
// Run to specific block, while calling disputes pallet hooks manually, because disputes is not
// integrated in initializer yet.
fn run_to_block<'a>(
pub(crate) fn run_to_block<'a>(
to: BlockNumber,
new_session: impl Fn(BlockNumber) -> Option<NewSession<'a>>,
) {