Skip to content

chore(deps): bump dependabot/fetch-metadata from 3.0.0 to 3.1.0 #348

chore(deps): bump dependabot/fetch-metadata from 3.0.0 to 3.1.0

chore(deps): bump dependabot/fetch-metadata from 3.0.0 to 3.1.0 #348

Workflow file for this run

name: CI
on:
pull_request:
push:
branches: [ main ]
env:
CARGO_TERM_COLOR: always
CARGO_DENY_VERSION: 0.18.9
CARGO_AUDIT_VERSION: 0.22.0
CARGO_LLVM_COV_VERSION: 0.6.19
CARGO_UDEPS_VERSION: 0.1.59
CARGO_ABOUT_VERSION: 0.8.4
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install Rust toolchain
run: |
rustup update stable
rustup default stable
rustup component add clippy rustfmt
rustup toolchain install nightly
- name: Cache cargo registry
uses: actions/cache@v5
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-
- name: Install cargo-binstall
uses: cargo-bins/cargo-binstall@v1.18.1
- name: Install cargo-deny
run: cargo binstall --no-confirm --locked --version ${{ env.CARGO_DENY_VERSION }} cargo-deny
- name: Install cargo-audit
run: cargo binstall --no-confirm --locked --version ${{ env.CARGO_AUDIT_VERSION }} cargo-audit
- name: Install cargo-udeps
run: cargo binstall --no-confirm --locked --version ${{ env.CARGO_UDEPS_VERSION }} cargo-udeps
- name: Install cargo-about
run: cargo binstall --no-confirm --locked --version ${{ env.CARGO_ABOUT_VERSION }} cargo-about
- name: Check formatting
run: cargo fmt --all -- --check
- name: Run clippy
run: cargo clippy -- -D warnings
- name: Build
run: cargo build --verbose
- name: Publish dry run
run: cargo publish --dry-run
- name: Run cargo deny
run: cargo deny check
- name: Run cargo audit
run: cargo audit
- name: Run cargo udeps (package dependencies)
run: cargo +nightly udeps
- name: Run cargo udeps (dev dependencies)
run: cargo +nightly udeps --all-features --all-targets
- name: Verify LICENSE-3RD-PARTY.txt is up to date
run: |
cargo about generate --frozen about.hbs > LICENSE-3RD-PARTY-generated.txt
if ! diff -q LICENSE-3RD-PARTY.txt LICENSE-3RD-PARTY-generated.txt > /dev/null; then
echo "ERROR: LICENSE-3RD-PARTY.txt is not up to date!"
echo "Please run: cargo about generate about.hbs > LICENSE-3RD-PARTY.txt"
echo "Differences found:"
diff LICENSE-3RD-PARTY.txt LICENSE-3RD-PARTY-generated.txt || true
exit 1
fi
rm LICENSE-3RD-PARTY-generated.txt
echo "LICENSE-3RD-PARTY.txt is up to date"
test-matrix:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
rust: [stable, beta]
exclude:
# Don't run beta on all platforms to save CI time
- os: windows-latest
rust: beta
- os: macos-latest
rust: beta
steps:
- uses: actions/checkout@v6
- name: Install Rust toolchain
run: |
rustup update ${{ matrix.rust }}
rustup default ${{ matrix.rust }}
- name: Install cargo-binstall
uses: cargo-bins/cargo-binstall@v1.18.1
- name: Install cargo-llvm-cov
shell: bash
run: cargo binstall --no-confirm --locked --version ${{ env.CARGO_LLVM_COV_VERSION }} cargo-llvm-cov
- name: Cache cargo registry
uses: actions/cache@v5
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-${{ matrix.rust }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-${{ matrix.rust }}-cargo-
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose --lib
- name: Generate coverage report
run: cargo llvm-cov --lib --verbose --lcov --output-path=unit-tests.lcov
- name: Upload coverage report
env:
COVERALLS_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
uses: coverallsapp/github-action@v2.3.6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: unit-tests.lcov
parallel: true
flag-name: ${{ matrix.os }}-${{ matrix.rust }}-unit-tests
# Minimum supported Rust version check
msrv:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install Rust 1.89
run: |
rustup update 1.89
rustup default 1.89
- name: Install cargo-binstall
uses: cargo-bins/cargo-binstall@v1.18.1
- name: Install cargo-deny
run: cargo binstall --no-confirm --locked --version ${{ env.CARGO_DENY_VERSION }} cargo-deny
- name: Check MSRV build
run: cargo check --verbose
e2e-tests:
runs-on: ubuntu-latest
services:
docker:
image: docker:dind
options: --privileged
ports:
- 2375:2375
container:
image: ubuntu:latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install dependencies
run: |
apt-get update
apt-get install -y curl gcc
- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Cache cargo-llvm-cov
uses: actions/cache@v5
with:
path: |
~/.cargo/bin
~/.rustup/toolchains
key: ${{ runner.os }}-cargo-llvm-cov-${{ env.CARGO_LLVM_COV_VERSION }}
restore-keys: |
${{ runner.os }}-cargo-llvm-cov-
# cargo-llvm-cov is not available in cargo-binstall yet, so we need to install it manually
- name: Install cargo-llvm-cov
shell: bash
run: |
if ! command -v cargo-llvm-cov &> /dev/null; then
cargo install --locked --version ${{ env.CARGO_LLVM_COV_VERSION }} cargo-llvm-cov
fi
- name: Run E2E Tests
run: cargo test --test '*' --workspace --exclude 'src/*' --verbose --features e2e-tests
- name: Generate coverage report
run: cargo llvm-cov --test '*' --workspace --exclude 'src/*' --verbose --features e2e-tests --lcov --output-path=e2e-tests.lcov
- name: Upload coverage report
uses: coverallsapp/github-action@v2.3.6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: e2e-tests.lcov
parallel: true
flag-name: ubuntu-latest-e2e-tests
coverage:
name: Report Coverage
runs-on: ubuntu-latest
needs: [test-matrix, e2e-tests]
steps:
- name: Send coverage
env:
COVERALLS_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
uses: coverallsapp/github-action@v2.3.6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true