mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
[4.1.x] Fixed GEOSTest.test_emptyCollections() on GEOS 3.8.0.
It's a regression in GEOS 3.8.0 fixed in GEOS 3.8.1.
Backport of 863aa7541d from main
This commit is contained in:
@@ -1127,8 +1127,10 @@ class GEOSTest(SimpleTestCase, TestDataMixin):
|
||||
|
||||
# Testing __getitem__ (doesn't work on Point or Polygon)
|
||||
if isinstance(g, Point):
|
||||
with self.assertRaises(IndexError):
|
||||
g.x
|
||||
# IndexError is not raised in GEOS 3.8.0.
|
||||
if geos_version_tuple() != (3, 8, 0):
|
||||
with self.assertRaises(IndexError):
|
||||
g.x
|
||||
elif isinstance(g, Polygon):
|
||||
lr = g.shell
|
||||
self.assertEqual("LINEARRING EMPTY", lr.wkt)
|
||||
|
||||
Reference in New Issue
Block a user