Remove flaky merkle timing test (#8602)
This commit is contained in:
@ -280,25 +280,6 @@ mod tests {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
|
||||||
fn test_node_capacity_constant_time() {
|
|
||||||
use std::time::Instant;
|
|
||||||
|
|
||||||
// trigger function invoking optimize once
|
|
||||||
MerkleTree::calculate_vec_capacity(2);
|
|
||||||
|
|
||||||
// record time spending
|
|
||||||
let mut time_record = Instant::now();
|
|
||||||
MerkleTree::calculate_vec_capacity(4);
|
|
||||||
let small_leaf_count_duration = time_record.elapsed();
|
|
||||||
|
|
||||||
time_record = Instant::now();
|
|
||||||
MerkleTree::calculate_vec_capacity(65536);
|
|
||||||
let large_leaf_count_duration = time_record.elapsed();
|
|
||||||
// large leafs should not bring time inceasing
|
|
||||||
assert!(large_leaf_count_duration < 2 * small_leaf_count_duration);
|
|
||||||
}
|
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
#[should_panic]
|
#[should_panic]
|
||||||
fn test_proof_entry_instantiation_both_clear() {
|
fn test_proof_entry_instantiation_both_clear() {
|
||||||
|
Reference in New Issue
Block a user