MCPcopy Create free account
hub / github.com/ElementsProject/lightning / test_invalid_upfront_shutdown_script

Function test_invalid_upfront_shutdown_script

tests/test_closing.py:3723–3734  ·  view source on GitHub ↗
(node_factory, bitcoind, executor)

Source from the content-addressed store, hash-verified

3721
3722
3723def test_invalid_upfront_shutdown_script(node_factory, bitcoind, executor):
3724 l1, l2 = node_factory.line_graph(2, fundchannel=False)
3725
3726 l1 = node_factory.get_node(start=False, allow_warning=True)
3727 # Insist on upfront script we're not going to match.
3728 l1.daemon.env["DEV_OPENINGD_UPFRONT_SHUTDOWN_SCRIPT"] = "76a91404b61f7dc1ea0dc99424464cc4064dc564d91e8988ac00"
3729 l1.start()
3730
3731 l2 = node_factory.get_node()
3732 l1.rpc.connect(l2.info['id'], 'localhost', l2.port)
3733 with pytest.raises(RpcError, match=r'Unacceptable upfront_shutdown_script'):
3734 l1.fundchannel(l2, 1000000, False)
3735
3736
3737@pytest.mark.slow_test

Callers

nothing calls this directly

Calls 5

line_graphMethod · 0.80
get_nodeMethod · 0.45
startMethod · 0.45
connectMethod · 0.45
fundchannelMethod · 0.45

Tested by

no test coverage detected