Cross-Platform Build & Test #271
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # SPDX-License-Identifier: MPL-2.0 | |
| # Cross-platform CI for Game Server Admin | |
| # Builds and tests on Linux, macOS, and Windows | |
| name: Cross-Platform Build & Test | |
| on: | |
| push: | |
| branches: [main, 'claude/**'] | |
| pull_request: | |
| branches: [main] | |
| permissions: | |
| actions: read | |
| contents: read | |
| jobs: | |
| build-and-test: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| # Linux only for now; macOS/Windows deferred to the cross-platform | |
| # effort. Kept as a matrix so re-adding os/name there is trivial. | |
| - os: ubuntu-latest | |
| name: Linux | |
| run-integration: true | |
| name: ${{ matrix.name }} | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| - name: Install Zig 0.15.2 | |
| uses: mlugg/setup-zig@d1434d08867e3ee9daa34448df10607b98908d29 # v2.2.1 | |
| with: | |
| version: 0.15.2 | |
| - name: Cache Zig | |
| uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0 | |
| with: | |
| path: | | |
| ~/.cache/zig | |
| ~/AppData/Local/zig | |
| key: zig-${{ matrix.os }}-${{ hashFiles('src/interface/ffi/build.zig') }} | |
| - name: Build | |
| working-directory: src/interface/ffi | |
| run: zig build | |
| - name: Unit Tests | |
| working-directory: src/interface/ffi | |
| run: zig build test | |
| - name: Integration Tests (Linux only) | |
| if: matrix.run-integration | |
| working-directory: src/interface/ffi | |
| run: zig build test-integration | |
| - name: Smoke Tests | |
| working-directory: src/interface/ffi | |
| run: zig build test-smoke | |
| - name: Property Tests | |
| working-directory: src/interface/ffi | |
| run: zig build test-property | |
| - name: Behavioral Tests (mock servers) | |
| working-directory: src/interface/ffi | |
| run: zig build test-behavioral | |
| - name: CLI Tests | |
| working-directory: src/interface/ffi | |
| run: zig build test-cli | |
| - name: Fuzz seed corpus | |
| working-directory: src/interface/ffi | |
| run: zig build fuzz |