diff options
author | Brad King <brad.king@kitware.com> | 2020-05-27 10:45:39 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-05-27 10:45:39 (GMT) |
commit | 0a74d7c2b84c9c8f87f4d821d3f0cd5bd8a7f479 (patch) | |
tree | be63ba6b56160a20e8c27b9681566b6156e7abb5 /Tests/RunCMake/ctest_test/TestRepeatNotRun.cmake | |
parent | 614e93c563c977b68e37399d09d28d58672166d4 (diff) | |
parent | bbb62dcc72394316f151ead984a9f7cdc258e98f (diff) | |
download | CMake-0a74d7c2b84c9c8f87f4d821d3f0cd5bd8a7f479.zip CMake-0a74d7c2b84c9c8f87f4d821d3f0cd5bd8a7f479.tar.gz CMake-0a74d7c2b84c9c8f87f4d821d3f0cd5bd8a7f479.tar.bz2 |
Merge branch 'backport-ctest-repeat-notrun' into ctest-repeat-notrun
Diffstat (limited to 'Tests/RunCMake/ctest_test/TestRepeatNotRun.cmake')
-rw-r--r-- | Tests/RunCMake/ctest_test/TestRepeatNotRun.cmake | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Tests/RunCMake/ctest_test/TestRepeatNotRun.cmake b/Tests/RunCMake/ctest_test/TestRepeatNotRun.cmake new file mode 100644 index 0000000..abde4f0 --- /dev/null +++ b/Tests/RunCMake/ctest_test/TestRepeatNotRun.cmake @@ -0,0 +1,10 @@ +include("${COUNT_FILE}" OPTIONAL) +if(NOT COUNT) + set(COUNT 0) +endif() +math(EXPR COUNT "${COUNT} + 1") +file(WRITE "${COUNT_FILE}" "set(COUNT ${COUNT})\n") +if(NOT COUNT EQUAL 2) + message("this test times out except on the 2nd run") + execute_process(COMMAND ${CMAKE_COMMAND} -E sleep 10) +endif() |