mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-30 07:55:51 +00:00
Adjustments to code coverage reports:
* src/beast is removed since it has its own coverage and CI integration.
This commit is contained in:
committed by
Vinnie Falco
parent
92b3cdb6f8
commit
76b761d8e2
@@ -21,6 +21,13 @@ rm -f build/rippled
|
||||
# See what we've actually built
|
||||
ldd $RIPPLED_PATH
|
||||
|
||||
if [[ $TARGET == "coverage" ]]; then
|
||||
export PATH=$PATH:$LCOV_ROOT/usr/bin
|
||||
|
||||
# Create baseline coverage data file
|
||||
lcov --no-external -c -i -d . -o baseline.info
|
||||
fi
|
||||
|
||||
# Execute unit tests under gdb, printing a call stack
|
||||
# if we get a crash.
|
||||
gdb -return-child-result -quiet -batch \
|
||||
@@ -32,8 +39,17 @@ gdb -return-child-result -quiet -batch \
|
||||
--args $RIPPLED_PATH --unittest
|
||||
|
||||
if [[ $TARGET == "coverage" ]]; then
|
||||
# We pass along -p to keep path segments so as to avoid collisions
|
||||
codecov --gcov-args=-p --gcov-source-match='^src/(ripple|beast)'
|
||||
# Create test coverage data file
|
||||
lcov --no-external -c -d . -o tests.info
|
||||
|
||||
# Combine baseline and test coverage data
|
||||
lcov -a baseline.info -a tests.info -o lcov-all.info
|
||||
|
||||
# Only report on src/ripple files
|
||||
lcov -e "lcov-all.info" "*/src/ripple/*" -o lcov.info
|
||||
|
||||
# Push the results (lcov.info) to codecov
|
||||
codecov -X gcov # don't even try and look for .gcov files ;)
|
||||
fi
|
||||
|
||||
# Run NPM tests
|
||||
|
||||
Reference in New Issue
Block a user