Skip to content

Commit f9cb363

Browse files
committed
Add test matrix for multiple toolchains
Including 1.81, our minimum, plus stable and nightly.
1 parent 27b5bc0 commit f9cb363

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

.github/workflows/tests.yml

+10-7
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,21 @@ on:
44
push:
55
pull_request:
66
workflow_dispatch:
7-
# used when called manually.
8-
workflow_call:
9-
# used when called by _another_ workflow (not when called on this repo!)
107

118
jobs:
129
test:
1310
runs-on: ubuntu-latest
11+
strategy:
12+
matrix:
13+
rust-toolchain:
14+
- "1.81" # minimum for this crate
15+
- "stable"
16+
- "nightly"
1417
steps:
15-
- uses: actions/checkout@v4 # not pinning to commit since this is a GitHub action, which we trust
18+
- uses: actions/checkout@v4 # not pinning to commit hash since this is a GitHub action, which we trust
1619
- id: cache-cargo
1720
name: Cache Cargo toolchain
18-
uses: actions/cache@v4 # not pinning to commit since this is a GitHub action, which we trust
21+
uses: actions/cache@v4 # not pinning to commit hash since this is a GitHub action, which we trust
1922
with:
2023
path: |
2124
~/.cargo/bin/
@@ -26,10 +29,10 @@ jobs:
2629
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}-release
2730
- if: ${{ steps.cache-cargo.outputs.cache-hit != 'true' }}
2831
name: Install Rust toolchain
29-
uses: actions-rs/toolchain@v1 # not pinning to commit since this is an archived GitHub action, which we trust
32+
uses: actions-rs/toolchain@v1 # not pinning to commit hash since this is an archived GitHub action, which we trust
3033
with:
3134
profile: minimal
32-
toolchain: stable
35+
toolchain: ${{ matrix.rust-toolchain }}
3336
override: true
3437
- name: Architecture check
3538
run: cargo run arch-check

0 commit comments

Comments
 (0)