summaryrefslogtreecommitdiff
path: root/tests/gis_tests
AgeCommit message (Collapse)Author
2025-03-01[5.2.x] Applied Black's 2025 stable style.Mariusz Felisiak
https://github.com/psf/black/releases/tag/25.1.0 Backport of ff3aaf036f0cb66cd8f404cd51c603e68aaa7676 from main
2024-12-11Fixed #35989 -- Removed crs from GeoJSON serializer.Jeremy Thompson
Specification of coordinate reference systems (crs) was removed from the GeoJSON spec in 2016. https://datatracker.ietf.org/doc/html/rfc7946#appendix-B.1
2024-11-04Fixed #35883 -- Confirmed support for GDAL 3.9.David Smith
Updated test for change to exportToXML() which now errors out on unsupported projection methods. See https://github.com/OSGeo/gdal/issues/9223. Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2024-10-24Refs #35803 -- Added more tests for __coveredby and __covers GIS lookups.Mariusz Felisiak
Co-authored-by: David Smith <smithdc@gmail.com>
2024-10-22Refs #34406 -- Added support for GDAL curved geometries.David Smith
Co-authored-by: Fabien Le Frapper <contact@fabienlefrapper.me>
2024-10-17Fixed #35841 -- Restored support for DB-IP databases in GeoIP2.Nick Pope
Thanks Felix Farquharson for the report and Claude Paroz for the review. Regression in 40b5b1596f7505416bd30d5d7582b5a9004ea7d5. Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2024-10-17Refs #35841 -- Adjusted GeoIP2 tests for easier test case extension.Nick Pope
These changes will make it easier to introduce tests for alternate databases that may have different results without the need to duplicate lots of the tests definition.
2024-10-17Refs #35841 -- Updated GeoIP2 test database files.Nick Pope
The mmdb files were taken from https://github.com/maxmind/MaxMind-DB/commit/679e37e18a4a3009949c2213ec2c0bb8090c10c7.
2024-09-19Fixed #35074 -- Fixed adding/removing indexes when spatial_index is changed ↵Mariusz Felisiak
on MySQL, PostgreSQL, and Oracle. Co-authored-by: Mário Falcão <mario@falcao.dev>
2024-08-28Fixed #35666 -- Documented stacklevel usage and testing, and adjusted test ↵Simon Charette
suite accordingly. Over the years we've had multiple instances of hit and misses when emitting warnings: either setting the wrong stacklevel or not setting it at all. This work adds assertions for the existing warnings that were declaring the correct stacklevel, but were lacking tests for it.
2024-06-20Refs #35074 -- Avoided failed attempts to remove spatial indexes on nullable ↵Mariusz Felisiak
fields on MySQL. MySQL doesn't support spatial indexes on NULL columns, so there is no point in removing them.
2024-06-18Simplified OperationTestCase.alter_gis_model() test hook a bit.Mariusz Felisiak
This avoids passing "blank=False" and "srid=4326" to field classes, which are the default values, and removes special treatment for the "blank" parameter.
2024-03-18Refs #31014 -- Added srid argument to FromWKB/FromWKT() GIS functions.Claude Paroz
2024-03-10Applied BoundingCircle test to only one country.Claude Paroz
Looks like testing the second Country is much more computing-intensive and brings nothing to the test.
2024-03-07Fixed typos in docstrings and docs.cuinix
Signed-off-by: cuinix <915115094@qq.com>
2024-03-01Refs #35234 -- Deprecated CheckConstraint.check in favor of .condition.Simon Charette
Once the deprecation period ends CheckConstraint.check() can become the documented method that performs system checks for BaseConstraint subclasses.
2024-02-12Refs #35058 -- Added support for measured geometries to GDAL ↵David Smith
GeometryCollection and subclasses.
2024-01-31Refs #35058 -- Added support for measured geometries to GDAL Polygon.David Smith
2024-01-29Refs #35058 -- Added support for measured geometries to GDAL LineString.David Smith
2024-01-28Refs #35058 -- Made centroid available on all geometry types.David Smith
Centroid is available on all geometry types since GDAL 1.8.0. Previously it was restricted to Polygon. https://gdal.org/doxygen/classOGRGeometry.html#a91787f669b2a148169667e270e7e40df
2024-01-26Applied Black's 2024 stable style.Mariusz Felisiak
https://github.com/psf/black/releases/tag/24.1.0
2024-01-25Refs #35058 -- Added support for measured geometries to GDAL Point.David Smith
Co-authored-by: Nick Pope <nick@nickpope.me.uk>
2024-01-23Refs #35058 -- Deprecated OGRGeometry.coord_dim setter.David Smith
Reflecting a change in the underlying GDAL library (since GDAL 2.1) using coord_dim to set a geometries dimensions is deprecated in favor of set_3d().
2024-01-22Added more WKT and WKB tests.David Smith
2024-01-18Refs #35058 -- Added is_3d and set_3d() to OGRGeometry.David Smith
2024-01-16Fixed #35117 -- Added support for the hectare unit in Area.Alexis Athlani
2024-01-11Fixed #35100 -- Reworked GeoIP2 database initialization.Nick Pope
2024-01-10Fixed #35092 -- Exposed extra fields for GeoIP2.country() and GeoIP2.city() ↵Nick Pope
responses.
2024-01-07Fixed #35091 -- Allowed GeoIP2 querying using IPv4Address/IPv6Address.Nick Pope
2024-01-05Fixed #35086 -- Added support for BoundedCircle on Spatialite 5.1+.David Smith
Spatialite 5.1 added support for BoundingCircle (GEOSMinimumBoundingCircle). GEOS 3.7 is required which is lower than Django's currently supported minmum of 3.8. https://groups.google.com/g/spatialite-users/c/hAJ2SgitN4M https://www.gaia-gis.it/gaia-sins/spatialite-sql-5.1.0.html
2023-12-31Used addCleanup() in tests where appropriate.Mariusz Felisiak
2023-12-27Refs #35058 -- Made OGRGeomType aware of additional WKB geometry types.David Smith
This commit increases OGRGeomType's knowledge of WKB types and allows for improved error messages when Django doesn't yet have a corresponding class to wrap a given type.
2023-12-26Refs #35058 -- Added __repr__() to OGRGeomType.David Smith
2023-12-20Fixed #35049 -- Dropped support for GDAL 2.4.David Smith
2023-12-18Fixed #34411 -- Updated GDAL API to handle vector DataSource's.Claude Paroz
Co-authored-by: David Smith <smithdc@gmail.com>
2023-12-12Fixed #34305 -- Changed GeoIP2 tests to use MaxMind test databases.Nick Pope
GEOIP_SETTINGS is removed from the global scope as this prevents modifications to the settings using @override_settings in tests. Additional improvements now that we have stable test databases include: - Made testing more comprehensive and improved coverage - Patched socket.gethostbyname() for whole test case - Added testing of non-free GeoIP2 databases Co-authored-by: Tom Forbes <tom@tomforb.es>
2023-12-05Deprecated django.contrib.gis.geoip2.GeoIP2.open().Nick Pope
2023-12-01Made GeoIP2.__del__() close all databases.Nick Pope
2023-12-01Deprecated django.contrib.gis.geoip2.GeoIP2.coords().Nick Pope
The `ordering` argument is undocumented and of limited use, so this is effectively the same as `GeoIP2.lon_lat()`.
2023-10-11Refs #34882 -- Fixed GISFunctionsTests.test_asgeojson_option_0() test on Oracle.Mariusz Felisiak
This uses an example with the same precision for all databases. Follow up to 96e7a752b6c44a84e18d82d37524c1df64b32e12.
2023-10-06Fixed #34882 -- Fixed no options in AsGeoJSON() for geometries in ↵Denis Rouzaud
non-default CRS.
2023-10-04Fixed #34759 -- Confirmed support for SpatiaLite 5.1.pieterck
Thanks The Epic Dev for helping with tests.
2023-09-20Fixed #34851 -- Dropped support for PostgreSQL 12 and PostGIS 2.5.Mariusz Felisiak
2023-09-18Refs #33924 -- Removed BaseGeometryWidget.map_height/map_width attributes ↵Mariusz Felisiak
per deprecation timeline.
2023-08-22Removed unnecessary trailing commas in tests.konsti
2023-08-05Fixed #34739 -- Added GEOSGeometry.equals_identical() method.Olivier Tabone
2023-08-04Fixed #34686 -- Added support for GEOS 3.12.Olivier Tabone
2023-08-01Fixed #32820 -- Added aria-invalid="true" to fields with errors.Gregor Jerše
Co-authored-by: Demetris Stavrou <demestav@gmail.com> Co-authored-by: David Smith <smithdc@gmail.com>
2023-07-07Fixed #9602 -- Added AdminSite.get_model_admin().Mariusz Felisiak
This allows retrieving an admin class for the given model class without using internal attributes.
2023-06-30Fixed RelatedGeoModelTest.test_centroid_collect_filter().Mariusz Felisiak