Fix warnings (#64)
This commit is contained in:
parent
03bfb012a1
commit
84f675021c
@ -240,6 +240,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
/// run an json executive test
|
||||
pub fn json_executive_test<H: FnMut(&str, HookType)>(
|
||||
path: &Path,
|
||||
json_data: &[u8],
|
||||
|
@ -19,12 +19,14 @@
|
||||
mod chain;
|
||||
mod difficulty;
|
||||
mod executive;
|
||||
pub mod runner;
|
||||
mod state;
|
||||
mod test_common;
|
||||
mod transaction;
|
||||
mod trie;
|
||||
|
||||
/// executor of ethereum/json tests
|
||||
pub mod runner;
|
||||
|
||||
pub use self::{
|
||||
executive::json_executive_test,
|
||||
test_common::{debug_include_test, find_json_files_recursive, HookType},
|
||||
|
@ -59,6 +59,7 @@ impl std::ops::AddAssign for TestResult {
|
||||
}
|
||||
}
|
||||
|
||||
/// An executor of ethereum/json tests
|
||||
pub struct TestRunner(EthereumTestSuite);
|
||||
|
||||
impl TestRunner {
|
||||
|
@ -27,6 +27,7 @@ pub enum HookType {
|
||||
OnStop,
|
||||
}
|
||||
|
||||
/// find all json files recursively from a path
|
||||
pub fn find_json_files_recursive(path: &PathBuf) -> Vec<PathBuf> {
|
||||
WalkDir::new(path)
|
||||
.into_iter()
|
||||
@ -36,6 +37,7 @@ pub fn find_json_files_recursive(path: &PathBuf) -> Vec<PathBuf> {
|
||||
.collect::<Vec<PathBuf>>()
|
||||
}
|
||||
|
||||
/// check if the test is selected to execute via TEST_DEBUG environment variable
|
||||
pub fn debug_include_test(name: &str) -> bool {
|
||||
match std::env::var_os("TEST_DEBUG") {
|
||||
Some(s) => s.to_string_lossy().split_terminator(",").any(|expr| {
|
||||
|
Loading…
Reference in New Issue
Block a user