From 18974d9458d4d99f218ad0f93506acc344ba9141 Mon Sep 17 00:00:00 2001 From: tecnovert Date: Tue, 25 Oct 2022 21:44:01 +0200 Subject: [PATCH] test: Fix RESET_TEST=false --- bin/basicswap_prepare.py | 2 +- tests/basicswap/extended/test_xmr_persistent.py | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/bin/basicswap_prepare.py b/bin/basicswap_prepare.py index 4f835b4..3f2a444 100755 --- a/bin/basicswap_prepare.py +++ b/bin/basicswap_prepare.py @@ -1299,7 +1299,7 @@ def main(): with open(config_path, 'w') as fp: json.dump(settings, fp, indent=4) - logger.info('Done.') + logger.info(f'Done. Coin {add_coin} successfully added.') return 0 logger.info('With coins: %s', ', '.join(with_coins)) diff --git a/tests/basicswap/extended/test_xmr_persistent.py b/tests/basicswap/extended/test_xmr_persistent.py index 6d3ee18..8ed1d17 100644 --- a/tests/basicswap/extended/test_xmr_persistent.py +++ b/tests/basicswap/extended/test_xmr_persistent.py @@ -120,8 +120,11 @@ class Test(unittest.TestCase): random.seed(time.time()) - logging.info('Preparing %d nodes.', NUM_NODES) - prepare_nodes(NUM_NODES, 'bitcoin,monero', True, {'min_sequence_lock_seconds': 60}, PORT_OFS) + if os.path.exists(test_path) and not RESET_TEST: + logging.info(f'Continuing with existing directory: {test_path}') + else: + logging.info('Preparing %d nodes.', NUM_NODES) + prepare_nodes(NUM_NODES, 'bitcoin,monero', True, {'min_sequence_lock_seconds': 60}, PORT_OFS) signal.signal(signal.SIGINT, lambda signal, frame: cls.signal_handler(cls, signal, frame))