Workflow performing CI step: coverage #5
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: CI-coverage | |
run-name: "Workflow performing CI step: coverage" | |
on: | |
pull_request: | |
types: [opened, synchronize] | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
env: | |
RUST_BACKTRACE: 1 | |
jobs: | |
coverage: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout branch | |
uses: actions/checkout@v4 | |
- name: Install coverage tools | |
run: | | |
cargo install --force cargo-llvm-cov | |
- name: Coverage tasks | |
run: | | |
cargo llvm-cov --workspace --lcov --output-path lcov.info | |
cargo llvm-cov report --json --output-path coverage_report.json --summary-only | |
cargo llvm-cov report > coverage-summary.txt | |
cat coverage-summary.txt | |
- name: Upload json summary as Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: coverage-output | |
path: ./coverage_report.json | |
if-no-files-found: warn | |
retention-days: 1 | |
compression-level: 0 | |
overwrite: true | |
# It is also possible to upload the generated lcov.info for later use with Codecov | |
# (see https://llvm.org/docs/CommandGuide/llvm-profdata.html) |