(self)
| 22 | self.assertEqual(bds, [1., -1., 1., -1., 1., -1.]) |
| 23 | |
| 24 | def testReader(self): |
| 25 | r = io.vtkCellGridReader() |
| 26 | r.SetFileName(os.path.join(Testing.VTK_DATA_ROOT, 'Data', 'dgHexahedra.dg')) |
| 27 | r.Update() |
| 28 | g = r.GetOutput() |
| 29 | self.assertEqual(g.GetNumberOfCells(), 2) |
| 30 | s = g.GetShapeAttribute() |
| 31 | self.assertEqual(s.GetNumberOfComponents(), 3) |
| 32 | bds = [0, 0, 0, 0, 0, 0] |
| 33 | g.GetBounds(bds) |
| 34 | self.assertEqual(bds, [0.0, 2.0, 0.0, 1.25, 0.0, 1.0]) |
| 35 | # TODO: Fetch cell types, cell metadata |
| 36 | |
| 37 | if __name__ == "__main__": |
| 38 | Testing.main([(TestCellGrid, 'test')]) |
nothing calls this directly
no test coverage detected