Skip to content

Fix CI failures (clippy + fmt) and document test runner #6

Fix CI failures (clippy + fmt) and document test runner

Fix CI failures (clippy + fmt) and document test runner #6

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: rustup component add rustfmt
- run: cargo fmt --check
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: rustup component add clippy
- uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: clippy-${{ hashFiles('**/Cargo.lock') }}
- run: cargo clippy -- -D warnings
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: check-${{ hashFiles('**/Cargo.lock') }}
- run: cargo check --workspace
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: test-${{ hashFiles('**/Cargo.lock') }}
- run: cargo test --workspace
machete:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: cargo install cargo-machete
- run: cargo machete