MCPcopy Create free account
hub / github.com/Kitware/CMake / FinishTestProcess

Method FinishTestProcess

Source/CTest/cmCTestMultiProcessHandler.cxx:779–820  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

777}
778
779void cmCTestMultiProcessHandler::FinishTestProcess(
780 std::unique_ptr<cmCTestRunTest> runner, bool started)
781{
782 this->Completed++;
783
784 int test = runner->GetIndex();
785 auto* properties = runner->GetTestProperties();
786
787 cmCTestRunTest::EndTestResult testResult =
788 runner->EndTest(this->Completed, this->Total, started);
789 if (testResult.StopTimePassed) {
790 this->SetStopTimePassed();
791 }
792 if (started) {
793 if (!this->StopTimePassed &&
794 cmCTestRunTest::StartAgain(std::move(runner), this->Completed)) {
795 this->Completed--; // remove the completed test because run again
796 return;
797 }
798 }
799
800 if (testResult.Passed) {
801 this->Passed->push_back(properties->Name);
802 } else if (!properties->Disabled) {
803 this->Failed->push_back(properties->Name);
804 }
805
806 for (auto& t : this->PendingTests) {
807 t.second.Depends.erase(test);
808 }
809
810 this->WriteCheckpoint(test);
811 this->DeallocateResources(test);
812 this->UnlockResources(test);
813
814 runner.reset();
815
816 if (this->JobServerClient) {
817 this->JobServerClient->ReleaseToken();
818 }
819 this->StartNextTestsOnIdle();
820}
821
822void cmCTestMultiProcessHandler::UpdateCostData()
823{

Callers 1

FinalizeTestMethod · 0.80

Calls 13

SetStopTimePassedMethod · 0.95
WriteCheckpointMethod · 0.95
DeallocateResourcesMethod · 0.95
UnlockResourcesMethod · 0.95
StartNextTestsOnIdleMethod · 0.95
moveFunction · 0.85
GetIndexMethod · 0.80
GetTestPropertiesMethod · 0.80
EndTestMethod · 0.80
push_backMethod · 0.80
eraseMethod · 0.80
ReleaseTokenMethod · 0.80

Tested by

no test coverage detected