From b966e5e78324aaacb5361c8029acc21ae85cdb70 Mon Sep 17 00:00:00 2001 From: darosior Date: Fri, 9 Aug 2019 11:02:46 +0200 Subject: [PATCH] Add a test for 'fundchannel_start' crash on deconnection --- tests/test_connection.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/test_connection.py b/tests/test_connection.py index 2e1b9a8d2..ff9c7de0b 100644 --- a/tests/test_connection.py +++ b/tests/test_connection.py @@ -920,6 +920,7 @@ def test_funding_cancel_race(node_factory, bitcoind, executor): def test_funding_external_wallet(node_factory, bitcoind): l1 = node_factory.get_node() l2 = node_factory.get_node() + l3 = node_factory.get_node() l1.rpc.connect(l2.info['id'], 'localhost', l2.port) assert(l1.rpc.listpeers()['peers'][0]['id'] == l2.info['id']) @@ -966,6 +967,11 @@ def test_funding_external_wallet(node_factory, bitcoind): channel = node.rpc.listpeers()['peers'][0]['channels'][0] assert amount * 1000 == channel['msatoshi_total'] + # Test that we don't crash if peer disconnects after fundchannel_start + l2.connect(l3) + l2.rpc.fundchannel_start(l3.info["id"], amount) + l3.rpc.close(l2.info["id"]) + def test_lockin_between_restart(node_factory, bitcoind): l1 = node_factory.get_node(may_reconnect=True)