diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2017-07-11 15:22:45 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-07-12 17:29:21 (GMT) |
commit | 0c650f39659a62c03012ec07dc32effd3bfba6e8 (patch) | |
tree | 33a1deb8d5e1e60746b5b0fe1987fe04f4f852ca /Source/CTest/cmCTestRunTest.cxx | |
parent | 1fda77d45565c3a819e6149597c3a194d9ccd0bb (diff) | |
download | CMake-0c650f39659a62c03012ec07dc32effd3bfba6e8.zip CMake-0c650f39659a62c03012ec07dc32effd3bfba6e8.tar.gz CMake-0c650f39659a62c03012ec07dc32effd3bfba6e8.tar.bz2 |
CTest: Report more detail about system exceptions in tests
This passes the system exception string up to CDash and to the command line
instead of just printing "other".
Diffstat (limited to 'Source/CTest/cmCTestRunTest.cxx')
-rw-r--r-- | Source/CTest/cmCTestRunTest.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/CTest/cmCTestRunTest.cxx b/Source/CTest/cmCTestRunTest.cxx index 0c4269e..9274c01 100644 --- a/Source/CTest/cmCTestRunTest.cxx +++ b/Source/CTest/cmCTestRunTest.cxx @@ -237,6 +237,8 @@ bool cmCTestRunTest::EndTest(size_t completed, size_t total, bool started) } else if (res == cmsysProcess_State_Exception) { outputTestErrorsToConsole = this->CTest->OutputTestOutputOnTestFailure; cmCTestLog(this->CTest, HANDLER_OUTPUT, "***Exception: "); + this->TestResult.ExceptionStatus = + this->TestProcess->GetExitExceptionString(); switch (this->TestProcess->GetExitException()) { case cmsysProcess_Exception_Fault: cmCTestLog(this->CTest, HANDLER_OUTPUT, "SegFault"); @@ -255,7 +257,8 @@ bool cmCTestRunTest::EndTest(size_t completed, size_t total, bool started) this->TestResult.Status = cmCTestTestHandler::NUMERICAL; break; default: - cmCTestLog(this->CTest, HANDLER_OUTPUT, "Other"); + cmCTestLog(this->CTest, HANDLER_OUTPUT, + this->TestResult.ExceptionStatus); this->TestResult.Status = cmCTestTestHandler::OTHER_FAULT; } } else if ("Disabled" == this->TestResult.CompletionStatus) { |