mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-18 05:18:30 +00:00
Fix test_harness tests
They were broken by changes to TestingBeaconStateBuilder and where the keypairs file is stored.
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
use crate::test_case::TestCase;
|
||||
use clap::ArgMatches;
|
||||
use std::path::Path;
|
||||
use std::{fs::File, io::prelude::*};
|
||||
use yaml_rust::YamlLoader;
|
||||
|
||||
@@ -17,10 +16,6 @@ pub fn run_test(matches: &ArgMatches) {
|
||||
};
|
||||
|
||||
for doc in &docs {
|
||||
let validators_dir = matches
|
||||
.value_of("validators_dir")
|
||||
.and_then(|dir_str| Some(Path::new(dir_str)));
|
||||
|
||||
// For each `test_cases` YAML in the document, build a `TestCase`, execute it and
|
||||
// assert that the execution result matches the test_case description.
|
||||
//
|
||||
@@ -35,7 +30,7 @@ pub fn run_test(matches: &ArgMatches) {
|
||||
// panics with a message.
|
||||
for test_case in doc["test_cases"].as_vec().unwrap() {
|
||||
let test_case = TestCase::from_yaml(test_case);
|
||||
test_case.assert_result_valid(test_case.execute(validators_dir))
|
||||
test_case.assert_result_valid(test_case.execute())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user