diff options
author | Stefan Brand <stefan.brand@eox.at> | 2023-02-17 09:38:39 +0100 |
---|---|---|
committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2023-02-17 19:56:29 +0100 |
commit | d77762de038d1ab46cdcda2b7202d36c80956e25 (patch) | |
tree | dcb38776dd0c26f14fdc18357223d5c8f5e6568a /tests/gis_tests | |
parent | 52b054824e899db40ba48f908a9a00dadc56cb89 (diff) | |
download | django-d77762de038d1ab46cdcda2b7202d36c80956e25.tar.gz |
Refs #34302 -- Fixed SpatialReference.auth_name()/auth_code() when target is None.
force_bytes() turns None into the byte string b"None". Since
ctypes.c_char_p() also accepts None, we can bypass force_bytes() if
target is None.
Diffstat (limited to 'tests/gis_tests')
-rw-r--r-- | tests/gis_tests/gdal_tests/test_srs.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/gis_tests/gdal_tests/test_srs.py b/tests/gis_tests/gdal_tests/test_srs.py index fd25dcbc34..293144aa8e 100644 --- a/tests/gis_tests/gdal_tests/test_srs.py +++ b/tests/gis_tests/gdal_tests/test_srs.py @@ -35,7 +35,11 @@ srlist = ( ang_name="degree", lin_units=1.0, ang_units=0.0174532925199, - auth={"GEOGCS": ("EPSG", "4326"), "spheroid": ("EPSG", "7030")}, + auth={ + None: ("EPSG", "4326"), # Top-level authority. + "GEOGCS": ("EPSG", "4326"), + "spheroid": ("EPSG", "7030"), + }, attr=( ("DATUM", "WGS_1984"), (("SPHEROID", 1), "6378137"), @@ -64,6 +68,7 @@ srlist = ( lin_units=1.0, ang_units=0.0174532925199, auth={ + None: ("EPSG", "32140"), # Top-level authority. "PROJCS": ("EPSG", "32140"), "spheroid": ("EPSG", "7019"), "unit": ("EPSG", "9001"), |