File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7373
7474
7575
76- # Code coverage (Linux only)
77- coverage :
78- name : Code coverage
79- runs-on : ubuntu-latest
80- steps :
81- - name : Checkout code
82- uses : actions/checkout@v4
8376
84- - name : Install Rust
85- uses : dtolnay/rust-toolchain@v1
86- with :
87- toolchain : stable
88-
89- - name : Install grcov
90- run : cargo install grcov
91-
92- - name : Generate coverage
93- run : |
94- export CARGO_INCREMENTAL=0
95- export RUSTFLAGS="-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests -Cpanic=abort"
96- export RUSTDOCFLAGS="-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests -Cpanic=abort"
97- cargo test --verbose
98-
99- - name : Generate coverage report
100- run : |
101- ./grcov . --binary-path ./target/debug/ -s . -t html --branch --ignore-not-existing -o ./coverage/
102-
103- - name : Upload coverage to Codecov
104- uses : codecov/codecov-action@v3
105- with :
106- file : ./coverage/
107- flags : unittests
108- name : codecov-umbrella
109- fail_ci_if_error : false
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments