summaryrefslogtreecommitdiffstats
path: root/Source/CTest
diff options
context:
space:
mode:
authorNils Gladitz <nilsgladitz@gmail.com>2013-10-19 07:28:18 (GMT)
committerNils Gladitz <nilsgladitz@gmail.com>2013-10-19 07:28:18 (GMT)
commit1b750cbf9a77388b96b8fd3420c602d98a2e0ab9 (patch)
tree55789dc3b0432ed1db6fc796034fe8b368c48af9 /Source/CTest
parent6d4d7ca9551e60592003272a3a2039af4dee192e (diff)
downloadCMake-1b750cbf9a77388b96b8fd3420c602d98a2e0ab9.zip
CMake-1b750cbf9a77388b96b8fd3420c602d98a2e0ab9.tar.gz
CMake-1b750cbf9a77388b96b8fd3420c602d98a2e0ab9.tar.bz2
CTest: perform cycle test early
Diffstat (limited to 'Source/CTest')
-rw-r--r--Source/CTest/cmCTestMultiProcessHandler.cxx8
-rw-r--r--Source/CTest/cmCTestMultiProcessHandler.h1
2 files changed, 8 insertions, 1 deletions
diff --git a/Source/CTest/cmCTestMultiProcessHandler.cxx b/Source/CTest/cmCTestMultiProcessHandler.cxx
index a9aaf0c..33e88b2 100644
--- a/Source/CTest/cmCTestMultiProcessHandler.cxx
+++ b/Source/CTest/cmCTestMultiProcessHandler.cxx
@@ -41,6 +41,7 @@ cmCTestMultiProcessHandler::cmCTestMultiProcessHandler()
this->Completed = 0;
this->RunningCount = 0;
this->StopTimePassed = false;
+ this->HasCycles = false;
}
cmCTestMultiProcessHandler::~cmCTestMultiProcessHandler()
@@ -65,6 +66,11 @@ cmCTestMultiProcessHandler::SetTests(TestMap& tests,
if(!this->CTest->GetShowOnly())
{
this->ReadCostData();
+ this->HasCycles = !this->CheckCycles();
+ if(this->HasCycles)
+ {
+ return;
+ }
this->CreateTestCostList();
}
}
@@ -79,7 +85,7 @@ void cmCTestMultiProcessHandler::SetParallelLevel(size_t level)
void cmCTestMultiProcessHandler::RunTests()
{
this->CheckResume();
- if(!this->CheckCycles())
+ if(this->HasCycles)
{
return;
}
diff --git a/Source/CTest/cmCTestMultiProcessHandler.h b/Source/CTest/cmCTestMultiProcessHandler.h
index cd21d91..439a8f3 100644
--- a/Source/CTest/cmCTestMultiProcessHandler.h
+++ b/Source/CTest/cmCTestMultiProcessHandler.h
@@ -111,6 +111,7 @@ protected:
std::set<cmCTestRunTest*> RunningTests; // current running tests
cmCTestTestHandler * TestHandler;
cmCTest* CTest;
+ bool HasCycles;
};
#endif