name: CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
test:
name: Build & test on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
timeout-minutes: 35
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- name: Add x86_64 target (macOS ARM)
if: runner.os == 'macOS'
run: rustup target add x86_64-apple-darwin
- name: Build
run: cargo build --verbose
- name: Clippy
run: cargo clippy
- name: Run tests
run: make tests