mirror of
https://github.com/Xevion/Pac-Man.git
synced 2025-12-10 00:07:52 -06:00
This is just because managing both 1.86 and 1.88 is really annoying, so it's better to just be unified. There's no real point to using 1.88 besides more clippy warnings, which are already impeding my work right now. So we're downgrading.
59 lines
1.3 KiB
YAML
59 lines
1.3 KiB
YAML
name: Tests & Checks
|
|
|
|
on: ["push", "pull_request"]
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
RUST_TOOLCHAIN: 1.86.0
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install Rust toolchain
|
|
uses: dtolnay/rust-toolchain@master
|
|
with:
|
|
toolchain: ${{ env.RUST_TOOLCHAIN }}
|
|
components: clippy, rustfmt
|
|
|
|
- name: Rust Cache
|
|
uses: Swatinem/rust-cache@v2
|
|
|
|
- name: Cache vcpkg
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: target/vcpkg
|
|
key: A-vcpkg-${{ runner.os }}-${{ hashFiles('Cargo.toml', 'Cargo.lock') }}
|
|
restore-keys: |
|
|
A-vcpkg-${{ runner.os }}-
|
|
|
|
- name: Vcpkg Linux Dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y libltdl-dev
|
|
|
|
- name: Vcpkg
|
|
run: |
|
|
cargo install cargo-vcpkg
|
|
cargo vcpkg -v build
|
|
|
|
- uses: taiki-e/install-action@nextest
|
|
|
|
- name: Run nextest
|
|
run: cargo nextest run --workspace
|
|
|
|
- name: Run clippy
|
|
run: cargo clippy -- -D warnings
|
|
|
|
- name: Check formatting
|
|
run: cargo fmt -- --check
|
|
|
|
- uses: taiki-e/install-action@cargo-audit
|
|
|
|
- name: Run security audit
|
|
run: cargo audit
|