From 1111108685ec0fd09b1e288b07c2b7982fc017e0 Mon Sep 17 00:00:00 2001 From: MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> Date: Tue, 10 Feb 2026 11:59:03 +0100 Subject: [PATCH] ci: [refactor] Move pyzmq install and get_previous_releases into ci-windows-cross.py --- .github/ci-windows-cross.py | 10 ++++++++++ .github/workflows/ci.yml | 9 +++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/.github/ci-windows-cross.py b/.github/ci-windows-cross.py index bacaffa03cf..84be2ed1001 100755 --- a/.github/ci-windows-cross.py +++ b/.github/ci-windows-cross.py @@ -4,6 +4,7 @@ # file COPYING or https://opensource.org/license/mit/. import argparse +import os import shlex import subprocess import sys @@ -70,6 +71,15 @@ def prepare_tests(): content = "\n".join(lines) + "\n" config_path.write_text(content) print(content) + previous_releases_dir = Path(os.environ["PREVIOUS_RELEASES_DIR"]) + cmd_download_prev_rel = [ + sys.executable, + str(workspace / "test" / "get_previous_releases.py"), + "--target-dir", + str(previous_releases_dir), + ] + run(cmd_download_prev_rel) + run([sys.executable, "-m", "pip", "install", "pyzmq"]) def main(): diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dff90ff856a..210bccc2c60 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -425,21 +425,18 @@ jobs: ./src/univalue/object.exe ./src/univalue/unitester.exe - - name: Adjust paths in test/config.ini - run: py -3 .github/ci-windows-cross.py prepare_tests - - name: Set previous release directory run: | echo "PREVIOUS_RELEASES_DIR=${{ runner.temp }}/previous_releases" >> "$GITHUB_ENV" - - name: Get previous releases - run: ./test/get_previous_releases.py --target-dir $PREVIOUS_RELEASES_DIR + - name: Prepare Windows test environment + run: | + py -3 .github/ci-windows-cross.py prepare_tests - name: Run functional tests env: TEST_RUNNER_EXTRA: ${{ github.event_name != 'pull_request' && '--extended' || '' }} run: | - py -3 -m pip install pyzmq py -3 test/functional/test_runner.py --jobs $NUMBER_OF_PROCESSORS --quiet --tmpdirprefix="$RUNNER_TEMP" --combinedlogslen=99999999 --timeout-factor=$TEST_RUNNER_TIMEOUT_FACTOR $TEST_RUNNER_EXTRA \ `# feature_unsupported_utxo_db.py fails on Windows because of emojis in the test data directory.` \ --exclude feature_unsupported_utxo_db.py \