From e4fe97eba0160a4d9b1282732cbaea7f8dfb4c7d Mon Sep 17 00:00:00 2001 From: Rodney Dawes Date: Thu, 2 Feb 2017 15:52:03 -0500 Subject: Use cmake-extras for coverage support and always enable testing. --- CMakeLists.txt | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 1aebdf3..1378fe4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -94,9 +94,6 @@ add_custom_target (dist COMMAND bzr export --root=${ARCHIVE_NAME} ${CMAKE_BINARY_DIR}/${ARCHIVE_NAME}.tar.gz WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}) -add_custom_target (clean-coverage - COMMAND find ${CMAKE_BINARY_DIR} -name '*.gcda' | xargs rm -f) - add_custom_target (cppcheck COMMAND cppcheck --enable=all -q --error-exitcode=2 --inline-suppr ${CMAKE_SOURCE_DIR}/src ${CMAKE_SOURCE_DIR}/tests) @@ -126,7 +123,12 @@ if (${ENABLE_TESTS}) pkg_check_modules (DBUSTEST REQUIRED dbustest-1>=14.04.0) enable_testing () if (${ENABLE_COVERAGE}) - include(GCov) + find_package(CoverageReport) + ENABLE_COVERAGE_REPORT( + TARGETS indicatordatetimeservice indicator-datetime-service + TESTS test-actions test-alarm-queue test-clock test-datetime test-exporter test-formatter test-live-actions test-locations test-menu-appointments test-menus test-notification test-notification-response test-planner test-settings test-sound test-timezone-timedated test-utils test-eds-ics-all-day-events test-eds-ics-repeating-events test-eds-ics-nonrepeating-events test-eds-ics-repeating-valarms test-eds-ics-missing-trigger test-eds-ics-tzids test-eds-ics-tzids-2 test-eds-ics-tzids-utc test-eds-ics-non-attending-alarms test-eds-ics-repeating-events-with-individual-change manual-test-snap + FILTER /usr/include ${CMAKE_BINARY_DIR}/* + ) endif () endif () -- cgit v1.2.3