Skip to content

Commit

Permalink
ci: add proper msrv and beta version test (#86)
Browse files Browse the repository at this point in the history
Signed-off-by: gruebel <[email protected]>
  • Loading branch information
gruebel authored Sep 2, 2024
1 parent 9cb0990 commit 56af10a
Show file tree
Hide file tree
Showing 4 changed files with 743 additions and 19 deletions.
35 changes: 23 additions & 12 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,30 +18,41 @@ env:
jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
rust:
- 1.67.1 # MSRV
- stable
- beta
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4

- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: ${{ matrix.rust }}

- name: Setup cache
uses: Swatinem/rust-cache@v2
- if: matrix.rust == '1.67.1'
name: Use MSRV lock file
run: cp Cargo.lock.msrv Cargo.lock

- name: Build
run: cargo build --verbose
- name: Build
run: cargo build --verbose

- name: Run tests
run: cargo test --verbose
- name: Run tests
run: cargo test --verbose

lint:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Check formats
run: cargo fmt --check
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: stable

- name: Setup cache
uses: Swatinem/rust-cache@v2
- name: Check formats
run: cargo fmt --check --all

- name: Check code quality
run: cargo clippy -- -D warnings
Loading

0 comments on commit 56af10a

Please sign in to comment.