MCPcopy Create free account
hub / github.com/MeshInspector/MeshLib / testComponentsMap

Function testComponentsMap

source/MRTestC2/MRMeshComponents.c:52–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50}
51
52void testComponentsMap( void )
53{
54 CreatedMesh m = createMesh();
55
56 MR_std_pair_MR_Face2RegionMap_int* map = MR_MeshComponents_getAllComponentsMap( m.part, NULL, NULL );
57 TEST_ASSERT( *MR_std_pair_MR_Face2RegionMap_int_second( map ) == 2 );
58 TEST_ASSERT( MR_Face2RegionMap_size( MR_std_pair_MR_Face2RegionMap_int_first( map ) ) == 24 );
59 TEST_ASSERT( MR_Face2RegionMap_index( MR_std_pair_MR_Face2RegionMap_int_first( map ), (MR_FaceId){0} )->id_ == 0 );
60 TEST_ASSERT( MR_Face2RegionMap_index( MR_std_pair_MR_Face2RegionMap_int_first( map ), (MR_FaceId){12} )->id_ == 1 );
61
62 MR_std_pair_MR_Face2RegionMap_int_Destroy( map );
63
64 destroyMesh( m );
65}
66
67void testLargeRegions( void )
68{

Callers

nothing calls this directly

Calls 2

createMeshFunction · 0.85
destroyMeshFunction · 0.85

Tested by

no test coverage detected