Use hashbrown replacements for std equivalents
[rust-lightning] / lightning / src / util / test_utils.rs
index 7b9b54fabc2c79f1bff95f44c43ba678b034232d..b4d274f683cb5b414b9a174e781feb978600e815 100644 (file)
@@ -42,7 +42,6 @@ use core::time::Duration;
 use std::sync::{Mutex, Arc};
 use core::sync::atomic::{AtomicBool, AtomicUsize, Ordering};
 use core::{cmp, mem};
-use std::collections::{HashMap, HashSet, VecDeque};
 use chain::keysinterface::InMemorySigner;
 
 pub struct TestVecWriter(pub Vec<u8>);
@@ -210,7 +209,7 @@ impl chaininterface::BroadcasterInterface for TestBroadcaster {
                if tx.lock_time > self.blocks.lock().unwrap().len() as u32 + 1 && tx.lock_time < 500_000_000 {
                        for inp in tx.input.iter() {
                                if inp.sequence != 0xffffffff {
-                                       return;
+                                       panic!("We should never broadcast a transaction before its locktime ({})!", tx.lock_time);
                                }
                        }
                }