summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2017-01-29 15:46:33 +0100
committerSlávek Banko <slavek.banko@axis.cz>2017-01-29 15:46:33 +0100
commit6455cb89f3f39b76326df5fc2558d42b6088a0e5 (patch)
tree45e99611e479538b3576954ee59556d9a8fbfc08
parent9150bd170f31408d6b4f02a2de8627a338ad6276 (diff)
downloadtde-cmake-6455cb89f3f39b76326df5fc2558d42b6088a0e5.tar.gz
tde-cmake-6455cb89f3f39b76326df5fc2558d42b6088a0e5.zip
Automatically run tests within check target
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
-rw-r--r--modules/TDEMacros.cmake5
1 files changed, 4 insertions, 1 deletions
diff --git a/modules/TDEMacros.cmake b/modules/TDEMacros.cmake
index 481ae7d..5f155b4 100644
--- a/modules/TDEMacros.cmake
+++ b/modules/TDEMacros.cmake
@@ -1166,7 +1166,10 @@ macro( tde_add_check_executable _arg_target )
# create make check target
if(NOT TARGET check)
- add_custom_target(check)
+ add_custom_target( check
+ COMMAND ${CMAKE_CTEST_COMMAND}
+ WORKING_DIRECTORY "${CMAKE_BINARY_DIR}"
+ COMMENT "Running tests..." )
endif(NOT TARGET check)
add_dependencies( check ${_target} )