Skip to content

Commit 99f5fc6

Browse files
committed
ci: tighten CI matrix — add macOS, release-mode tests, explicit build step
The CI workflow's unit-test job ran on ubuntu-latest + windows-latest; extend the matrix with macos-latest so the new CLI parser tests are exercised on every platform the binary ships for. socket-patch ships prebuilt binaries for x86_64-apple-darwin and aarch64-apple-darwin (see release.yml), so silent macOS-specific regressions in path handling, TTY detection, or terminal escapes are real risks today. Three changes: - Add `macos-latest` to the test matrix. - Add `fail-fast: false` so a failure on one OS doesn't mask failures on the others. - Add an explicit `cargo build --workspace --all-features` step before `cargo test`. `cargo test` already builds, but a dedicated build step gives a cleaner red signal when a build-only failure happens (e.g. a feature-gated compile error) without the noise of test-discovery output. - New `test-release` job: `cargo test --workspace --all-features --release` on ubuntu-latest. Catches optimization-level regressions that debug mode hides (e.g. release-mode-only inlining changes that affect assertion behavior). One OS keeps total CI time reasonable while still locking in release-mode correctness. Assisted-by: Claude Code:claude-opus-4-7
1 parent ef0deac commit 99f5fc6

1 file changed

Lines changed: 31 additions & 1 deletion

File tree

.github/workflows/ci.yml

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,9 @@ jobs:
3838

3939
test:
4040
strategy:
41+
fail-fast: false
4142
matrix:
42-
os: [ubuntu-latest, windows-latest]
43+
os: [ubuntu-latest, macos-latest, windows-latest]
4344
runs-on: ${{ matrix.os }}
4445
steps:
4546
- name: Checkout
@@ -62,9 +63,38 @@ jobs:
6263
key: ${{ matrix.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
6364
restore-keys: ${{ matrix.os }}-cargo-
6465

66+
- name: Build
67+
run: cargo build --workspace --all-features
68+
6569
- name: Run tests
6670
run: cargo test --workspace --all-features
6771

72+
test-release:
73+
runs-on: ubuntu-latest
74+
steps:
75+
- name: Checkout
76+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
77+
with:
78+
persist-credentials: false
79+
80+
- name: Install Rust
81+
uses: dtolnay/rust-toolchain@efa25f7f19611383d5b0ccf2d1c8914531636bf9 # stable
82+
with:
83+
toolchain: stable
84+
85+
- name: Cache cargo
86+
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4
87+
with:
88+
path: |
89+
~/.cargo/registry
90+
~/.cargo/git
91+
target
92+
key: ubuntu-latest-cargo-release-${{ hashFiles('**/Cargo.lock') }}
93+
restore-keys: ubuntu-latest-cargo-release-
94+
95+
- name: Run tests (release)
96+
run: cargo test --workspace --all-features --release
97+
6898
dispatch-tests:
6999
runs-on: ubuntu-latest
70100
steps:

0 commit comments

Comments
 (0)