Code coverage with lcov

Includes:
 - A cmake script to setup lcov targets
 - A predefined cppast_coverage target (Disabled by default, enable by setting CPPAST_TEST_GCOV var to TRUE/ON/1)
 - Coverage report submission to coveralls.io
This commit is contained in:
Manu343726 2017-08-11 19:38:21 +02:00 • committed by Jonathan Müller
commit b1b0cad69a
4 changed files with 271 additions and 3 deletions

View file

@ -32,6 +32,12 @@ endif()
include(external/external.cmake)
if(build_test AND CPPAST_TEST_GCOV AND (CMAKE_CXX_COMPILER_ID STREQUAL "GNU"))
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
include(CodeCoverage)
APPEND_COVERAGE_COMPILER_FLAGS()
endif()
add_subdirectory(src)
if(${build_test})