mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-22 16:44:20 +01:00
test_lightningd.py: wait longer test_permfail for l2 to notice new blocks.
Reproduced this failure locally: l2 hadn't seen the block yet. Timeout was too aggressive. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -1527,7 +1527,6 @@ class LightningDTests(BaseLightningDTests):
|
|||||||
wait_for(lambda: p.rpc.listpeers(l1.info['id'])['peers'][0]['channels'][0]['status'][1] == 'ONCHAIN:Tracking mutual close transaction')
|
wait_for(lambda: p.rpc.listpeers(l1.info['id'])['peers'][0]['channels'][0]['status'][1] == 'ONCHAIN:Tracking mutual close transaction')
|
||||||
l1.daemon.wait_for_logs([' to ONCHAIN'] * num_peers)
|
l1.daemon.wait_for_logs([' to ONCHAIN'] * num_peers)
|
||||||
|
|
||||||
@flaky
|
|
||||||
@unittest.skipIf(not DEVELOPER, "needs DEVELOPER=1")
|
@unittest.skipIf(not DEVELOPER, "needs DEVELOPER=1")
|
||||||
def test_permfail(self):
|
def test_permfail(self):
|
||||||
l1, l2 = self.connect()
|
l1, l2 = self.connect()
|
||||||
@@ -1583,7 +1582,7 @@ class LightningDTests(BaseLightningDTests):
|
|||||||
bitcoind.generate_block(95)
|
bitcoind.generate_block(95)
|
||||||
wait_forget_channels(l1)
|
wait_forget_channels(l1)
|
||||||
|
|
||||||
wait_for(lambda: l2.rpc.listpeers(l1.info['id'])['peers'][0]['channels'][0]['status'] == ['ONCHAIN:Tracking our own unilateral close', 'ONCHAIN:All outputs resolved: waiting 5 more blocks before forgetting channel'], timeout=1)
|
wait_for(lambda: l2.rpc.listpeers(l1.info['id'])['peers'][0]['channels'][0]['status'] == ['ONCHAIN:Tracking our own unilateral close', 'ONCHAIN:All outputs resolved: waiting 5 more blocks before forgetting channel'])
|
||||||
|
|
||||||
# Now, 100 blocks l2 should be done.
|
# Now, 100 blocks l2 should be done.
|
||||||
bitcoind.generate_block(5)
|
bitcoind.generate_block(5)
|
||||||
|
|||||||
Reference in New Issue
Block a user