/[thuban]/branches/WIP-pyshapelib-bramz/test/test_layer.py
ViewVC logotype

Diff of /branches/WIP-pyshapelib-bramz/test/test_layer.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 409 by jonathan, Wed Feb 19 16:50:39 2003 UTC revision 599 by bh, Thu Apr 3 11:37:13 2003 UTC
# Line 1  Line 1 
1  # Copyright (c) 2002 by Intevation GmbH  # Copyright (c) 2002, 2003 by Intevation GmbH
2  # Authors:  # Authors:
3  # Bernhard Herzog <[email protected]>  # Bernhard Herzog <[email protected]>
4  #  #
# Line 54  class TestLayer(unittest.TestCase, suppo Line 54  class TestLayer(unittest.TestCase, suppo
54                                    -13.55668830871582, 66.520111083984375])                                    -13.55668830871582, 66.520111083984375])
55          self.assertEquals(layer.ShapesInRegion((-24.0, 64.0, -23.75, 64.25)),          self.assertEquals(layer.ShapesInRegion((-24.0, 64.0, -23.75, 64.25)),
56                            [613, 726, 838])                            [613, 726, 838])
57            layer.Destroy()
58    
59      def test_polygon_layer(self):      def test_polygon_layer(self):
60          """Test Layer with polygon shapes"""          """Test Layer with polygon shapes"""
# Line 73  class TestLayer(unittest.TestCase, suppo Line 74  class TestLayer(unittest.TestCase, suppo
74                                    -13.495815277099609, 66.563774108886719])                                    -13.495815277099609, 66.563774108886719])
75          self.assertEquals(layer.ShapesInRegion((-24.0, 64.0, -23.9, 64.1)),          self.assertEquals(layer.ShapesInRegion((-24.0, 64.0, -23.9, 64.1)),
76                            [91, 92, 144, 146, 148, 150, 152, 153])                            [91, 92, 144, 146, 148, 150, 152, 153])
77            layer.Destroy()
78    
79      def test_point_layer(self):      def test_point_layer(self):
80          """Test Layer with point shapes"""          """Test Layer with point shapes"""
# Line 90  class TestLayer(unittest.TestCase, suppo Line 92  class TestLayer(unittest.TestCase, suppo
92                                    -15.12291431427002, 66.36572265625])                                    -15.12291431427002, 66.36572265625])
93          self.assertEquals(layer.ShapesInRegion((-24.0, 64.0, -23.80, 64.1)),          self.assertEquals(layer.ShapesInRegion((-24.0, 64.0, -23.80, 64.1)),
94                            [0, 1, 2, 3, 4, 5, 27, 28, 29, 30, 31])                            [0, 1, 2, 3, 4, 5, 27, 28, 29, 30, 31])
95            layer.Destroy()
96    
97      def test_empty_layer(self):      def test_empty_layer(self):
98          """Test Layer with empty shape file"""          """Test Layer with empty shape file"""
# Line 108  class TestLayer(unittest.TestCase, suppo Line 111  class TestLayer(unittest.TestCase, suppo
111          self.assertEquals(layer.BoundingBox(), None)          self.assertEquals(layer.BoundingBox(), None)
112          self.assertEquals(layer.LatLongBoundingBox(), None)          self.assertEquals(layer.LatLongBoundingBox(), None)
113          self.assertEquals(layer.NumShapes(), 0)          self.assertEquals(layer.NumShapes(), 0)
114            layer.Destroy()
115    
116    
117  class TestLayerLegend(unittest.TestCase, support.SubscriberMixin):  class TestLayerLegend(unittest.TestCase, support.SubscriberMixin):
# Line 175  class TestLayerLegend(unittest.TestCase, Line 179  class TestLayerLegend(unittest.TestCase,
179    
180    
181  if __name__ == "__main__":  if __name__ == "__main__":
182      unittest.main()      support.run_tests()

Legend:
Removed from v.409  
changed lines
  Added in v.599

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26