name: Rust CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- runner: ubuntu-latest
- runner: macos-13
- runner: macos-latest
- runner: windows-latest
runs-on: ${{ matrix.runner }}
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: taiki-e/install-action@v2
with:
tool: cargo-nextest
- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: rustfmt, clippy
override: true
- name: Check formatting
run: cargo fmt -- --check
- name: Run Clippy
run: cargo clippy --all-targets -- -D warnings
- name: Run tests
run: cargo nextest run