mirror of
https://github.com/allankoechke/jwt-cpp.git
synced 2026-11-30 10:18:40 +00:00
* adding coverage testing surprisingly: Overall coverage rate: lines......: 80.6% (519 of 644 lines) functions..: 92.5% (235 of 254 functions) * Update coverage.yml
16 lines
518 B
CMake
16 lines
518 B
CMake
set(COVERAGE_CMAKE "${CMAKE_BINARY_DIR}/cmake/CodeCoverage.cmake")
|
|
if(NOT EXISTS ${COVERAGE_CMAKE})
|
|
set(COVERAGE_URL
|
|
"https://raw.githubusercontent.com/bilke/cmake-modules/master/CodeCoverage.cmake"
|
|
)
|
|
file(DOWNLOAD ${COVERAGE_URL} ${COVERAGE_CMAKE})
|
|
endif()
|
|
|
|
include(${COVERAGE_CMAKE})
|
|
|
|
function(setup_coverage TARGET)
|
|
target_compile_options(${TARGET} PRIVATE -g -O0 -fprofile-arcs
|
|
-ftest-coverage)
|
|
target_link_libraries(${TARGET} PRIVATE gcov)
|
|
endfunction()
|