From 7915a9d67811b2db79adacef5cbc45423f7fa565 Mon Sep 17 00:00:00 2001 From: Alex Myers Date: Tue, 25 Jul 2023 14:54:21 -0500 Subject: [PATCH] pytest: add reckless local install test --- tests/test_reckless.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/tests/test_reckless.py b/tests/test_reckless.py index 794264f80..ac4f0db19 100644 --- a/tests/test_reckless.py +++ b/tests/test_reckless.py @@ -159,6 +159,22 @@ def test_install(node_factory): assert os.path.exists(plugin_path) +def test_local_dir_install(node_factory): + """Test search and install from local directory source.""" + n = get_reckless_node(node_factory) + n.start() + r = reckless([f"--network={NETWORK}", "-v", "source", "add", + "tests/data/recklessrepo/lightningd/testplugpass"], + dir=n.lightning_dir) + assert r.returncode == 0 + r = reckless([f"--network={NETWORK}", "-v", "install", "testplugpass"], dir=n.lightning_dir) + assert r.returncode == 0 + assert 'testplugpass enabled' in r.stdout + plugin_path = Path(n.lightning_dir) / 'reckless/testplugpass' + print(plugin_path) + assert os.path.exists(plugin_path) + + def test_disable_enable(node_factory): """test search, git clone, and installation to folder.""" n = get_reckless_node(node_factory)