From 8094716f7c9a3d9f2886132e7419b377abb97b3b Mon Sep 17 00:00:00 2001 From: Arnaud Bailly Date: Thu, 10 Oct 2024 18:37:19 +0200 Subject: Add simple script to compute rust coverage --- rust/cover.sh | 4 ++++ 1 file changed, 4 insertions(+) create mode 100755 rust/cover.sh (limited to 'rust') diff --git a/rust/cover.sh b/rust/cover.sh new file mode 100755 index 0000000..c7befa6 --- /dev/null +++ b/rust/cover.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash +CARGO_INCREMENTAL=0 RUSTFLAGS='-Cinstrument-coverage' LLVM_PROFILE_FILE='cargo-test-%p-%m.profraw' cargo test +rm -fr target/coverage/html +grcov . --binary-path ./target/debug/deps/ -s . -t html --branch --ignore-not-existing --ignore '../*' --ignore "/*" -o target/coverage/html -- cgit v1.2.3