mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 15:14:23 +01:00
plugin: Add a test for timeout and broken manifest
Both of these plugins will fail in interesting ways, and we should still handle them correctly. Signed-off-by: Christian Decker <decker.christian@gmail.com>
This commit is contained in:
committed by
Rusty Russell
parent
bd6ce102e6
commit
f5a3f1f0a2
@@ -77,3 +77,18 @@ def test_plugin_disable(node_factory):
|
||||
'helloworld.py')]))
|
||||
with pytest.raises(RpcError):
|
||||
n.rpc.hello(name='Sun')
|
||||
|
||||
|
||||
def test_failing_plugins():
|
||||
fail_plugins = [
|
||||
'contrib/plugins/fail/failtimeout.py',
|
||||
'contrib/plugins/fail/doesnotexist.py',
|
||||
]
|
||||
|
||||
for p in fail_plugins:
|
||||
with pytest.raises(subprocess.CalledProcessError):
|
||||
subprocess.check_output([
|
||||
'lightningd/lightningd',
|
||||
'--plugin={}'.format(p),
|
||||
'--help',
|
||||
])
|
||||
|
||||
Reference in New Issue
Block a user