From d6f8bf4564262915d1cc558a7cf81dcaea9c749c Mon Sep 17 00:00:00 2001 From: Timo Heister Date: Sun, 8 Dec 2013 02:49:30 +0000 Subject: [PATCH] quicktests: revert part of r31930 git-svn-id: https://svn.dealii.org/trunk@31935 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/tests/quick_tests/CMakeLists.txt | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/deal.II/tests/quick_tests/CMakeLists.txt b/deal.II/tests/quick_tests/CMakeLists.txt index 37ff9f5df2..2a37c13820 100644 --- a/deal.II/tests/quick_tests/CMakeLists.txt +++ b/deal.II/tests/quick_tests/CMakeLists.txt @@ -39,6 +39,7 @@ MACRO(make_quicktest test_basename build_name mpi_run) SET(_command mpirun -n ${mpi_run} ./${_target}) ENDIF() ADD_CUSTOM_TARGET(${_target}.run + DEPENDS kill-${_target}-OK DEPENDS ${_target} COMMAND ${_command} > ${_target}-OK 2>&1 @@ -50,6 +51,16 @@ MACRO(make_quicktest test_basename build_name mpi_run) WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} ) + # this is a hack to make sure the -OK file is deleted + # even if compilation fails. + ADD_CUSTOM_TARGET(kill-${_target}-OK + COMMAND rm -f ${_target}-OK + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} + ) + + # make sure kill is run before running the task + ADD_DEPENDENCIES(${_target} kill-${_target}-OK) + ADD_TEST(NAME ${_target} COMMAND ${CMAKE_COMMAND} -DTRGT=${_target}.run -DTEST=${_target} -DDEAL_II_BINARY_DIR=${CMAKE_BINARY_DIR} -- 2.39.5