Skip to content

Commit

Permalink
Test on Rust 1.80 and stable
Browse files Browse the repository at this point in the history
  • Loading branch information
spenserblack committed Aug 9, 2024
1 parent 927aef6 commit b3fb96f
Showing 1 changed file with 30 additions and 7 deletions.
37 changes: 30 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,19 @@ jobs:
feature-flags:
- --no-default-features
- --no-default-features --features color
rust-version:
- "1.80"
- "stable"

steps:
- uses: actions/checkout@v4
- name: Fetch Test Branches
run: git fetch origin test/javascript:test/javascript
- name: Setup Rust ${{ matrix.rust-version }}
uses: dtolnay/rust-toolchain@master
id: setup-rust
with:
toolchain: ${{ matrix.rust-version }}
- name: Cache
uses: actions/cache@v4
with:
Expand All @@ -37,7 +45,7 @@ jobs:
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
key: ${{ runner.os }}-${{ steps.setup-rust.outputs.cachekey }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Build
run: cargo build --verbose ${{ matrix.feature-flags }}
Expand All @@ -58,13 +66,20 @@ jobs:
feature-flags:
- --no-default-features
- --no-default-features --features color
rust-version:
- "1.80"
env:
TARPAULIN_VERSION: "0.30.0"

steps:
- uses: actions/checkout@v4
- name: Fetch Test Branches
run: git fetch origin test/javascript:test/javascript
- name: Setup Rust ${{ matrix.rust-version }}
uses: dtolnay/rust-toolchain@master
id: setup-rust
with:
toolchain: ${{ matrix.rust-version }}
- name: Main Cache
uses: actions/cache@v4
with:
Expand All @@ -73,14 +88,14 @@ jobs:
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
key: ${{ runner.os }}-${{ steps.setup-rust.outputs.cachekey }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Bin Cache
id: bin-cache
uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
key: ${{ runner.os }}-cargo-bin-tarpaulin-${{ env.TARPAULIN_VERSION }}
key: ${{ runner.os }}-${{ steps.setup-rust.outputs.cachekey }}-cargo-bin-tarpaulin-${{ env.TARPAULIN_VERSION }}
- name: Install Tarpualin
if: steps.bin-cache.outputs.cache-hit != 'true'
run: cargo install "cargo-tarpaulin@$TARPAULIN_VERSION"
Expand All @@ -101,7 +116,11 @@ jobs:
- build
steps:
- uses: actions/checkout@v4

- name: Setup Rust ${{ matrix.rust-version }}
uses: dtolnay/rust-toolchain@master
id: setup-rust
with:
toolchain: ${{ matrix.rust-version }}
- name: Cache
uses: actions/cache@v4
with:
Expand All @@ -110,7 +129,7 @@ jobs:
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
key: ${{ runner.os }}-${{ steps.setup-rust.outputs.cachekey }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Check Format
run: cargo fmt -- --check
Expand Down Expand Up @@ -138,7 +157,11 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 3

- name: Setup Rust 1.80
uses: dtolnay/rust-toolchain@master
id: setup-rust
with:
toolchain: "1.80"
- name: Cache
uses: actions/cache@v4
with:
Expand All @@ -147,7 +170,7 @@ jobs:
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
key: ${{ runner.os }}-${{ steps.setup-rust.outputs.cachekey }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Fetch Test Branches
run: git fetch origin test/javascript:test/javascript
Expand Down

0 comments on commit b3fb96f

Please sign in to comment.