Skip to content

Commit

Permalink
#32: fix script
Browse files Browse the repository at this point in the history
  • Loading branch information
tlamonthezie committed Jul 17, 2024
1 parent fba19bb commit 2d2a75c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ if [[ "${RUN_TESTS}" == "ON" ]]; then
# Looks like there are more lines in the file: /home/thomas/repositories/vt-tv/lib/yaml-cpp/include/yaml-cpp/node/detail/node.h
pushd OUTPUT_DIR
lcov --capture --directory ${BUILD_DIR} --output-file lcov_vt-tv_test.info
lcov --remove lcov_vt-tv_test.info -o lcov_vt-tv_test_no_deps.info '*/lib/*' '/usr/include/*' '*/vtk/*' '*/tests/*'
lcov --remove lcov_vt-tv_test.info -o lcov_vt-tv_test_no_deps.info '*/lib/*' '/usr/include/*' '*/vtk/*' '*/vtk-build/*' '*/tests/*'
lcov --summary lcov_vt-tv_test_no_deps.info
if [[ "${COVERAGE_BUILD_HTML_REPORT}" == "ON" ]]; then
genhtml --prefix ./src --ignore-errors source lcov_vt-tv_test_no_deps.info --legend --title "$(git rev-parse HEAD)" --output-directory=lcov_vt-tv_html
Expand Down
4 changes: 2 additions & 2 deletions ci/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ cp /opt/src/vt-tv/output/lcov-list-report.txt /tmp/artifacts/

# extract total coverage (Lines) for later use in a badge in the CI
LCOV_SUMMARY=$(lcov --summary lcov_vt-tv_test_no_deps.info)
LCOV_TOTAL_LINES_COV=$LCOV_SUMMARY | grep -E -o 'lines......: ([0-9.]+)*' | grep -o -E '[0-9]+.[0-9]+'
echo LCOV_TOTAL_LINES_COV > lcov-lines-total.txt
LCOV_TOTAL_LINES_COV=$(echo $LCOV_SUMMARY | grep -E -o 'lines......: ([0-9.]+)*' | grep -o -E '[0-9]+.[0-9]+')
echo $LCOV_TOTAL_LINES_COV > lcov-lines-total.txt
cp /opt/src/vt-tv/output/lcov-lines-total.txt /tmp/artifacts/

popd
Expand Down

0 comments on commit 2d2a75c

Please sign in to comment.