ci: condense the check, build, and test jobs into a single job since trying it the other way taught me that this will work better with the cache

This commit is contained in:
J / Jacob Babich
2024-09-25 14:37:21 -04:00
parent 40dc6916b6
commit c156157a59

View File

@@ -10,39 +10,7 @@ env:
CARGO_TERM_COLOR: always
jobs:
check:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Check
run: cargo check --verbose
build:
needs: check
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Build
run: cargo build --verbose
test:
needs: build
check-build-and-test:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
@@ -56,5 +24,11 @@ jobs:
- uses: Swatinem/rust-cache@v2
- name: Check
run: cargo check --verbose
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo nextest run