Created
April 30, 2015 19:42
-
-
Save EricWF/eaf2dc4ce888cb659275 to your computer and use it in GitHub Desktop.
Coverage change for Benchmark
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt | |
| index 5fb0b29..38277ab 100644 | |
| --- a/test/CMakeLists.txt | |
| +++ b/test/CMakeLists.txt | |
| @@ -54,11 +54,13 @@ if (${CMAKE_BUILD_TYPE} MATCHES "[Cc]overage") | |
| if (GCOV AND LCOV AND GENHTML AND MAKE AND "${CMAKE_GENERATOR}" STREQUAL "Unix Makefiles") | |
| add_custom_command( | |
| OUTPUT ${CMAKE_BINARY_DIR}/lcov/index.html | |
| - COMMAND ${LCOV} -q -z -d . | |
| - COMMAND ${LCOV} --no-external -q -c -b "${CMAKE_BINARY_DIR}" -d . -o initial.lcov -i | |
| + COMMAND ${LCOV} --zerocounters -d . | |
| + COMMAND ${LCOV} --capture --initial --no-external -b ${CMAKE_SOURCE_DIR} -d . -o initial.lcov | |
| COMMAND ${MAKE} test | |
| - COMMAND ${LCOV} --no-external -q -c -b "${CMAKE_BINARY_DIR}" -d . -o info.lcov | |
| - COMMAND ${GENHTML} info.lcov --o lcov --demangle-cpp --sort -p "${CMAKE_BINARY_DIR}" -t benchmark | |
| + COMMAND ${LCOV} --capture --no-external -b ${CMAKE_SOURCE_DIR} -d . -o after_tests.lcov | |
| + COMMAND ${LCOV} -a initial.lcov -a after_tests.lcov -o final.lcov | |
| + COMMAND ${LCOV} --remove final.lcov "'${CMAKE_SOURCE_DIR}/test/*'" -o final.lcov | |
| + COMMAND ${GENHTML} final.lcov -o lcov --demangle-cpp --sort -p "${CMAKE_BINARY_DIR}" -t benchmark | |
| DEPENDS filter_test benchmark_test options_test basic_test fixture_test cxx03_test | |
| WORKING_DIRECTORY ${CMAKE_BINARY_DIR} | |
| COMMENT "Running LCOV" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment