-
Notifications
You must be signed in to change notification settings - Fork 25
50 lines (41 loc) · 1.13 KB
/
codecov.yaml
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
39
40
41
42
43
44
45
46
47
48
49
50
name: Coverage
on:
pull_request:
push:
branches:
- main
- releases/**
jobs:
coverage:
runs-on: ubuntu-8-core-32-gb
env:
CARGO_TERM_COLOR: always
steps:
- uses: actions/checkout@v4
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.73.0
override: true
- name: Install protoc
uses: arduino/setup-protoc@v2
- name: Install libclang-dev
run: sudo apt-get install libclang-dev
- name: Cache build artifacts
uses: Swatinem/rust-cache@v2
with:
shared-key: "cache"
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: Generate code coverage
run: cargo llvm-cov --workspace --lcov --output-path lcov.info
env:
RUSTFLAGS: --cfg tracing_unstable
RUST_BACKTRACE: 1
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: lcov.info
fail_ci_if_error: true