forked from madara-alliance/madara-orchestrator
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (29 loc) · 1.01 KB
/
coverage.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
---
name: Task - Rust Tests & Coverage
on:
workflow_dispatch:
workflow_call:
jobs:
coverage:
# sadly, for now we have to "rebuild" for the coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# selecting a toolchain either by action or manual `rustup` calls should happen
# before the plugin, as the cache uses the current rustc version as its cache key
- run: rustup show
- uses: taiki-e/install-action@cargo-llvm-cov
- uses: taiki-e/install-action@nextest
- name: Clean workspace
run: |
cargo llvm-cov clean --workspace
- name: Run llvm-cov
run: |
cargo llvm-cov nextest --release --lcov --output-path lcov.info --test-threads=1
- name: Upload coverage to codecov.io
uses: codecov/codecov-action@v3
with:
files: lcov.info
fail_ci_if_error: false
- uses: colpal/actions-clean@v1
if: ${{ always() }} # To ensure this step runs even when earlier steps fail