Skip to content

Commit 59c5fec

Browse files
author
Peter Neiss
committed
Fix Code Coverage workflow: handle gcov mismatch errors
- Use newer 'branch_coverage' instead of deprecated 'lcov_branch_coverage' - Add --ignore-errors mismatch,gcov,inconsistent to handle exception tag mismatches - Add --rc geninfo_unexecuted_blocks=1 to handle unexecuted block warnings - Fixes: 'mismatched exception tag' error in lstate.h
1 parent 193af26 commit 59c5fec

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

.github/workflows/coverage.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,20 +42,24 @@ jobs:
4242
lcov --capture \
4343
--directory build \
4444
--output-file coverage.info \
45-
--rc lcov_branch_coverage=1
45+
--rc branch_coverage=1 \
46+
--rc geninfo_unexecuted_blocks=1 \
47+
--ignore-errors mismatch,gcov,inconsistent
4648
4749
# Filter out system headers and test files
4850
lcov --remove coverage.info \
4951
'/usr/*' \
5052
'*/build/*' \
5153
'*/testes/*' \
5254
--output-file coverage_filtered.info \
53-
--rc lcov_branch_coverage=1
55+
--rc branch_coverage=1 \
56+
--ignore-errors mismatch,gcov,inconsistent
5457
5558
# Generate HTML report
5659
genhtml coverage_filtered.info \
5760
--output-directory coverage_html \
58-
--rc lcov_branch_coverage=1
61+
--rc branch_coverage=1 \
62+
--ignore-errors mismatch
5963
6064
# Print summary
6165
lcov --list coverage_filtered.info

0 commit comments

Comments
 (0)