From c1397ace1dfc595c02e9cc7ee8392c085530c014 Mon Sep 17 00:00:00 2001 From: Kyle Edwards Date: Wed, 29 Apr 2020 14:49:19 -0400 Subject: Help: Clarify why CTEST_NIGHTLY_START_TIME is needed --- Help/variable/CTEST_NIGHTLY_START_TIME.rst | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Help/variable/CTEST_NIGHTLY_START_TIME.rst b/Help/variable/CTEST_NIGHTLY_START_TIME.rst index bc80276..90841f9 100644 --- a/Help/variable/CTEST_NIGHTLY_START_TIME.rst +++ b/Help/variable/CTEST_NIGHTLY_START_TIME.rst @@ -1,5 +1,9 @@ CTEST_NIGHTLY_START_TIME ------------------------ -Specify the CTest ``NightlyStartTime`` setting -in a :manual:`ctest(1)` dashboard client script. +Specify the CTest ``NightlyStartTime`` setting in a :manual:`ctest(1)` +dashboard client script. + +Note that this variable must always be set for a nightly build in a +dashboard script. It is needed so that nightly builds can be properly grouped +together in CDash. -- cgit v0.12 From 4f2fa2459a6918846a915099a16d081854b0a846 Mon Sep 17 00:00:00 2001 From: Kyle Edwards Date: Wed, 29 Apr 2020 14:49:36 -0400 Subject: Tests: Add tests to demonstrate when CTEST_NIGHTLY_START_TIME is needed --- Tests/RunCMake/ctest_start/NoStartTimeNightly-result.txt | 1 + Tests/RunCMake/ctest_start/NoStartTimeNightly-stderr.txt | 4 ++++ Tests/RunCMake/ctest_start/RunCMakeTest.cmake | 2 ++ Tests/RunCMake/ctest_start/test.cmake.in | 4 +++- 4 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 Tests/RunCMake/ctest_start/NoStartTimeNightly-result.txt create mode 100644 Tests/RunCMake/ctest_start/NoStartTimeNightly-stderr.txt diff --git a/Tests/RunCMake/ctest_start/NoStartTimeNightly-result.txt b/Tests/RunCMake/ctest_start/NoStartTimeNightly-result.txt new file mode 100644 index 0000000..b57e2de --- /dev/null +++ b/Tests/RunCMake/ctest_start/NoStartTimeNightly-result.txt @@ -0,0 +1 @@ +(-1|255) diff --git a/Tests/RunCMake/ctest_start/NoStartTimeNightly-stderr.txt b/Tests/RunCMake/ctest_start/NoStartTimeNightly-stderr.txt new file mode 100644 index 0000000..79756eb --- /dev/null +++ b/Tests/RunCMake/ctest_start/NoStartTimeNightly-stderr.txt @@ -0,0 +1,4 @@ +^WARNING: No nightly start time found please set in CTestConfig\.cmake or DartConfig\.cmake +CMake Error at [^ +]*/Tests/RunCMake/ctest_start/NoStartTimeNightly/test\.cmake:[0-9]+ \(ctest_start\): + ctest_start unknown error\.$ diff --git a/Tests/RunCMake/ctest_start/RunCMakeTest.cmake b/Tests/RunCMake/ctest_start/RunCMakeTest.cmake index da85b39..f11f1ec 100644 --- a/Tests/RunCMake/ctest_start/RunCMakeTest.cmake +++ b/Tests/RunCMake/ctest_start/RunCMakeTest.cmake @@ -48,6 +48,8 @@ run_ctest_start(TooManyArgs Experimental ${RunCMake_BINARY_DIR}/TooManyArgs-build ${RunCMake_BINARY_DIR}/TooManyArgs-build ${RunCMake_BINARY_DIR}/TooManyArgs-build) +run_ctest_start(NoStartTimeExperimental Experimental) +run_ctest_start(NoStartTimeNightly Nightly) function(run_ConfigInBuild) set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/ConfigInBuild-build) diff --git a/Tests/RunCMake/ctest_start/test.cmake.in b/Tests/RunCMake/ctest_start/test.cmake.in index 8cd3cff..4063ece 100644 --- a/Tests/RunCMake/ctest_start/test.cmake.in +++ b/Tests/RunCMake/ctest_start/test.cmake.in @@ -8,7 +8,9 @@ set(CTEST_CMAKE_GENERATOR "@RunCMake_GENERATOR@") set(CTEST_CMAKE_GENERATOR_PLATFORM "@RunCMake_GENERATOR_PLATFORM@") set(CTEST_CMAKE_GENERATOR_TOOLSET "@RunCMake_GENERATOR_TOOLSET@") set(CTEST_BUILD_CONFIGURATION "$ENV{CMAKE_CONFIG_TYPE}") -set(CTEST_NIGHTLY_START_TIME "01:00:00 UTC") +if(NOT "@CASE_NAME@" MATCHES "^NoStartTime") + set(CTEST_NIGHTLY_START_TIME "01:00:00 UTC") +endif() function(setup_tests) ctest_start(${ctest_start_args}) -- cgit v0.12