chore(zig): update to 0.14 #20
This file contains 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
name: ci | |
on: | |
pull_request: | |
branches: [ main ] | |
push: | |
branches: [ main ] | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
unit-tests: | |
name: Build and Unit Tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: goto-bus-stop/setup-zig@v2 | |
with: | |
version: 0.14.0 | |
- name: Build Examples | |
run: zig build | |
- name: Run unit tests | |
run: zig build test --summary all | |
linux-pipeline: | |
name: Linux Pipeline | |
needs: unit-tests | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
async: [io_uring, epoll, poll] | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: goto-bus-stop/setup-zig@v2 | |
with: | |
version: 0.14.0 | |
- name: Generate random 64-bit integer | |
id: random | |
shell: bash | |
run: echo "RANDOM_INT=$(shuf -i 1-9223372036854775807 -n 1)" >> $GITHUB_ENV | |
- name: Run E2E tests with ${{ matrix.async }} | |
run: zig build -Dasync=${{ matrix.async }} test_e2e -- ${{ env.RANDOM_INT }} | |
macos-pipeline: | |
name: macOS Pipeline | |
needs: unit-tests | |
runs-on: macos-latest | |
strategy: | |
matrix: | |
async: [kqueue, poll] | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: goto-bus-stop/setup-zig@v2 | |
with: | |
version: 0.14.0 | |
- name: Generate random 64-bit integer | |
id: random | |
shell: bash | |
run: echo "RANDOM_INT=$((RANDOM + (RANDOM << 15) + (RANDOM << 30) + (RANDOM << 45)))" >> $GITHUB_ENV | |
- name: Run E2E tests with ${{ matrix.async }} | |
run: zig build -Dasync=${{ matrix.async }} test_e2e -- ${{ env.RANDOM_INT }} | |
windows-pipeline: | |
name: Windows Pipeline | |
needs: unit-tests | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: goto-bus-stop/setup-zig@v2 | |
with: | |
version: 0.14.0 | |
- name: Generate random 64-bit integer | |
id: random | |
shell: pwsh | |
run: echo "RANDOM_INT=$([long]::Parse([math]::Floor([decimal](Get-Random -Minimum 1 -Maximum 9223372036854775807)).ToString()))" >> $env:GITHUB_ENV | |
- name: Run E2E tests with poll | |
run: zig build -Dasync=poll test_e2e -- ${{ env.RANDOM_INT }} |