aboutsummaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorToni Uhlig <matzeton@googlemail.com>2022-03-11 18:29:38 +0100
committerToni Uhlig <matzeton@googlemail.com>2022-03-11 18:29:38 +0100
commitf884a538ce79f70d44bdaaa9cb5ad2801dc36196 (patch)
tree95711638fbd34265e65ddf1d17e7c40398a13996 /.gitlab-ci.yml
parent41757ecf1cbcbcd890c1ab7e08995aaffe031752 (diff)
Code coverage generation using LCOV.
Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml6
1 files changed, 4 insertions, 2 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 6d7e46aa0..cd6c014f4 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -23,7 +23,7 @@ build_and_test:
# static linked build
- mkdir build-cmake-submodule
- cd build-cmake-submodule
- - env CMAKE_C_FLAGS='-Werror' cmake .. -DBUILD_EXAMPLES=ON -DBUILD_NDPI=ON -DENABLE_SANITIZER=ON -DENABLE_ZLIB=ON
+ - env CMAKE_C_FLAGS='-Werror' cmake .. -DENABLE_COVERAGE=ON -DBUILD_EXAMPLES=ON -DBUILD_NDPI=ON -DENABLE_SANITIZER=ON -DENABLE_ZLIB=ON
- make libnDPI
- tree libnDPI
- make install VERBOSE=1 DESTDIR="$(realpath ../_install)"
@@ -37,7 +37,7 @@ build_and_test:
- mkdir build
- cd build
- export PKG_CONFIG_PATH="$(realpath ../build-cmake-submodule/libnDPI/lib/pkgconfig)"
- - env CMAKE_C_FLAGS='-Werror' cmake .. -DBUILD_EXAMPLES=ON -DENABLE_SANITIZER=ON -DENABLE_MEMORY_PROFILING=ON -DENABLE_ZLIB=ON
+ - env CMAKE_C_FLAGS='-Werror' cmake .. -DENABLE_COVERAGE=ON -DBUILD_EXAMPLES=ON -DENABLE_SANITIZER=ON -DENABLE_MEMORY_PROFILING=ON -DENABLE_ZLIB=ON
- make all VERBOSE=1
- cd ..
- ./build/nDPId-test || test $? -eq 1
@@ -45,6 +45,8 @@ build_and_test:
# dameon start/stop test
- NUSER=nobody make -C ./build daemon VERBOSE=1
- NUSER=nobody make -C ./build daemon VERBOSE=1
+ # generate coverage report
+ - make -C ./build coverage
# make dist
- make -C ./build dist
artifacts: