aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2021-05-04 13:04:58 +0200
committerRobert Tari <robert@tari.in>2021-05-17 20:26:00 +0200
commit41d834903548424be7d0a60d3f1aac5b07280f22 (patch)
treed126095d9c0a931f6335412aa137a273567b3772 /CMakeLists.txt
parent287c8fc4f0e9644c2bb9568813fb225cea036c43 (diff)
downloadayatana-ido-41d834903548424be7d0a60d3f1aac5b07280f22.tar.gz
ayatana-ido-41d834903548424be7d0a60d3f1aac5b07280f22.tar.bz2
ayatana-ido-41d834903548424be7d0a60d3f1aac5b07280f22.zip
CMakeLists.txt: Move coverage report generation macro into basefolder's CMakeLists.txt file.
With the previous approach, only coverage of the tests/ subfolder was reported (which always should be 100%). With this change, also coverage of the files in src/ is reported.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt9
1 files changed, 9 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b039352..70b509f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -51,6 +51,15 @@ if (ENABLE_TESTS)
enable_testing()
add_subdirectory(example)
add_subdirectory(tests)
+ # coverage
+ if (ENABLE_COVERAGE)
+ find_package(CoverageReport)
+ ENABLE_COVERAGE_REPORT(
+ TARGETS "ayatana-ido3-0.4"
+ TESTS "gtest-menuitems"
+ FILTER /usr/include ${CMAKE_BINARY_DIR}/*
+ )
+ endif()
endif()
# Display config info