diff options
author | Kyle Edwards <kyle.edwards@kitware.com> | 2020-02-21 21:53:48 (GMT) |
---|---|---|
committer | Kyle Edwards <kyle.edwards@kitware.com> | 2020-02-24 20:44:01 (GMT) |
commit | 1dec35942215817ff2e7535239a89bc239abed16 (patch) | |
tree | 09a2fadf63e67e5e7e744e0972c5dc25198223e4 /Source/CTest/cmCTestRunTest.cxx | |
parent | 8d6ea4401c8fc4c18d070378fc5284b93c311d3a (diff) | |
download | CMake-1dec35942215817ff2e7535239a89bc239abed16.zip CMake-1dec35942215817ff2e7535239a89bc239abed16.tar.gz CMake-1dec35942215817ff2e7535239a89bc239abed16.tar.bz2 |
Refactor: Require detail when calling cmCTestRunTest::StartFailure()
Diffstat (limited to 'Source/CTest/cmCTestRunTest.cxx')
-rw-r--r-- | Source/CTest/cmCTestRunTest.cxx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/CTest/cmCTestRunTest.cxx b/Source/CTest/cmCTestRunTest.cxx index cc5de43..f0a3af1 100644 --- a/Source/CTest/cmCTestRunTest.cxx +++ b/Source/CTest/cmCTestRunTest.cxx @@ -324,8 +324,9 @@ bool cmCTestRunTest::StartAgain(size_t completed) cmWorkingDirectory workdir(this->TestProperties->Directory); if (workdir.Failed()) { this->StartFailure("Failed to change working directory to " + - this->TestProperties->Directory + " : " + - std::strerror(workdir.GetLastResult())); + this->TestProperties->Directory + " : " + + std::strerror(workdir.GetLastResult()), + "Failed to start"); return true; } @@ -381,7 +382,8 @@ void cmCTestRunTest::MemCheckPostProcess() handler->PostProcessTest(this->TestResult, this->Index); } -void cmCTestRunTest::StartFailure(std::string const& output) +void cmCTestRunTest::StartFailure(std::string const& output, + std::string const& detail) { // Still need to log the Start message so the test summary records our // attempt to start this test @@ -404,7 +406,7 @@ void cmCTestRunTest::StartFailure(std::string const& output) this->TestResult.ExecutionTime = cmDuration::zero(); this->TestResult.CompressOutput = false; this->TestResult.ReturnValue = -1; - this->TestResult.CompletionStatus = "Failed to start"; + this->TestResult.CompletionStatus = detail; this->TestResult.Status = cmCTestTestHandler::NOT_RUN; this->TestResult.TestCount = this->TestProperties->Index; this->TestResult.Name = this->TestProperties->Name; |