| 1 | name: CI |
| 2 | |
| 3 | on: |
| 4 | push: |
| 5 | branches: [ main ] |
| 6 | pull_request: |
| 7 | branches: [ main ] |
| 8 | |
| 9 | jobs: |
| 10 | ci: |
| 11 | name: Check, test, rustfmt and clippy |
| 12 | runs-on: ubuntu-latest |
| 13 | steps: |
| 14 | - uses: actions/checkout@v4 |
| 15 | |
| 16 | - name: Install Rust, clippy and rustfmt |
| 17 | uses: dtolnay/rust-toolchain@stable |
| 18 | with: |
| 19 | components: clippy, rustfmt |
| 20 | |
| 21 | - name: Check |
| 22 | run: | |
| 23 | cargo check --workspace --all-features |
| 24 | |
| 25 | - name: Test |
| 26 | run: | |
| 27 | cargo test --workspace --all-features |
| 28 | |
| 29 | - name: Rustfmt |
| 30 | run: | |
| 31 | cargo fmt --all --check |
| 32 | |
| 33 | - name: Clippy |
| 34 | run: | |
| 35 | cargo clippy --workspace --all-features --all-targets --tests -- --deny warnings |