Skip to content

Commit

Permalink
pytest: test_gossip_jsonrpc can always test aliases.
Browse files Browse the repository at this point in the history
The whole test is under DEVELOPER anyway, but even if it weren't it
would work fine.

Signed-off-by: Rusty Russell <[email protected]>
  • Loading branch information
rustyrussell committed Jun 6, 2018
1 parent 035d606 commit e4457e5
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions tests/test_lightningd.py
Original file line number Diff line number Diff line change
Expand Up @@ -2455,16 +2455,14 @@ def test_gossip_jsonrpc(self):
assert n2['nodeid'] == l2.info['id']

# Might not have seen other node-announce yet.
# TODO(cdecker) Can't check these without DEVELOPER=1, re-enable after we get alias and color into getinfo
if DEVELOPER:
assert n1['alias'].startswith('JUNIORBEAM')
assert n1['color'] == '0266e4'
if 'alias' not in n2:
assert 'color' not in n2
assert 'addresses' not in n2
else:
assert n2['alias'].startswith('SILENTARTIST')
assert n2['color'] == '022d22'
assert n1['alias'].startswith('JUNIORBEAM')
assert n1['color'] == '0266e4'
if 'alias' not in n2:
assert 'color' not in n2
assert 'addresses' not in n2
else:
assert n2['alias'].startswith('SILENTARTIST')
assert n2['color'] == '022d22'

assert [c['active'] for c in l1.rpc.listchannels()['channels']] == [True, True]
assert [c['public'] for c in l1.rpc.listchannels()['channels']] == [True, True]
Expand Down

0 comments on commit e4457e5

Please sign in to comment.