mirror of
https://github.com/ElementsProject/lightning.git
synced 2026-08-20 13:27:36 +02:00
pytest: fix flake in test_funding_fail
We may not see a disconnect instantly: ``` > assert len(l2.rpc.listpeers()['peers']) == 0 E assert 1 == 0 E +1 E -0 ``` Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
aeeaa14430
commit
486b1b2481
1 changed files with 2 additions and 2 deletions
|
|
@ -999,8 +999,8 @@ def test_funding_fail(node_factory, bitcoind):
|
|||
l1.rpc.fundchannel(l2.info['id'], int(funds / 10))
|
||||
|
||||
# channels disconnect on failure
|
||||
assert len(l1.rpc.listpeers()['peers']) == 0
|
||||
assert len(l2.rpc.listpeers()['peers']) == 0
|
||||
wait_for(lambda: len(l1.rpc.listpeers()['peers']) == 0)
|
||||
wait_for(lambda: len(l2.rpc.listpeers()['peers']) == 0)
|
||||
|
||||
# Restart l2 without ridiculous locktime.
|
||||
del l2.daemon.opts['watchtime-blocks']
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue