-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (47 loc) · 1.3 KB
/
test-code.yaml
File metadata and controls
53 lines (47 loc) · 1.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
name: ⌛ Test Code
on:
workflow_call:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test:
name: 🧪 Test on ${{ matrix.target }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
# Linux (x64)
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
# Linux (ARM)
- target: aarch64-unknown-linux-gnu
os: ubuntu-24.04-arm
# macOS (Intel)
- target: x86_64-apple-darwin
os: macos-latest
# macOS (ARM/M1)
- target: aarch64-apple-darwin
os: macos-latest
# Windows (GNU)
- target: x86_64-pc-windows-gnu
os: windows-latest
# Windows (MSVC)
- target: x86_64-pc-windows-msvc
os: windows-latest
# TODO: Run tests for android, pr wanted.
steps:
- name: 🛎️ Checkout code
uses: actions/checkout@v3
- name: 🦀 Set up Rust
uses: dtolnay/rust-toolchain@stable
with:
target: ${{ matrix.target }}
components: rustfmt, clippy
- name: 📦 Install Dependencies
run: cargo install cargo-nextest --locked
- name: 🧪 Run Tests
run: cargo nextest run --target ${{ matrix.target }}