summaryrefslogtreecommitdiffstats
path: root/Help/command/ctest_test.rst
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-11-07 16:27:48 (GMT)
committerBrad King <brad.king@kitware.com>2019-11-07 19:21:18 (GMT)
commit28994115e83b568ccba546db26a55381cbad244d (patch)
tree1b109db3fddad3a96a4c8ac2b91917bc24a15ae4 /Help/command/ctest_test.rst
parent42d5d8f425e655a07d3dcb0802d90cb5c167b164 (diff)
downloadCMake-28994115e83b568ccba546db26a55381cbad244d.zip
CMake-28994115e83b568ccba546db26a55381cbad244d.tar.gz
CMake-28994115e83b568ccba546db26a55381cbad244d.tar.bz2
ctest_test: Add option to REPEAT tests
Diffstat (limited to 'Help/command/ctest_test.rst')
-rw-r--r--Help/command/ctest_test.rst20
1 files changed, 20 insertions, 0 deletions
diff --git a/Help/command/ctest_test.rst b/Help/command/ctest_test.rst
index 7a3393b..5c67b2c 100644
--- a/Help/command/ctest_test.rst
+++ b/Help/command/ctest_test.rst
@@ -23,6 +23,7 @@ Perform the :ref:`CTest Test Step` as a :ref:`Dashboard Client`.
[STOP_TIME <time-of-day>]
[RETURN_VALUE <result-var>]
[CAPTURE_CMAKE_ERROR <result-var>]
+ [REPEAT <mode>:<n>]
[QUIET]
)
@@ -95,6 +96,25 @@ The options are:
and then the ``--test-load`` command-line argument to :manual:`ctest(1)`.
See also the ``TestLoad`` setting in the :ref:`CTest Test Step`.
+``REPEAT <mode>:<n>``
+ Run tests repeatedly based on the given ``<mode>`` up to ``<n>`` times.
+ The modes are:
+
+ ``UNTIL_FAIL``
+ Require each test to run ``<n>`` times without failing in order to pass.
+ This is useful in finding sporadic failures in test cases.
+
+ ``UNTIL_PASS``
+ Allow each test to run up to ``<n>`` times in order to pass.
+ Repeats tests if they fail for any reason.
+ This is useful in tolerating sporadic failures in test cases.
+
+ ``AFTER_TIMEOUT``
+ Allow each test to run up to ``<n>`` times in order to pass.
+ Repeats tests only if they timeout.
+ This is useful in tolerating sporadic timeouts in test cases
+ on busy machines.
+
``SCHEDULE_RANDOM <ON|OFF>``
Launch tests in a random order. This may be useful for detecting
implicit test dependencies.