-
Notifications
You must be signed in to change notification settings - Fork 1
38 lines (35 loc) · 892 Bytes
/
Copy pathcoverage.yml
File metadata and controls
38 lines (35 loc) · 892 Bytes
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: Code Coverage
on:
push:
branches:
- master
paths:
- 'matcher_rs/src/**'
- '.github/workflows/coverage.yml'
- 'Cargo.toml'
pull_request:
paths:
- 'matcher_rs/src/**'
- '.github/workflows/coverage.yml'
- 'Cargo.toml'
permissions:
contents: read
jobs:
coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
- name: Install tarpaulin
uses: taiki-e/install-action@cargo-tarpaulin
- name: Generate code coverage
run: cargo tarpaulin -p matcher_rs --out xml
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
file: ./cobertura.xml
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}