Skip to content

chore(deps): Bump step-security/harden-runner from 2.10.2 to 2.10.3 #166

chore(deps): Bump step-security/harden-runner from 2.10.2 to 2.10.3

chore(deps): Bump step-security/harden-runner from 2.10.2 to 2.10.3 #166

Workflow file for this run

name: Rust Test Suite
on:
push:
branches: ["main"]
paths:
- .github/workflows/*_rust.yml
- src/**
- tests/**
- Cargo.lock
- Cargo.toml
- deny.toml
pull_request:
paths:
- .github/workflows/*_rust.yml
- src/**
- tests/**
- Cargo.lock
- Cargo.toml
- deny.toml
permissions:
contents: read
jobs:
test:
name: Rust test
strategy:
matrix:
os:
- ubuntu-latest
- windows-latest
- macos-latest
runs-on: ${{matrix.os}}
steps:
- name: Harden Runner
uses: step-security/harden-runner@c95a14d0e5bab51a9f56296a4eb0e416910cd350 # v2.10.3
with:
egress-policy: audit
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: dtolnay/rust-toolchain@d0592fe69e35bc8f12e3dbaf9ad2694d976cb8e3 # stable
- uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab # v2.7.5
with:
shared-key: lang-rust-${{runner.os}}
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@6ec01d6033d5f6e87d04fc92d55eaa5b132b1ad4 # cargo-llvm-cov
- name: Run Cargo Clippy
run: cargo clippy
- name: Run Cargo Fmt
run: cargo fmt --check
- name: Run Cargo Deny
uses: EmbarkStudios/cargo-deny-action@e2f4ede4a4e60ea15ff31bc0647485d80c66cfba # v2.0.4
if: ${{ matrix.os == 'ubuntu-latest' }}
- name: Generate coverage report from Rust tests
run: cargo llvm-cov --all-features --lcov --output-path lcov.info
- name: Run examples
run: |
cargo run --example async_auto_fix
cargo run --example async_check
cargo run --example auto_fix
cargo run --example check
- name: Run doc tests
run: cargo test --doc
- uses: codecov/codecov-action@015f24e6818733317a2da2edd6290ab26238649a # v5.0.7
with:
files: lcov.info
flags: lang-rust