mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-22 06:41:44 +01:00
pytest: fix output order assumption in test_setchannel_all
Hash table coming up makes it random! Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
6a95d3a25e
commit
17aa047b17
1 changed files with 3 additions and 0 deletions
|
@ -2413,7 +2413,10 @@ def test_setchannel_all(node_factory, bitcoind):
|
|||
wait_for(lambda: [c['base_fee_millisatoshi'] for c in l1.rpc.listchannels(scid3)['channels']] == [0xDEAD, DEF_BASE])
|
||||
wait_for(lambda: [c['fee_per_millionth'] for c in l1.rpc.listchannels(scid3)['channels']] == [0xBEEF, DEF_PPM])
|
||||
|
||||
# Don't assume order!
|
||||
assert len(result['channels']) == 2
|
||||
if result['channels'][0]['peer_id'] == l3.info['id']:
|
||||
result['channels'] = [result['channels'][1], result['channels'][0]]
|
||||
assert result['channels'][0]['peer_id'] == l2.info['id']
|
||||
assert result['channels'][0]['short_channel_id'] == scid2
|
||||
assert result['channels'][0]['fee_base_msat'] == 0xDEAD
|
||||
|
|
Loading…
Add table
Reference in a new issue