test_singularity.py 381 B

123456789101112131415
  1. import unittest
  2. from shapely.geometry import Polygon
  3. class PolygonTestCase(unittest.TestCase):
  4. def test_polygon_3(self):
  5. p = (1.0, 1.0)
  6. poly = Polygon([p, p, p])
  7. assert poly.bounds == (1.0, 1.0, 1.0, 1.0)
  8. def test_polygon_5(self):
  9. p = (1.0, 1.0)
  10. poly = Polygon([p, p, p, p, p])
  11. assert poly.bounds == (1.0, 1.0, 1.0, 1.0)