From fa2719ab1ba2252b53609e254413a38ac2097dc9 Mon Sep 17 00:00:00 2001 From: MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> Date: Tue, 10 Feb 2026 12:53:51 +0100 Subject: [PATCH] ci: [refactor] Move run_unit_tests to ci-windows-cross.py --- .github/ci-windows-cross.py | 19 +++++++++++++++++++ .github/workflows/ci.yml | 10 +--------- 2 files changed, 20 insertions(+), 9 deletions(-) diff --git a/.github/ci-windows-cross.py b/.github/ci-windows-cross.py index 9b59f2a2a3b..13ca3b49456 100755 --- a/.github/ci-windows-cross.py +++ b/.github/ci-windows-cross.py @@ -116,12 +116,29 @@ def run_functional_tests(): run(cmd_feature_unsupported_db) +def run_unit_tests(): + # Can't use ctest here like other jobs as we don't have a CMake build tree. + commands = [ + ["./bin/test_bitcoin-qt.exe"], + # Intentionally run sequentially here, to catch test case failures caused by dirty global state from prior test cases: + ["./bin/test_bitcoin.exe", "-l", "test_suite"], + ["./src/secp256k1/bin/exhaustive_tests.exe"], + ["./src/secp256k1/bin/noverify_tests.exe"], + ["./src/secp256k1/bin/tests.exe"], + ["./src/univalue/object.exe"], + ["./src/univalue/unitester.exe"], + ] + for cmd in commands: + run(cmd) + + def main(): parser = argparse.ArgumentParser(description="Utility to run Windows CI steps.") steps = [ "print_version", "check_manifests", "prepare_tests", + "run_unit_tests", "run_functional_tests", ] parser.add_argument("step", choices=steps, help="CI step to perform.") @@ -138,6 +155,8 @@ def main(): check_manifests() elif args.step == "prepare_tests": prepare_tests() + elif args.step == "run_unit_tests": + run_unit_tests() elif args.step == "run_functional_tests": run_functional_tests() diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c821999ef42..c86832b4c06 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -415,15 +415,7 @@ jobs: run: py -3 .github/ci-windows-cross.py check_manifests - name: Run unit tests - # Can't use ctest here like other jobs as we don't have a CMake build tree. - run: | - ./bin/test_bitcoin-qt.exe - ./bin/test_bitcoin.exe -l test_suite # Intentionally run sequentially here, to catch test case failures caused by dirty global state from prior test cases. - ./src/secp256k1/bin/exhaustive_tests.exe - ./src/secp256k1/bin/noverify_tests.exe - ./src/secp256k1/bin/tests.exe - ./src/univalue/object.exe - ./src/univalue/unitester.exe + run: py -3 .github/ci-windows-cross.py run_unit_tests - name: Prepare Windows test environment run: |