name: Check
on:
workflow_call:
inputs:
plan:
required: false
type: string
jobs:
check:
runs-on: ubuntu-latest
env:
PLAN: ${{ inputs.plan }}
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- name: Check formatting
run: cargo fmt --all -- --check
- name: Run clippy
run: cargo clippy --all-targets --all-features -- -D warnings
- name: Run tests
run: cargo test --all-features --lib --bins