diff options
author | Zach Mullen <zach.mullen@kitware.com> | 2010-06-15 14:29:35 (GMT) |
---|---|---|
committer | Zach Mullen <zach.mullen@kitware.com> | 2010-06-15 14:29:35 (GMT) |
commit | 960dc2b10ff8651c5c7f1be566855c8440effd2b (patch) | |
tree | 8922f6d1865bd2c00e8aba0329451e58b7aaddd5 /Source/CTest/cmCTestRunTest.cxx | |
parent | d714b18ac5f415e15c5e03bf8f6aaeaf45e143f5 (diff) | |
download | CMake-960dc2b10ff8651c5c7f1be566855c8440effd2b.zip CMake-960dc2b10ff8651c5c7f1be566855c8440effd2b.tar.gz CMake-960dc2b10ff8651c5c7f1be566855c8440effd2b.tar.bz2 |
Do not exit if stoptime is passed.
Diffstat (limited to 'Source/CTest/cmCTestRunTest.cxx')
-rw-r--r-- | Source/CTest/cmCTestRunTest.cxx | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/Source/CTest/cmCTestRunTest.cxx b/Source/CTest/cmCTestRunTest.cxx index 4c9675b..9fb8827 100644 --- a/Source/CTest/cmCTestRunTest.cxx +++ b/Source/CTest/cmCTestRunTest.cxx @@ -32,6 +32,7 @@ cmCTestRunTest::cmCTestRunTest(cmCTestTestHandler* handler) this->ProcessOutput = ""; this->CompressedOutput = ""; this->CompressionRatio = 2; + this->StopTimePassed = false; } cmCTestRunTest::~cmCTestRunTest() @@ -436,8 +437,13 @@ bool cmCTestRunTest::StartTest(size_t total) } this->StartTime = this->CTest->CurrentTime(); - return this->ForkProcess(this->ResolveTimeout(), - &this->TestProperties->Environment); + double timeout = this->ResolveTimeout(); + + if(this->StopTimePassed) + { + return false; + } + return this->ForkProcess(timeout, &this->TestProperties->Environment); } //---------------------------------------------------------------------- @@ -569,8 +575,9 @@ double cmCTestRunTest::ResolveTimeout() if(stop_timeout <= 0 || stop_timeout > this->CTest->LastStopTimeout) { cmCTestLog(this->CTest, ERROR_MESSAGE, "The stop time has been passed. " - "Exiting ctest." << std::endl); - exit(-1); + "Stopping all tests." << std::endl); + this->StopTimePassed = true; + return 0; } return timeout == 0 ? stop_timeout : (timeout < stop_timeout ? timeout : stop_timeout); |