MCPcopy Create free account
hub / github.com/MITK/MITK / TestRemoveVertexAtIndex

Function TestRemoveVertexAtIndex

Modules/ContourModel/Testing/mitkContourModelTest.cpp:157–169  ·  view source on GitHub ↗

Remove a vertex by index

Source from the content-addressed store, hash-verified

155
156// Remove a vertex by index
157static void TestRemoveVertexAtIndex()
158{
159 mitk::ContourModel::Pointer contour = mitk::ContourModel::New();
160
161 mitk::Point3D p;
162 p[0] = p[1] = p[2] = 0;
163
164 contour->AddVertex(p);
165
166 contour->RemoveVertexAt(0);
167
168 MITK_TEST_CONDITION(contour->GetNumberOfVertices() == 0, "removed vertex");
169}
170
171// Remove a vertex by position
172static void TestRemoveVertexAtWorldPosition()

Callers 1

mitkContourModelTestFunction · 0.85

Calls 4

GetNumberOfVerticesMethod · 0.80
NewFunction · 0.50
AddVertexMethod · 0.45
RemoveVertexAtMethod · 0.45

Tested by

no test coverage detected