ci: T16 — wire cross-stack hang interop suite into build.yml
Adds a hang-interop job that runs after lint and exercises the :nestsClient:jvmTest suite under -DnestsHangInterop=true. Cargo registry + cli/hang-interop/target are cached on the Cargo.lock + REV file hashes so cold runs (~6 min for the moq-relay install) only happen on dependency change; warm runs finish in seconds. Linux-only — the protocol logic is platform-agnostic and the JNA libopus natives are already exercised by JvmOpusRoundTripTest on the Android job. macOS / Windows interop runs would double the matrix cost without catching new defects. Pinned to dtolnay/rust-toolchain@stable; ubuntu-latest's bundled Rust drifts and moq-relay 0.10.25 needs ≥ 1.95 (the constant_time_eq 0.4.3 transitive dep). https://claude.ai/code/session_01ERJPUYfdLPwZ99pr5EcEcV
This commit is contained in:
@@ -171,6 +171,71 @@ jobs:
|
||||
name: ${{ matrix.desktop-artifact-name }}
|
||||
path: ${{ matrix.desktop-artifact-path }}
|
||||
|
||||
# Cross-stack interop tests (T16). Builds the Rust hang-listen +
|
||||
# hang-publish sidecars (cli/hang-interop/), `cargo install`s
|
||||
# moq-relay + moq-token-cli at the version pinned in
|
||||
# `cli/hang-interop/REV`, then runs `:nestsClient:jvmTest
|
||||
# -DnestsHangInterop=true`. See
|
||||
# `nestsClient/plans/2026-05-06-cross-stack-interop-test.md`.
|
||||
#
|
||||
# Linux-only: the cargo install of `moq-relay` 0.10.x has nontrivial
|
||||
# native deps (aws-lc-sys, ring) that take 5+ min cold; we cache
|
||||
# both ~/.cargo and the cli/hang-interop/target tree so the warm
|
||||
# path is a few seconds. macOS / Windows runs would double the
|
||||
# matrix cost without catching anything Linux doesn't catch — the
|
||||
# protocol logic is platform-agnostic and the JNA libopus natives
|
||||
# are already exercised by the unit-level JvmOpusRoundTripTest on
|
||||
# the Android job.
|
||||
hang-interop:
|
||||
needs: lint
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Set up JDK 21
|
||||
uses: actions/setup-java@v5
|
||||
with:
|
||||
distribution: 'zulu'
|
||||
java-version: 21
|
||||
|
||||
- name: Set up Gradle
|
||||
uses: gradle/actions/setup-gradle@v4
|
||||
with:
|
||||
cache-read-only: ${{ github.ref != 'refs/heads/main' }}
|
||||
|
||||
# Pin Rust to ≥ 1.95 — moq-relay 0.10.25's transitive dep
|
||||
# `constant_time_eq 0.4.3` requires it, and ubuntu-latest's
|
||||
# default Rust version drifts.
|
||||
- name: Set up Rust
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
|
||||
# Cache cargo registry + the sidecar workspace's target/.
|
||||
# First cold run takes ~6 min for the moq-relay install;
|
||||
# cached runs ~30 s.
|
||||
- name: Cache cargo
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/registry
|
||||
~/.cargo/git
|
||||
cli/hang-interop/target
|
||||
~/.cache/amethyst-nests-interop/hang-interop-cargo
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('cli/hang-interop/Cargo.lock', 'cli/hang-interop/REV') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-cargo-
|
||||
|
||||
- name: Run cross-stack interop suite
|
||||
run: ./gradlew :nestsClient:jvmTest -DnestsHangInterop=true
|
||||
|
||||
- name: Upload interop test report
|
||||
uses: actions/upload-artifact@v7
|
||||
if: failure()
|
||||
with:
|
||||
name: Hang Interop Test Reports
|
||||
path: nestsClient/build/reports/tests/jvmTest/
|
||||
|
||||
test-and-build-android:
|
||||
needs: lint
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
Reference in New Issue
Block a user