2023-04-26 18:40:16 +01:00
|
|
|
name: 'CI'
|
|
|
|
# Makes some checks
|
|
|
|
|
2023-04-12 16:04:18 +01:00
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches: [ main ]
|
2023-04-26 18:40:16 +01:00
|
|
|
workflow_dispatch:
|
2023-04-12 16:04:18 +01:00
|
|
|
|
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
shell: bash
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
compat:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
zig: [ 0.6.0, 0.7.0, 0.8.0, 0.9.0, 0.10.0 ]
|
|
|
|
steps:
|
2023-04-26 18:40:16 +01:00
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v3
|
2023-04-12 16:04:18 +01:00
|
|
|
|
2023-04-26 18:40:16 +01:00
|
|
|
- name: Setup Zig
|
|
|
|
uses: goto-bus-stop/setup-zig@v2
|
|
|
|
with:
|
|
|
|
version: ${{ matrix.zig }}
|
2023-04-12 16:04:18 +01:00
|
|
|
|
2023-04-26 18:40:16 +01:00
|
|
|
- name: Check compatibility with old Zig compilers
|
|
|
|
run: ci/compat.sh
|
|
|
|
|
2023-04-28 12:10:37 +01:00
|
|
|
test-linux_mac:
|
2023-04-28 12:03:24 +01:00
|
|
|
name: Unit Tests
|
2023-04-25 14:25:07 +01:00
|
|
|
strategy:
|
|
|
|
matrix:
|
2023-04-28 12:03:24 +01:00
|
|
|
os: [ubuntu-latest, macos-latest]
|
2023-04-25 14:25:07 +01:00
|
|
|
runs-on: ${{ matrix.os }}
|
2023-04-26 18:40:16 +01:00
|
|
|
timeout-minutes: 30
|
2023-04-25 14:25:07 +01:00
|
|
|
steps:
|
2023-04-26 18:40:16 +01:00
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v3
|
2023-04-25 14:25:07 +01:00
|
|
|
|
2023-04-26 18:40:16 +01:00
|
|
|
- name: Setup Zig
|
|
|
|
uses: goto-bus-stop/setup-zig@v2
|
|
|
|
with:
|
|
|
|
version: master
|
2023-04-25 14:25:07 +01:00
|
|
|
|
2023-04-26 18:40:16 +01:00
|
|
|
- name: Run unit tests
|
|
|
|
run: zig build test
|
2023-04-28 12:03:24 +01:00
|
|
|
|
2023-04-28 12:10:37 +01:00
|
|
|
test-windows:
|
2023-04-28 12:03:24 +01:00
|
|
|
name: Unit Test Windows
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
runs-on: windows-latest
|
|
|
|
timeout-minutes: 30
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
|
|
|
|
- name: Setup Zig
|
|
|
|
uses: goto-bus-stop/setup-zig@v2
|
|
|
|
with:
|
|
|
|
version: master
|
|
|
|
|
|
|
|
- name: Run unit tests
|
|
|
|
run: zig build test
|
|
|
|
shell: pwsh
|