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

Function _pyln_has_inline_plugin

tests/test_pay.py:7406–7415  ·  view source on GitHub ↗

Did pyln-testing gain get_node(inline_plugin=...) yet? It arrived after this branch forked, and get_node() takes **kwargs, so on a branch without it the argument is silently swallowed and the plugin never loads. Detect it rather than let the test fail somewhere unrelated.

()

Source from the content-addressed store, hash-verified

7404
7405
7406def _pyln_has_inline_plugin():
7407 """Did pyln-testing gain get_node(inline_plugin=...) yet?
7408
7409 It arrived after this branch forked, and get_node() takes **kwargs, so on a
7410 branch without it the argument is silently swallowed and the plugin never
7411 loads. Detect it rather than let the test fail somewhere unrelated.
7412 """
7413 import inspect
7414 from pyln.testing.utils import NodeFactory
7415 return 'inline_plugin' in inspect.signature(NodeFactory.get_node).parameters
7416
7417
7418@unittest.skipIf(not _pyln_has_inline_plugin(),

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected