Browse Source

Fixed #33215 -- Confirmed support for GEOS 3.10.

Mariusz Felisiak 3 years ago
parent
commit
9231526af4
2 changed files with 7 additions and 2 deletions
  1. 2 1
      docs/ref/contrib/gis/install/geolibs.txt
  2. 5 1
      tests/gis_tests/geos_tests/test_io.py

+ 2 - 1
docs/ref/contrib/gis/install/geolibs.txt

@@ -8,7 +8,7 @@ geospatial libraries:
 ========================  ====================================  ================================  ======================================
 Program                   Description                           Required                          Supported Versions
 ========================  ====================================  ================================  ======================================
-:doc:`GEOS <../geos>`     Geometry Engine Open Source           Yes                               3.9, 3.8, 3.7, 3.6
+:doc:`GEOS <../geos>`     Geometry Engine Open Source           Yes                               3.10, 3.9, 3.8, 3.7, 3.6
 `PROJ`_                   Cartographic Projections library      Yes (PostgreSQL and SQLite only)  8.x, 7.x, 6.x, 5.x, 4.x
 :doc:`GDAL <../gdal>`     Geospatial Data Abstraction Library   Yes                               3.3, 3.2, 3.1, 3.0, 2.4, 2.3, 2.2, 2.1
 :doc:`GeoIP <../geoip2>`  IP-based geolocation library          No                                2
@@ -25,6 +25,7 @@ totally fine with GeoDjango. Your mileage may vary.
     GEOS 3.7.0 2018-09-10
     GEOS 3.8.0 2019-10-10
     GEOS 3.9.0 2020-12-14
+    GEOS 3.10.0 2021-10-20
     GDAL 2.1.0 2016-04
     GDAL 2.2.0 2017-05
     GDAL 2.3.0 2018-05

+ 5 - 1
tests/gis_tests/geos_tests/test_io.py

@@ -3,6 +3,7 @@ import binascii
 from django.contrib.gis.geos import (
     GEOSGeometry, Point, Polygon, WKBReader, WKBWriter, WKTReader, WKTWriter,
 )
+from django.contrib.gis.geos.libgeos import geos_version_tuple
 from django.test import SimpleTestCase
 
 
@@ -40,7 +41,10 @@ class GEOSIOTest(SimpleTestCase):
     def test_wktwriter_constructor_arguments(self):
         wkt_w = WKTWriter(dim=3, trim=True, precision=3)
         ref = GEOSGeometry('POINT (5.34562 23 1.5)')
-        ref_wkt = 'POINT Z (5.35 23 1.5)'
+        if geos_version_tuple() > (3, 10):
+            ref_wkt = 'POINT Z (5.346 23 1.5)'
+        else:
+            ref_wkt = 'POINT Z (5.35 23 1.5)'
         self.assertEqual(ref_wkt, wkt_w.write(ref).decode())
 
     def test03_wkbreader(self):