Use llvm-cov for coverage reporting
grcov reports incorrect coverage, e.g. showing blank lines as uncovered
This commit is contained in:
parent
c89c8b060c
commit
f9d47533ee
11
coverage.sh
11
coverage.sh
|
@ -8,7 +8,10 @@ export LLVM_PROFILE_FILE="target/coverage/prof/opentally-%p-%m.profraw"
|
||||||
export CARGO_TARGET_DIR=target/coverage
|
export CARGO_TARGET_DIR=target/coverage
|
||||||
cargo test
|
cargo test
|
||||||
|
|
||||||
grcov target/coverage/prof --binary-path target/coverage/debug -t html -o target/coverage/html \
|
llvm-profdata merge -sparse target/coverage/prof/*.profraw -o target/coverage/opentally.profdata
|
||||||
--ignore src/numbers/rational_num.rs \
|
|
||||||
--ignore src/stv/wasm.rs \
|
llvm-cov show target/coverage/debug/opentally -instr-profile=target/coverage/opentally.profdata -Xdemangler="$HOME/.cargo/bin/rustfilt" \
|
||||||
--ignore 'tests/*'
|
-ignore-filename-regex="$HOME/." \
|
||||||
|
-ignore-filename-regex=numbers/rational_num.rs \
|
||||||
|
-ignore-filename-regex=stv/wasm.rs \
|
||||||
|
-format=html --show-instantiations=false --output-dir=target/coverage/html
|
||||||
|
|
Loading…
Reference in New Issue