From e376f3a2f730471f9efbab441d6228eb85e3d8e4 Mon Sep 17 00:00:00 2001 From: Alfredo Garcia Date: Thu, 19 Sep 2024 18:03:06 -0300 Subject: [PATCH] restore env var --- zebra-rpc/qa/pull-tester/rpc-tests.py | 4 ++-- zebra-rpc/qa/rpc-tests/test_framework/test_framework.py | 4 ++-- zebra-rpc/qa/rpc-tests/test_framework/util.py | 5 +---- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/zebra-rpc/qa/pull-tester/rpc-tests.py b/zebra-rpc/qa/pull-tester/rpc-tests.py index 7ac0fb6b30..b754d04040 100755 --- a/zebra-rpc/qa/pull-tester/rpc-tests.py +++ b/zebra-rpc/qa/pull-tester/rpc-tests.py @@ -184,8 +184,8 @@ def run_tests(test_handler, test_list, src_dir, build_dir, exeext, jobs=1, enabl BOLD = ('\033[0m', '\033[1m') #Set env vars - #if "ZEBRAD" not in os.environ: - # os.environ["ZEBRAD"] = build_dir + '/target/debug/zebrad' + exeext + if "CARGO_BIN_EXE_zebrad" not in os.environ: + os.environ["CARGO_BIN_EXE_zebrad"] = os.path.join("..", "target", "debug", "zebrad") tests_dir = src_dir + '/qa/rpc-tests/' diff --git a/zebra-rpc/qa/rpc-tests/test_framework/test_framework.py b/zebra-rpc/qa/rpc-tests/test_framework/test_framework.py index 453034a316..a429064765 100755 --- a/zebra-rpc/qa/rpc-tests/test_framework/test_framework.py +++ b/zebra-rpc/qa/rpc-tests/test_framework/test_framework.py @@ -194,10 +194,10 @@ def __init__(self): def add_options(self, parser): parser.add_option("--testbinary", dest="testbinary", - default=os.getenv("ZEBRAD", zcashd_binary()), + default=os.getenv("CARGO_BIN_EXE_zebrad", zcashd_binary()), help="zebrad binary to test") parser.add_option("--refbinary", dest="refbinary", - default=os.getenv("ZEBRAD", zcashd_binary()), + default=os.getenv("CARGO_BIN_EXE_zebrad", zcashd_binary()), help="zebrad binary to use for reference nodes (if any)") def setup_network(self): diff --git a/zebra-rpc/qa/rpc-tests/test_framework/util.py b/zebra-rpc/qa/rpc-tests/test_framework/util.py index 28da9f0a29..c50e730307 100644 --- a/zebra-rpc/qa/rpc-tests/test_framework/util.py +++ b/zebra-rpc/qa/rpc-tests/test_framework/util.py @@ -51,11 +51,8 @@ # The number of ports to "reserve" for p2p and rpc, each PORT_RANGE = 5000 -def default_binary(): - return os.getenv("CARGO_BIN_EXE_zebrad", os.path.join("..", "target", "debug", "zebrad")) - def zcashd_binary(): - return os.getenv("ZEBRAD", default_binary()) + return os.getenv("CARGO_BIN_EXE_zebrad", os.path.join("..", "target", "debug", "zebrad")) def zebrad_config(datadir): base_location = os.path.join('qa', 'base_config.toml')