From 6efae16f14c9bea6c3defcb2165a0e36a4161592 Mon Sep 17 00:00:00 2001 From: Kayshen-X Date: Sun, 5 Jul 2026 22:52:40 +0800 Subject: [PATCH] ci: split multiplatform host-test into two steps (avoid pwsh exit masking) Windows runs multi-line run: blocks under PowerShell, which reports only the last command's exit code. Keeping the workspace test and the serialized op-host-desktop test in one run: block would let a workspace-test failure be masked by the second command passing. Split into two steps so each fails the job independently. --- .github/workflows/rust-multiplatform.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/rust-multiplatform.yml b/.github/workflows/rust-multiplatform.yml index 33e246dd7..a05909a44 100644 --- a/.github/workflows/rust-multiplatform.yml +++ b/.github/workflows/rust-multiplatform.yml @@ -115,14 +115,18 @@ jobs: # STEP1A_REQUIRE_GPU=1 on a known-good GPU runner to fail hard. run: cargo test --workspace --target ${{ matrix.target }} - name: Test (host, macOS / Windows) + if: matrix.cross == false && matrix.check_only != true && runner.os != 'Linux' + run: cargo test --workspace --exclude op-host-desktop --target ${{ matrix.target }} + - name: Test op-host-desktop (host, macOS / Windows, serialized) if: matrix.cross == false && matrix.check_only != true && runner.os != 'Linux' # op-host-desktop's tests build native NativeBackends (skia / # DirectWrite fonts); across cargo's parallel test-worker threads this - # segfaults on the Windows runner (STATUS_ACCESS_VIOLATION). Split it - # out and serialize with --test-threads=1 (matches rust-check.yml). - run: | - cargo test --workspace --exclude op-host-desktop --target ${{ matrix.target }} - cargo test -p op-host-desktop --target ${{ matrix.target }} -- --test-threads=1 + # segfaults on the Windows runner (STATUS_ACCESS_VIOLATION). Run + # single-threaded (matches rust-check.yml). A SEPARATE step — not a + # second line in the step above — because Windows runs multi-line + # run: blocks under PowerShell, which only fails on the LAST command's + # exit code and would mask a failure in the workspace test above. + run: cargo test -p op-host-desktop --target ${{ matrix.target }} -- --test-threads=1 # Desktop binary artifact upload is intentionally not wired here yet. # The real desktop binary lives in the `op-host-desktop` crate; a # build + upload step can be added once release packaging is finalized.