From 074191fdd7ae98ea6713df94e14bfedb568c1b07 Mon Sep 17 00:00:00 2001 From: Yevhenii Babichenko Date: Fri, 15 Nov 2024 18:03:12 +0200 Subject: [PATCH] a better fix attempt --- .github/workflows/tests.yml | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 2dedff8..f43f249 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -63,20 +63,10 @@ jobs: - name: Generate coverage report run: | - set -x BINARIES="$(cargo nextest list --list-type binaries-only --message-format json | jq -r '.["rust-binaries"] | .[] | "--object \(.["binary-path"])"' | tr '\n' ' ')" ARGS="-instr-profile fixit.profdata $BINARIES --object ./target/debug/fixit" - while true; do - output=$(cargo profdata -- merge -sparse default_*.profraw -o fixit.profdata 2>&1) - if [[ ! $output =~ "warning" ]] && [[ ! $output =~ "error" ]]; then - break - fi - bad_file=$(echo "$output" | grep -o 'default_[^:]*\.profraw') - if [ -z "$bad_file" ]; then - break - fi - rm "$bad_file" - done + export LLVM_PROFILE_FILE="default_%m.profraw" + cargo profdata -- merge -sparse default_*.profraw -o fixit.profdata cargo cov -- report --use-color --ignore-filename-regex='/.cargo/registry' $ARGS cargo cov -- export -format=lcov $ARGS -sources src/{,**/}*.rs > fixit.lcov