keep debugging coverage

This commit is contained in:
Thomas Fussell 2017-03-21 22:34:49 -04:00
parent dc0a8caa8b
commit 8d04b6501c
2 changed files with 4 additions and 3 deletions

View File

@ -32,10 +32,11 @@ script:
- mkdir build - mkdir build
- cd build - cd build
- cmake -D STATIC=$STATIC -D BENCHMARKS=$BENCHMARKS -D SAMPLES=$SAMPLES -D COVERAGE=$COVERAGE -D CMAKE_CXX_COMPILER=$COMPILER -D CMAKE_BUILD_TYPE=Debug .. - cmake -D STATIC=$STATIC -D BENCHMARKS=$BENCHMARKS -D SAMPLES=$SAMPLES -D COVERAGE=$COVERAGE -D CMAKE_CXX_COMPILER=$COMPILER -D CMAKE_BUILD_TYPE=Debug ..
- cmake --build . - make VERBOSE=1
- ./tests/xlnt.test - ./tests/xlnt.test
after_success: after_success:
- strings tests/xlnt.test | grep gcda - find . -name "*.gcda"
- pwd
- lcov --compat-libtool --directory source/CMakeFiles/xlnt.dir --capture --output-file coverage.info --gcov-tool /usr/bin/gcov-6 - lcov --compat-libtool --directory source/CMakeFiles/xlnt.dir --capture --output-file coverage.info --gcov-tool /usr/bin/gcov-6
- coveralls-lcov coverage.info - coveralls-lcov coverage.info

View File

@ -40,7 +40,7 @@ set(RUNNER "${CMAKE_CURRENT_BINARY_DIR}/runner-autogen.cpp")
set_source_files_properties(${RUNNER} PROPERTIES GENERATED TRUE) set_source_files_properties(${RUNNER} PROPERTIES GENERATED TRUE)
if(COVERAGE) if(COVERAGE)
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -lgcov --coverage") set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fprofile-arcs -ftest-coverage")
endif() endif()
set(CXXTEST_ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../third-party/cxxtest) set(CXXTEST_ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../third-party/cxxtest)