diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2017-11-07 15:27:42 +0100 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2017-11-07 15:27:42 +0100 |
commit | c6119654921decf0412149484b546dfc4902346c (patch) | |
tree | 5a4d8c3f0e37ebb9593258a0e01277a3fcbfaace /tests | |
parent | ff3a97de55176ae600124695ae9aa815b5ff2f18 (diff) | |
download | sink-c6119654921decf0412149484b546dfc4902346c.tar.gz sink-c6119654921decf0412149484b546dfc4902346c.zip |
Require valgrind when enabling memcheck
Diffstat (limited to 'tests')
-rw-r--r-- | tests/SinkTest.cmake | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/SinkTest.cmake b/tests/SinkTest.cmake index 4eb8f43..d0cda8d 100644 --- a/tests/SinkTest.cmake +++ b/tests/SinkTest.cmake | |||
@@ -3,12 +3,11 @@ | |||
3 | function(add_memcheck_test name binary) | 3 | function(add_memcheck_test name binary) |
4 | if (${ENABLE_MEMCHECK}) | 4 | if (${ENABLE_MEMCHECK}) |
5 | set(memcheck_command "${MEMORYCHECK_COMMAND} ${MEMORYCHECK_COMMAND_OPTIONS}") | 5 | set(memcheck_command "${MEMORYCHECK_COMMAND} ${MEMORYCHECK_COMMAND_OPTIONS}") |
6 | if (NOT ${memcheck_command}) | 6 | if (NOT memcheck_command) |
7 | message("MEMORYCHECK_COMMAND not defined.") | 7 | message(FATAL_ERROR "memcheck_command not defined. ${memcheck_command}") |
8 | else() | ||
9 | separate_arguments(memcheck_command) | ||
10 | add_test(memcheck_${name} ${memcheck_command} ./${binary} ${ARGN}) | ||
11 | endif() | 8 | endif() |
9 | separate_arguments(memcheck_command) | ||
10 | add_test(memcheck_${name} ${memcheck_command} ./${binary} ${ARGN}) | ||
12 | endif() | 11 | endif() |
13 | endfunction(add_memcheck_test) | 12 | endfunction(add_memcheck_test) |
14 | 13 | ||