File tree Expand file tree Collapse file tree 3 files changed +12
-15
lines changed Expand file tree Collapse file tree 3 files changed +12
-15
lines changed Original file line number Diff line number Diff line change @@ -12,20 +12,16 @@ jobs:
12
12
os : ["ubuntu"]
13
13
runs-on : ${{ matrix.os }}-latest
14
14
steps :
15
- - uses : actions/checkout@v2
16
- - uses : actions/setup-python@v2
15
+ - uses : actions/checkout@v4
16
+ - uses : actions/setup-python@v5
17
17
with :
18
18
python-version : " 3.10"
19
19
cache : " pip"
20
- - uses : actions-rs/toolchain@v1
21
- with :
22
- toolchain : stable
23
- override : true
24
- profile : minimal
25
- components : llvm-tools-preview
20
+ - name : Rust setup
21
+ run : rustup toolchain install stable --profile minimal
26
22
- name : Install cargo-llvm-cov
27
23
uses : taiki-e/install-action@cargo-llvm-cov
28
- - uses : Swatinem/rust-cache@v1
24
+ - uses : Swatinem/rust-cache@v2
29
25
with :
30
26
key : coverage-cargo-${{ matrix.os }}
31
27
continue-on-error : true
45
41
maturin develop
46
42
pytest tests --cov=foobar --cov-report lcov:python-coverage.lcov
47
43
cargo llvm-cov report --lcov --output-path rust-coverage.lcov
48
- - uses : codecov/codecov-action@v3
44
+ - name : Upload results to Codecov
45
+ uses : codecov/codecov-action@v4
49
46
with :
50
47
files : python-coverage.lcov,rust-coverage.lcov
51
48
name : ${{ matrix.os }}
49
+ token : ${{ secrets.CODECOV_TOKEN }}
50
+
Original file line number Diff line number Diff line change 17
17
# rust-python-coverage
18
18
Example PyO3 project with automated test coverage for Rust and Python
19
19
20
- [ ![ CI] ( https://github.com/cjermain /rust-python-coverage/actions/workflows/CI.yml/badge.svg )] ( https://github.com/cjermain /rust-python-coverage/actions/workflows/CI.yml )
21
- [ ![ codecov] ( https://codecov.io/gh/cjermain /rust-python-coverage/branch/main/ graph/badge.svg?token=NWHDJ22L8I )] ( https://codecov.io/gh/cjermain /rust-python-coverage )
20
+ [ ![ CI] ( https://github.com/Michael-J-Ward /rust-python-coverage/actions/workflows/CI.yml/badge.svg )] ( https://github.com/Michael-J-Ward /rust-python-coverage/actions/workflows/CI.yml )
21
+ [ ![ codecov] ( https://codecov.io/github/Michael-J-Ward /rust-python-coverage/graph/badge.svg?token=K4T59SGTQX )] ( https://codecov.io/github/Michael-J-Ward /rust-python-coverage )
22
22
23
23
This repository shows how to set up a continuous-integration job for measuring
24
24
coverage over a project using [ PyO3] ( https://github.com/PyO3/pyo3 ) . Based on
@@ -129,8 +129,7 @@ The last step of this process happens in the CI, where we upload both coverage
129
129
files to CodeCov. [Merging reports](https://docs.codecov.com/docs/merging-reports)
130
130
is an automatic feature of CodeCov, so the final view shows the combined view.
131
131
132
- https://codecov.io/gh/cjermain/rust-python-coverage
133
-
132
+ https://codecov.io/github/Michael-J-Ward/rust-python-coverage
134
133
135
134
## Appendix
136
135
Original file line number Diff line number Diff line change 1
-
2
1
use pyo3:: prelude:: * ;
3
2
4
3
/// Returns the sum of two numbers (only Rust)
You can’t perform that action at this time.
0 commit comments