mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-24 01:24:26 +01:00
cln-plugin: Add support for synchronous RPC methods
Changelog-Experimental: cln-plugin: Added support for non-async RPC method passthrough (async support coming soon)
This commit is contained in:
committed by
Rusty Russell
parent
22618a2f94
commit
8c6af21169
@@ -37,3 +37,18 @@ def test_plugin_start(node_factory):
|
||||
'path': None
|
||||
}
|
||||
assert expected == p
|
||||
|
||||
# Now check that the `testmethod was registered ok
|
||||
l1.rpc.help("testmethod") == {
|
||||
'help': [
|
||||
{
|
||||
'command': 'testmethod ',
|
||||
'category': 'plugin',
|
||||
'description': 'This is a test',
|
||||
'verbose': 'This is a test'
|
||||
}
|
||||
],
|
||||
'format-hint': 'simple'
|
||||
}
|
||||
|
||||
assert l1.rpc.testmethod() == "Hello"
|
||||
|
||||
Reference in New Issue
Block a user