All checks were successful
CI / test (pull_request) Successful in 14m6s
push and pull_request both fired for commits on a branch with an open PR. Scope push to master only, matching sporah's workflow, so branch commits trigger just the pull_request run.
35 lines
697 B
YAML
35 lines
697 B
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [master]
|
|
pull_request:
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: rust-ci
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Cache cargo registry and build artifacts
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: |
|
|
~/.cargo/registry
|
|
~/.cargo/git
|
|
target
|
|
key: cargo-${{ runner.os }}-${{ hashFiles('Cargo.lock') }}
|
|
restore-keys: |
|
|
cargo-${{ runner.os }}-
|
|
|
|
- name: Check formatting
|
|
run: cargo fmt -- --check
|
|
|
|
- name: Lint
|
|
run: cargo clippy --all-targets -- -D warnings
|
|
|
|
- name: Build
|
|
run: cargo build
|
|
|
|
- name: Test
|
|
run: cargo test
|