Skip to content

Commit

Permalink
fix: Add combined coverage script
Browse files Browse the repository at this point in the history
  • Loading branch information
miguelmtzinf committed Feb 20, 2024
1 parent 3d432d1 commit effd361
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions combined-coverage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,13 @@
# This bash script creates coverage reports via Hardhat and Foundry
# and then merges them, removing uninteresting files

export NODE_OPTIONS="--max_old_space_size=8192"

set -e

npm run hardhat coverage
forge coverage --report lcov

sed -i -e 's/\/.*gho-core.//g' coverage/lcov.info
# sed -i -e 's/\/.*gho-core.//g' coverage/lcov.info
sed -i -e '/^FN\|FNDA:/s/,[^.]*\./,/g' lcov.info



lcov \
--rc lcov_branch_coverage=1 \
Expand All @@ -24,7 +23,7 @@ lcov \
--rc lcov_branch_coverage=1 \
--remove merged-lcov.info \
--output-file combined-lcov.info \
"*node_modules*" "*test*" "*mock*"
"*node_modules*" "*test*" "*mock*" "*script*"

rm merged-lcov.info

Expand Down

0 comments on commit effd361

Please sign in to comment.