name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
jobs:
check:
name: Check
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Check
shell: bash
run: |
cargo fmt --all -- --check
cargo clippy --all-targets --all-features -- -D warnings
make:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Test
shell: bash
run: cargo test
timeout-minutes: 5
- name: Examples (basic)
shell: bash
run: cargo run --example basic
timeout-minutes: 5
- name: Examples (stdio)
shell: bash
run: cargo run --example basic
timeout-minutes: 5