Use in-memory database in tests

This commit is contained in:
arkpar
2017-04-06 19:26:17 +02:00
parent 1e6674f804
commit 314af4cdae
19 changed files with 130 additions and 276 deletions

View File

@@ -56,7 +56,7 @@ pub fn json_chain_test(json_data: &[u8]) -> Vec<String> {
let post_root: H256 = state.hash.into();
let transaction = multitransaction.select(&state.indexes).into();
let mut state = get_temp_mem_state();
let mut state = get_temp_state();
state.populate_from(pre.clone());
state.commit().expect(&format!("State test {} failed due to internal error.", name));
let _res = state.apply(&env, &**engine, &transaction, false);