2019-10-05 10:54:14 +00:00
|
|
|
name: CI
|
2019-10-05 10:56:30 +00:00
|
|
|
on: push
|
2019-10-05 10:54:14 +00:00
|
|
|
jobs:
|
2020-11-11 11:38:41 +00:00
|
|
|
test:
|
|
|
|
name: Unit tests
|
2019-10-05 13:19:06 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2020-11-11 11:38:41 +00:00
|
|
|
- name: Checkout sources
|
2023-12-30 11:31:55 +00:00
|
|
|
uses: actions/checkout@v4
|
2020-11-11 11:38:41 +00:00
|
|
|
- name: Install dependencies
|
|
|
|
run: npm install
|
|
|
|
- name: Run tests
|
|
|
|
run: npm test
|
2019-10-05 13:19:06 +00:00
|
|
|
|
2019-10-05 10:54:14 +00:00
|
|
|
smoke-test:
|
2020-11-11 11:38:41 +00:00
|
|
|
name: Build test
|
2019-10-05 10:58:19 +00:00
|
|
|
strategy:
|
2022-11-07 12:28:28 +00:00
|
|
|
fail-fast: false
|
2019-10-05 10:58:19 +00:00
|
|
|
matrix:
|
2019-10-05 11:01:01 +00:00
|
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
2023-12-30 11:27:39 +00:00
|
|
|
zig-version: [0.7.0, 0.8.0, 0.9.0, 0.10.0, 0.11.0]
|
2022-11-07 12:42:28 +00:00
|
|
|
include:
|
|
|
|
- os: ubuntu-latest
|
|
|
|
zig-version: 0.5.0
|
2019-10-05 11:01:01 +00:00
|
|
|
runs-on: ${{matrix.os}}
|
2019-10-05 10:54:14 +00:00
|
|
|
steps:
|
2020-11-11 11:38:41 +00:00
|
|
|
- name: Checkout sources
|
2023-12-30 11:31:55 +00:00
|
|
|
uses: actions/checkout@v4
|
2020-11-11 11:38:41 +00:00
|
|
|
- name: Install Zig
|
|
|
|
uses: goto-bus-stop/setup-zig@default
|
2019-10-05 10:57:26 +00:00
|
|
|
with:
|
2020-02-01 18:01:44 +00:00
|
|
|
version: ${{matrix.zig-version}}
|
2023-12-30 11:27:39 +00:00
|
|
|
- name: Run tests (zig up to v0.10.x)
|
|
|
|
if: ${{ !startsWith(matrix.zig-version, '0.11.') }}
|
|
|
|
run: zig build test
|
|
|
|
working-directory: test/v0.10
|
|
|
|
- name: Run tests (zig v0.11.x)
|
|
|
|
if: ${{ startsWith(matrix.zig-version, '0.11.') }}
|
2020-11-11 11:38:41 +00:00
|
|
|
run: zig build test
|
2023-12-30 11:27:39 +00:00
|
|
|
working-directory: test/v0.11
|