summaryrefslogtreecommitdiffstats
path: root/Source/CTest/cmCTestMultiProcessHandler.cxx
diff options
context:
space:
mode:
authorZack Galbreath <zack.galbreath@kitware.com>2015-02-17 19:23:56 (GMT)
committerBrad King <brad.king@kitware.com>2015-02-23 15:01:59 (GMT)
commit876a680d4851a39e77b49daa3c670fe2e535c1e6 (patch)
tree74a2032fe2e2029a6b26d3991771f26957828344 /Source/CTest/cmCTestMultiProcessHandler.cxx
parent49ba4545c272f5bb00828dfe35e5a63749b4aa43 (diff)
downloadCMake-876a680d4851a39e77b49daa3c670fe2e535c1e6.zip
CMake-876a680d4851a39e77b49daa3c670fe2e535c1e6.tar.gz
CMake-876a680d4851a39e77b49daa3c670fe2e535c1e6.tar.bz2
ctest_test: Add QUIET option
Diffstat (limited to 'Source/CTest/cmCTestMultiProcessHandler.cxx')
-rw-r--r--Source/CTest/cmCTestMultiProcessHandler.cxx47
1 files changed, 28 insertions, 19 deletions
diff --git a/Source/CTest/cmCTestMultiProcessHandler.cxx b/Source/CTest/cmCTestMultiProcessHandler.cxx
index f223127..eb33d8e 100644
--- a/Source/CTest/cmCTestMultiProcessHandler.cxx
+++ b/Source/CTest/cmCTestMultiProcessHandler.cxx
@@ -113,7 +113,8 @@ void cmCTestMultiProcessHandler::RunTests()
//---------------------------------------------------------
void cmCTestMultiProcessHandler::StartTestProcess(int test)
{
- cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, "test " << test << "\n");
+ cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
+ "test " << test << "\n", this->Quiet);
this->TestRunningMap[test] = true; // mark the test as running
// now remove the test itself
this->EraseTest(test);
@@ -639,39 +640,44 @@ void cmCTestMultiProcessHandler::PrintTestList()
if(!p.Labels.empty()) //print the labels
{
- cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, "Labels:");
+ cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT, "Labels:",
+ this->Quiet);
}
for(std::vector<std::string>::iterator label = p.Labels.begin();
label != p.Labels.end(); ++label)
{
- cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, " " << *label);
+ cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT, " " << *label,
+ this->Quiet);
}
if(!p.Labels.empty()) //print the labels
{
- cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT, std::endl,
+ this->Quiet);
}
if (this->TestHandler->MemCheck)
{
- cmCTestLog(this->CTest, HANDLER_OUTPUT, " Memory Check");
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT, " Memory Check",
+ this->Quiet);
}
else
{
- cmCTestLog(this->CTest, HANDLER_OUTPUT, " Test");
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT, " Test", this->Quiet);
}
std::ostringstream indexStr;
indexStr << " #" << p.Index << ":";
- cmCTestLog(this->CTest, HANDLER_OUTPUT,
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
std::setw(3 + getNumWidth(this->TestHandler->GetMaxIndex()))
- << indexStr.str());
- cmCTestLog(this->CTest, HANDLER_OUTPUT, " ");
- cmCTestLog(this->CTest, HANDLER_OUTPUT, p.Name.c_str() << std::endl);
+ << indexStr.str(), this->Quiet);
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT, " ", this->Quiet);
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
+ p.Name.c_str() << std::endl, this->Quiet);
//pop working dir
cmSystemTools::ChangeDirectory(current_dir);
}
- cmCTestLog(this->CTest, HANDLER_OUTPUT, std::endl << "Total Tests: "
- << this->Total << std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT, std::endl << "Total Tests: "
+ << this->Total << std::endl, this->Quiet);
}
void cmCTestMultiProcessHandler::PrintLabels()
@@ -686,16 +692,19 @@ void cmCTestMultiProcessHandler::PrintLabels()
if(!allLabels.empty())
{
- cmCTestLog(this->CTest, HANDLER_OUTPUT, "All Labels:" << std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
+ "All Labels:" << std::endl, this->Quiet);
}
else
{
- cmCTestLog(this->CTest, HANDLER_OUTPUT, "No Labels Exist" << std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
+ "No Labels Exist" << std::endl, this->Quiet);
}
for(std::set<std::string>::iterator label = allLabels.begin();
label != allLabels.end(); ++label)
{
- cmCTestLog(this->CTest, HANDLER_OUTPUT, " " << *label << std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
+ " " << *label << std::endl, this->Quiet);
}
}
@@ -758,8 +767,8 @@ int cmCTestMultiProcessHandler::FindMaxIndex()
//Returns true if no cycles exist in the dependency graph
bool cmCTestMultiProcessHandler::CheckCycles()
{
- cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
- "Checking test dependency graph..." << std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
+ "Checking test dependency graph..." << std::endl, this->Quiet);
for(TestMap::iterator it = this->Tests.begin();
it != this->Tests.end(); ++it)
{
@@ -794,7 +803,7 @@ bool cmCTestMultiProcessHandler::CheckCycles()
}
}
}
- cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
- "Checking test dependency graph end" << std::endl);
+ cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
+ "Checking test dependency graph end" << std::endl, this->Quiet);
return true;
}