def test_iter_edges(self): """Test iter_edges method """ num_mesh = NumerrinMesh('test_mesh', self.mesh, self.pool) self.assertEqual(sum(1 for _ in num_mesh.iter(item_type=CUBA.EDGE)), num_mesh.count_of(CUBA.EDGE))
def test_iter_faces(self): """Test iter_faces method """ num_mesh = NumerrinMesh('test_mesh', self.mesh, self.pool) for face_f in num_mesh.iter(item_type=CUBA.FACE): face = self.mesh.get(face_f.uid) self.assertEqual(face.points, face_f.points)
def test_iter_points(self): """Test iter_points method """ num_mesh = NumerrinMesh('test_mesh', self.mesh, self.pool) for point_f in num_mesh.iter(item_type=CUBA.POINT): point = self.mesh.get(point_f.uid) self.assertEqual(point.data[CUBA.VELOCITY], point_f.data[CUBA.VELOCITY]) self.assertEqual(point.data[CUBA.PRESSURE], point_f.data[CUBA.PRESSURE])