def add_model_boundaries( model, builder ): nb = 2 uuids = [] for i in range( nb ): uuids.append( builder.add_model_boundary() ) builder.set_model_boundary_name( uuids[-1], "boundary" + str(len( uuids )) ) temp_boundary = model.model_boundary( builder.add_model_boundary() ) builder.remove_model_boundary( temp_boundary ) if model.nb_model_boundaries() != nb: raise ValueError( "[Test] Section should have 2 model boundaries" ) if model.model_boundary( uuids[0] ).name() != "boundary1": raise ValueError( "[Test] Wrong ModelBoundary name" ) return uuids
def test_reloaded_brep(model): if model.nb_corners() != 6: raise ValueError( "[Test] Number of Corners in reloaded BRep should be 6") if model.nb_lines() != 9: raise ValueError("[Test] Number of Lines in reloaded BRep should be 9") if model.nb_surfaces() != 5: raise ValueError( "[Test] Number of Surfaces in reloaded BRep should be 5") if model.nb_blocks() != 1: raise ValueError( "[Test] Number of Blocks in reloaded BRep should be 1") if model.nb_model_boundaries() != 3: raise ValueError( "[Test] Number of Boundaries in reloaded BRep should be 3")