summaryrefslogtreecommitdiffstats
path: root/Source/ctest.cxx
diff options
context:
space:
mode:
authorZack Galbreath <zack.galbreath@kitware.com>2013-09-24 18:20:38 (GMT)
committerBrad King <brad.king@kitware.com>2013-10-08 13:18:13 (GMT)
commiteb2decc02d28f41a3e189d5387be24552c42060f (patch)
treef1995da8fc935d3ed8831213da02534eab5e7ce2 /Source/ctest.cxx
parent475635ec0f3eeae9f6db0f9daa8a9c4cd8b3f989 (diff)
downloadCMake-eb2decc02d28f41a3e189d5387be24552c42060f.zip
CMake-eb2decc02d28f41a3e189d5387be24552c42060f.tar.gz
CMake-eb2decc02d28f41a3e189d5387be24552c42060f.tar.bz2
ctest: Add --rerun-failed option
Add a new command line argument to ctest. This allows users to rerun tests that failed during the previous call to ctest. This is accomplished by analyzing the most recently modified file named "^LastTestsFailed*" in the Testing/Temporary subdirectory of the project's binary directory.
Diffstat (limited to 'Source/ctest.cxx')
-rw-r--r--Source/ctest.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/ctest.cxx b/Source/ctest.cxx
index e767a16..ece68f5 100644
--- a/Source/ctest.cxx
+++ b/Source/ctest.cxx
@@ -150,6 +150,13 @@ static const char * cmDocumentationOptions[][3] =
{"-U, --union", "Take the Union of -I and -R",
"When both -R and -I are specified by default the intersection of "
"tests are run. By specifying -U the union of tests is run instead."},
+ {"--rerun-failed", "Run only the tests that failed previously",
+ "This option tells ctest to perform only the tests that failed during its "
+ "previous run. When this option is specified, ctest ignores all other "
+ "options intended to modify the list of tests to run "
+ "(-L, -R, -E, -LE, -I, etc). In the event that CTest runs and no tests "
+ "fail, subsequent calls to ctest with the --rerun-failed option will "
+ "run the set of tests that most recently failed (if any)."},
{"--max-width <width>", "Set the max width for a test name to output",
"Set the maximum width for each test name to show in the output. This "
"allows the user to widen the output to avoid clipping the test name which "