From d51d606ba3dace151b2de5c893066d381b32405e Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Wed, 26 May 2021 20:02:30 +0000 Subject: [PATCH] panic if locktime is violated when broadcasting in tests --- lightning/src/util/test_utils.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightning/src/util/test_utils.rs b/lightning/src/util/test_utils.rs index 7b9b54fab..60aafd916 100644 --- a/lightning/src/util/test_utils.rs +++ b/lightning/src/util/test_utils.rs @@ -210,7 +210,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); } } } -- 2.39.5