Skip to content

Commit

Permalink
adding check for the deprecated api.
Browse files Browse the repository at this point in the history
Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@gmail.com>
  • Loading branch information
vincenzopalazzo authored and rustyrussell committed Sep 2, 2021
1 parent 3b65a4c commit 218875a
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions tests/test_gossip.py
Original file line number Diff line number Diff line change
Expand Up @@ -1975,7 +1975,14 @@ def test_parms_listforwards(node_factory):
it is simple and not useful, but it is good to have to avoid
simile errors in the future.
"""
l1, _ = node_factory.line_graph(2)
l1, l2 = node_factory.line_graph(2)

l2.stop()
l2.daemon.opts['allow-deprecated-apis'] = True
l2.start()

forwards_new = l1.rpc.listforwards("settled")["forwards"]
forwards_dep = l2.rpc.call("listforwards", {"in_channel": "0x1x2", "out_channel": "0x2x3", "status": "settled"})["forwards"]

forwards = l1.rpc.listforwards("settled")["forwards"]
assert len(forwards) == 0
assert len(forwards_new) == 0
assert len(forwards_dep) == 0

0 comments on commit 218875a

Please sign in to comment.