From 90ede052ad3b6f5f10c6aed551a220fc33194cc7 Mon Sep 17 00:00:00 2001 From: Christian Decker Date: Tue, 2 May 2023 17:15:08 +0200 Subject: [PATCH] pytest: Extend ListPeerChannels test to include ListClosedChannels --- tests/test_cln_rs.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/test_cln_rs.py b/tests/test_cln_rs.py index 8d9a39091..694c6c8c6 100644 --- a/tests/test_cln_rs.py +++ b/tests/test_cln_rs.py @@ -389,3 +389,13 @@ def test_grpc_listpeerchannels(bitcoind, node_factory): c = res.channels[0] assert c.peer_id.hex() == l2.info['id'] assert c.state == 2 # CHANNELD_NORMAL + + # And since we're at it let's close the channel as well so we can + # see it in listclosedchanenls + + res = stub.Close(nodepb.CloseRequest(id=l2.info['id'])) + + bitcoind.generate_block(100, wait_for_mempool=1) + l1.daemon.wait_for_log(r'onchaind complete, forgetting peer') + + stub.ListClosedChannels(nodepb.ListclosedchannelsRequest())