mirror of
https://github.com/NLnetLabs/krill.git
synced 2026-08-21 15:12:33 +02:00
41 lines
1.1 KiB
YAML
41 lines
1.1 KiB
YAML
name: Coverage
|
|
|
|
on:
|
|
#workflow_run:
|
|
# workflows: ["CI"]
|
|
# types:
|
|
# - completed
|
|
|
|
# Allow triggering manually.
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
coverage:
|
|
name: coverage
|
|
if: ${{ github.event.workflow_run.conclusion == 'success' }}
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
os: [ubuntu-latest]
|
|
rust: [stable]
|
|
args: ["", "--all-features"]
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
with:
|
|
# at the time of writing workflow_run.head_commit.id appears to be
|
|
# the commit that triggered the CI workflow which then triggered us.
|
|
ref: ${{ github.event.workflow_run.head_commit.id }}
|
|
- name: Install Rust
|
|
uses: hecrj/setup-rust-action@v1
|
|
with:
|
|
rust-version: ${{ matrix.rust }}
|
|
- run: cargo install cargo-tarpaulin
|
|
- run: cargo tarpaulin --locked --verbose --out Html ${{ matrix.args }}
|
|
- name: Archive code coverage results
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: code-coverage-report ${{ matrix.os }} ${{ matrix.rust }} ${{ matrix.args }}
|
|
path: tarpaulin-report.html
|
|
|