Skip to content

Commit

Permalink
Fix examples not building in CI (#90)
Browse files Browse the repository at this point in the history
  • Loading branch information
Finomnis authored Nov 1, 2024
1 parent 689208e commit 8b2d7f1
Showing 1 changed file with 18 additions and 8 deletions.
26 changes: 18 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,23 @@ jobs:
uses: taiki-e/install-action@cross

- name: Build
run: cross build --all-features --all-targets --release --target=${{ matrix.target }}
run: cross build --all-features --release --target=${{ matrix.target }}

build-examples:
name: Build Examples
runs-on: ubuntu-latest
needs: [lints, docs]
env:
RUSTFLAGS: "-D warnings"
steps:
- name: Checkout sources
uses: actions/checkout@v4

- name: Install stable toolchain
uses: dtolnay/rust-toolchain@stable

- name: Build
run: cargo build --examples --all-features --release

test:
name: Test Suite
Expand All @@ -45,8 +61,6 @@ jobs:
- name: Install stable toolchain
uses: dtolnay/rust-toolchain@stable

#- uses: Swatinem/rust-cache@v1

- name: Run cargo test
run: cargo test -- --test-threads 1

Expand All @@ -66,8 +80,6 @@ jobs:
- name: Install cargo-msrv
run: cargo binstall --version 0.16.0-beta.17 --no-confirm cargo-msrv

#- uses: Swatinem/rust-cache@v1

- name: Check MSRV
run: cargo msrv verify --log-target=stdout --output-format=json

Expand Down Expand Up @@ -185,8 +197,6 @@ jobs:
- name: Install nightly toolchain
uses: dtolnay/rust-toolchain@nightly

#- uses: Swatinem/rust-cache@v1

- name: Build
env:
RUSTFLAGS: "-Z sanitizer=address"
Expand All @@ -205,7 +215,7 @@ jobs:
runs-on: ubuntu-latest
environment: production
if: github.event_name == 'release'
needs: [build, test, msrv, lints, docs, leaks, semver, min-versions, min-versions-msrv]
needs: [build, build-examples, test, msrv, lints, docs, leaks, semver, min-versions, min-versions-msrv]
steps:
- name: Checkout sources
uses: actions/checkout@v4
Expand Down

0 comments on commit 8b2d7f1

Please sign in to comment.