MCPcopy Create free account
hub / github.com/PyMesh/PyMesh / TEST_F

Function TEST_F

tests/tools/MeshUtils/MeshSeparatorTest.h:22–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20};
21
22TEST_F(MeshSeparatorTest, single_surface_component) {
23 Mesh::Ptr mesh = load_mesh("cube.obj");
24 const auto faces = MatrixUtils::reshape<MatrixIr>(mesh->get_faces(),
25 mesh->get_num_faces(), mesh->get_vertex_per_face());
26 MeshSeparator separator(faces);
27 size_t num_comps = separator.separate();
28 ASSERT_EQ(1, num_comps);
29
30 auto comp = separator.get_component(0);
31 ASSERT_EQ(mesh->get_num_faces(), comp.rows());
32 assert_sources_are_correct(faces, comp, separator.get_sources(0));
33}
34
35TEST_F(MeshSeparatorTest, single_volume_component) {
36 Mesh::Ptr mesh = load_mesh("cube.msh");

Callers

nothing calls this directly

Calls 11

load_meshFunction · 0.85
separateMethod · 0.80
get_componentMethod · 0.80
get_sourcesMethod · 0.80
set_connectivity_typeMethod · 0.80
get_facesMethod · 0.45
get_num_facesMethod · 0.45
get_vertex_per_faceMethod · 0.45
get_voxelsMethod · 0.45
get_num_voxelsMethod · 0.45
get_vertex_per_voxelMethod · 0.45

Tested by

no test coverage detected