From 598c45dddd538c5c7d3f68d53852be67dc985c48 Mon Sep 17 00:00:00 2001 From: John Date: Sat, 13 Nov 2021 18:41:41 +0100 Subject: [PATCH] more options for coverage --- .github/workflows/coverage.yml | 2 +- CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index a30ba06c..57cc9781 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -21,7 +21,7 @@ jobs: run: sudo apt-get update && sudo apt-get install -y libmosquitto1 libmosquitto-dev - name: build - run: cmake -Dcoverage=ON -DBUILD_TESTING=1 . && make + run: cmake -Dcoverage=1 -DBUILD_TESTING=1 . && make - name: test regular run: cd src/lib/ebus/test && ./test_symbol && ./test_filereader && ./test_data && ./test_message diff --git a/CMakeLists.txt b/CMakeLists.txt index 7b9433e4..7a0ce182 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -73,7 +73,7 @@ endif(NOT HAVE_ARGP) option(coverage "enable code coverage tracking." OFF) if(NOT coverage STREQUAL OFF) - add_definitions(-coverage -O0) + add_definitions(-g -O0 --coverage -Wall) link_libraries(gcov) message(STATUS "coverage enabled") endif(NOT coverage STREQUAL OFF)