From 2b07d0b0e686d38be1ed3be7b1122db134041fed Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Sat, 14 Aug 2021 12:30:09 +0930 Subject: [PATCH] pytest: fix test_channel_lease_unilat_closes flake We fail waiting for 'Resolved OUR_UNILATERAL/DELAYED_OUTPUT_TO_US by our proposal OUR_DELAYED_RETURN_TO_WALLET' because we close *two* channels, but only wait for one transaction before mining a block. This means we might only have one, and we immediately mine the next wait_for_mempool=1, so the OUR_DELAYED_RETURN_TO_WALLET isn't mined. Signed-off-by: Rusty Russell --- tests/test_closing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_closing.py b/tests/test_closing.py index 270767234..96bc0ad31 100644 --- a/tests/test_closing.py +++ b/tests/test_closing.py @@ -910,7 +910,7 @@ def test_channel_lease_unilat_closes(node_factory, bitcoind): l3.rpc.close(l2.info['id'], 1, force_lease_closed=True) # Wait til to_self_delay expires, l1 should claim to_local back - bitcoind.generate_block(10, wait_for_mempool=1) + bitcoind.generate_block(10, wait_for_mempool=2) l1.daemon.wait_for_log('Broadcasting OUR_DELAYED_RETURN_TO_WALLET') bitcoind.generate_block(1, wait_for_mempool=1) l1.daemon.wait_for_log('Resolved OUR_UNILATERAL/DELAYED_OUTPUT_TO_US by our proposal OUR_DELAYED_RETURN_TO_WALLET')