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

Function test_dynamic_args

tests/test_plugin.py:3019–3030  ·  view source on GitHub ↗
(node_factory)

Source from the content-addressed store, hash-verified

3017
3018
3019def test_dynamic_args(node_factory):
3020 plugin_path = os.path.join(os.getcwd(), 'contrib/plugins/helloworld.py')
3021
3022 l1 = node_factory.get_node()
3023 l1.rpc.plugin_start(plugin_path, greeting='Test arg parsing')
3024
3025 assert l1.rpc.call("hello") == "Test arg parsing world"
3026 assert l1.rpc.listconfigs('greeting')['configs']['greeting']['value_str'] == 'Test arg parsing'
3027 assert l1.rpc.listconfigs('greeting')['configs']['greeting']['plugin'] == plugin_path
3028
3029 l1.rpc.plugin_stop(plugin_path)
3030 assert 'greeting' not in l1.rpc.listconfigs()['configs']
3031
3032
3033def test_pyln_request_notify(node_factory):

Callers

nothing calls this directly

Calls 6

joinMethod · 0.80
plugin_startMethod · 0.80
listconfigsMethod · 0.80
plugin_stopMethod · 0.80
get_nodeMethod · 0.45
callMethod · 0.45

Tested by

no test coverage detected