chore: Bump dependencies #13
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: wot-serve | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
clippy-rustfmt: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Rust stable | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
components: clippy, rustfmt | |
- name: Run rustfmt | |
run: | |
cargo fmt --all -- --check --verbose | |
- name: Run cargo clippy | |
uses: giraffate/clippy-action@v1 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
clippy_flags: --all-targets -- -D warnings | |
reporter: github-pr-review | |
build-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Rust stable | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
- name: Build | |
run: cargo build --verbose --tests --benches | |
- name: Run tests | |
run: cargo test --verbose | |
- name: Generate docs | |
run: cargo doc --no-deps | |
cargo-deny: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: EmbarkStudios/cargo-deny-action@v2 | |
code-coverage: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Rust stable | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
- name: Install grcov | |
env: | |
GRCOV_LINK: https://github.com/mozilla/grcov/releases/download | |
GRCOV_VERSION: v0.8.7 | |
run: | | |
curl -L "$GRCOV_LINK/$GRCOV_VERSION/grcov-x86_64-unknown-linux-musl.tar.bz2" | | |
tar xj -C $HOME/.cargo/bin | |
- name: Install llvm-tools-preview | |
run: | | |
rustup component add llvm-tools-preview | |
# Not necessary on a newly created image, but strictly advised | |
- name: Run cargo clean | |
run: | | |
cargo clean | |
- name: Run tests | |
env: | |
CARGO_INCREMENTAL: 0 | |
LLVM_PROFILE_FILE: "wot-serve-%p-%m.profraw" | |
RUSTFLAGS: > | |
-Cinstrument-coverage -Ccodegen-units=1 -Clink-dead-code | |
-Coverflow-checks=off | |
RUSTDOCFLAGS: > | |
-Cinstrument-coverage -Ccodegen-units=1 -Clink-dead-code | |
-Coverflow-checks=off | |
run: | | |
cargo test --verbose | |
cargo run --example advertise | |
cargo run --example thing | |
- name: Get coverage data | |
run: | | |
grcov . --binary-path ./target/debug/ -s . -t lcov --branch \ | |
--ignore-not-existing --ignore "/*" --ignore "../*" -o lcov.info | |
- name: Codecov upload | |
uses: codecov/codecov-action@v3 | |
with: | |
files: lcov.info |