test: add memory check, reporting and fix some memleaks in tests #14

Merged
rick merged 5 commits from feature/memcheck into develop 2022-07-30 23:10:31 +02:00
2 changed files with 8 additions and 0 deletions

View File

@ -64,6 +64,12 @@ steps:
- cd cmake-build-ci
- cmake --build .
- make coverage
- name: Generate memory report
image: registry.riba-interactive.de/reportly:latest
settings:
input_path: cmake-build-ci
output_path: .reports
debug: true
- name: Report test and coverage
image: alpine

View File

@ -33,6 +33,8 @@ if ((CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME OR MODERN_CMAKE_BUILD_TESTING)
if (ENABLE_TEST_COVERAGE)
include(CodeCoverage)
set(MEMORYCHECK_COMMAND_OPTIONS "--trace-children=yes --leak-check=full")
setup_target_for_coverage_lcov(
NAME coverage
EXECUTABLE ${CMAKE_CTEST_COMMAND} -T memcheck