0
0
mirror of https://github.com/django/django.git synced 2024-12-01 15:42:04 +01:00
Commit Graph

208 Commits

Author SHA1 Message Date
Jani Tiainen
fcf494b48f Fixed #24688 -- Added Oracle support for new-style GIS functions. 2015-09-21 13:52:14 -04:00
Dražen Odobašić
b1e33ceced Fixed #23395 -- Limited line lengths to 119 characters. 2015-09-12 11:40:50 -04:00
Tim Graham
d3c92afe42 Fixed a GeoIP2 test failure with the latest GeoIP2 database.
Düsseldorf now appears as Dusseldorf in the latest version
of the GeoIP2 database.
2015-09-10 20:54:25 -04:00
Tim Graham
8a780ec847 Fixed GeoIP test crash when dependencies not installed. 2015-09-04 08:52:20 -04:00
Keryn Knight
d4b10a7256 Refs #24121 -- Added a repr() to gis.GeoIP and gis.GeoIP2. 2015-08-31 16:12:40 -04:00
Jani Tiainen
1b8d7eff3b Refs #12400 -- Added supports_geometry_field_unique_index GIS db feature. 2015-08-19 19:02:30 -04:00
Tim Graham
197b187810 Fixed #25225 -- Simplified code to remove GEOSIndexError
The test is a regression for refs #4740 to show that the original
fix of GEOSIndexError is no longer needed.
2015-08-18 19:10:47 -04:00
Tim Graham
b27547f9d1 Removed deprecated GeoManager from inspectdb/ogrinspect output.
refs ea27e26b09
2015-08-10 10:29:36 -04:00
Flavio Curella
1e2362ca0f Refs #25184 -- Started deprecation for contrib.gis.geoip. 2015-07-31 10:09:06 -04:00
Flavio Curella
7f0953ce1f Fixed #25184 -- Added support for MaxMind GeoLite2 database format 2015-07-31 09:45:03 -04:00
Tim Graham
5b6ca15073 Fixed #25183 -- Fixed non-deterministic GeoIP test.
google.com doesn't always resolve to an IP inside the United States.
2015-07-30 18:11:57 -04:00
Tim Graham
c041671167 Refs #25183 -- Added debugging for non-deterministic GeoIP test. 2015-07-28 07:41:18 -04:00
Flavio Curella
c2e70f0265 Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField 2015-07-27 18:28:13 -04:00
Claude Paroz
1da170a203 Fixed #25141 -- Diminished GDAL dependence during geojson serialization
Only require GDAL if contained geometries need coordinate transformations.
Thanks drepo for the report and Tim Graham for the review.
2015-07-20 20:22:29 +02:00
Claude Paroz
19fcf083d3 Replaced try/finally by mock.patch in geos tests 2015-07-18 15:34:40 +02:00
Claude Paroz
d72f8862cb Fixed #25072 -- Prevented GDALRaster memory to be uncollectable
Setting GDALRaster.bands as a cached property was creating a circular
reference with objects having __del__ methods, which means the memory
could never be freed.
Thanks Daniel Wiesmann for the report and test, and Tim Graham for the review.
2015-07-10 19:56:17 +02:00
Andriy Sokolovskiy
b40c551fdf Fixed some unclosed objects in tests 2015-07-06 10:10:40 -04:00
Claude Paroz
0cc39e50e1 Pushed GDAL skip condition inside test
As GDAL_VERSION is conditionnaly imported, it cannot be referenced
in skipIf decorator.
2015-06-26 14:57:45 +02:00
Daniel Wiesmann
b647ccfa67 Refs #24840 -- Added skip flag to raster transform test for GDAL<1.8.1.
Thanks to Simon Charette for the report.
2015-06-26 14:30:54 +02:00
Claude Paroz
3f9dca62cb Updated GeoIP test for newer versions 2015-06-25 21:47:54 +02:00
Tim Graham
aaacaeb096 Renamed RemovedInDjangoXYWarnings for new roadmap.
Forwardport of ae1d663b79
from stable/1.8.x plus more.
2015-06-24 16:08:20 -04:00
Daniel Wiesmann
c078021555 Refs #24840 -- Added GDALRaster Warp and transform methods
Thanks to Tim Graham for the review.
2015-06-24 18:31:22 +02:00
Daniel Wiesmann
c0fff64486 Fixed #25011, Refs #23804 -- Added check for GDAL on RasterField initialization 2015-06-23 16:11:42 -04:00
Claude Paroz
ffdf507ec0 Added GDAL 2.0 support 2015-06-20 14:40:50 +02:00
Daniel Wiesmann
b769bbd4f6 Fixed #23804 -- Added RasterField for PostGIS.
Thanks to Tim Graham and Claude Paroz for the reviews and patches.
2015-06-19 14:36:43 -04:00
Claude Paroz
7abf418eb1 Fixed GIS tests broken by 0a89915 2015-06-06 10:30:55 +02:00
Shai Berger
071801ccff Cleanup: Removed the try-except-fail antipattern from tests
Found cases where testing code was doing

    try:
        whatever
    except (some excption type):
        self.fail("exception shouldn't be thrown")

replaced it with just

    whatever

as this makes the unexpected errors easier to debug, and the tests
would fail just as much and aren't rendered less readable.

Thanks Markus Holtermann for review
2015-06-05 12:57:20 +03:00
Simon Charette
be67400b47 Refs #24652 -- Used SimpleTestCase where appropriate. 2015-05-20 13:46:13 -04:00
Claude Paroz
e60eccd62e Removed test numbering in gdal tests 2015-05-13 14:13:20 +02:00
Claude Paroz
d1df1fd2bb Fixed #24207 -- Added 25D-type geometry field support to ogrinspect
Thanks Michael Diener for the report and sample data, and Tim Graham
for the review.
2015-05-06 20:31:36 +02:00
Claude Paroz
e7e39d32fd Made some tests run on non-GIS databases 2015-05-05 20:28:28 +02:00
Alasdair Nicol
eaeea6f947 Fixed #24714 -- Used more specific assertions than assertEqual in tests. 2015-04-28 09:31:04 -04:00
Alasdair Nicol
d91321e8be Used assertIsInstance in tests. 2015-04-27 08:40:36 -04:00
Tim Graham
26996e2d55 Fixed #24499 -- Dropped support for PostGIS 1.5. 2015-04-25 12:21:16 -04:00
Claude Paroz
a37dcfd0a3 Delayed GDAL check for OSMGeoAdmin 2015-04-24 20:30:23 +02:00
Claude Paroz
d9bcba9b29 Removed many HAS_GEOS conditional imports 2015-04-24 20:30:23 +02:00
Claude Paroz
61d09e61f5 Lazy loading of GEOS functions 2015-04-24 20:30:23 +02:00
Claude Paroz
6d685b1674 Fixed failures with older Spatialite versions 2015-04-23 18:54:07 +02:00
Claude Paroz
ea27e26b09 Deprecated legacy GeoManager/GeoQuerySet methods 2015-04-22 19:54:17 +02:00
Claude Paroz
71e20814fc Added MySQL support to GIS functions 2015-04-22 19:54:17 +02:00
Claude Paroz
44bdbbc316 Added Spatialite support to GIS functions 2015-04-22 19:54:17 +02:00
Claude Paroz
d9ff5ef36d Fixed #24214 -- Added GIS functions to replace geoqueryset's methods
Thanks Simon Charette and Tim Graham for the reviews.
2015-04-22 19:54:17 +02:00
Claude Paroz
6b6d13bf6e Stopped conditional discovery of gis_tests apps
Refs #23879.
2015-04-18 15:17:49 +02:00
Tim Graham
ed336a1a5d Fixed gis_tests when run without GIS dependencies. 2015-04-16 19:59:53 -04:00
Anssi Kääriäinen
fb5c7748da Fixed #24615 -- ordering by expression not part of SELECT
Fixed queries where an expression was used in order_by() but the
expression wasn't in the query's select clause (for example the
expression could be masked by .values() call)

Thanks to Trac alias MattBlack85 for the report.
2015-04-16 09:40:47 +02:00
Riccardo Magliocchetti
a429a502ea Updated tests to stop leaking models in shared AdminSite.
This would break upcoming changes and AdminSite assumptions about
having an app_config for each application that has registered
models.
2015-04-15 09:45:26 -04:00
Tim Graham
ba1665ed75 Fixed skipping of gis_tests when dependencies not installed. 2015-03-28 09:39:09 -04:00
Moritz Sichert
1f2abf784a Fixed #24469 -- Refined escaping of Django's form elements in non-Django templates. 2015-03-27 19:46:20 -04:00
Claude Paroz
01ec127bae Fixed #12400 -- Allowed geometry fields in unique_together
Thanks Tim Graham for the review.
2015-03-23 19:52:49 +01:00
Claude Paroz
a6bada1ee0 Revert "Removed unneeded app_label definitions in gis_tests"
This reverts commit e0cc36f615.
The problem is the following:
  * With non-gis backends, gis_tests sub apps are not discovered
    (see runtests.py)
  * Consequently, the app_label is inferred from the gis_tests
    AppConfig
  * Then models with same names in different sub apps conflict
    because of same model_name/app_label pair.
2015-03-21 16:59:30 +01:00
Claude Paroz
e0cc36f615 Removed unneeded app_label definitions in gis_tests 2015-03-21 16:10:24 +01:00
Daniel Wiesmann
0d9b018e07 Fixed gis test failures when numpy isn't installed.
Thanks to Bas Peschier for pointing this out. Refs #23804.
2015-03-20 13:42:55 -04:00
Claude Paroz
65129aac07 Fixed #23757 -- Added 3D introspection support to Spatialite backend
Thanks Tim Graham for the review.
2015-03-18 19:27:44 +01:00
Daniel Wiesmann
b9cb81570e Made SRID a required parameter for GDALRaster instantiation; refs #23804.
Earlier versions of GDAL do not allow the srid to be set to 0,
so it should be a required parameter to ensure compatibility.
2015-03-17 08:16:12 -04:00
Daniel Wiesmann
f269c1d6f6 Added write support for GDALRaster
- Instantiation of GDALRaster instances from dict or json data.
- Retrieve and write pixel values in GDALBand objects.
- Support for the GDALFlushCache in gdal C prototypes
- Added private flush method to GDALRaster to make sure all
  data is written to files when file-based rasters are changed.
- Replaced ``ptr`` with ``_ptr`` for internal ptr variable

Refs #23804. Thanks Claude Paroz and Tim Graham for the reviews.
2015-03-16 19:37:43 +01:00
Aymeric Augustin
a8fe12417f Normalized usage of the tempfile module.
Specifically stopped using the dir argument.
2015-02-23 16:55:27 +01:00
Loic Bistuer
bed504d70b Fixed #24351, #24346 -- Changed the signature of allow_migrate().
The new signature enables better support for routing RunPython and
RunSQL operations, especially w.r.t. reusable and third-party apps.

This commit also takes advantage of the deprecation cycle for the old
signature to remove the backward incompatibility introduced in #22583;
RunPython and RunSQL won't call allow_migrate() when when the router
has the old signature.

Thanks Aymeric Augustin and Tim Graham for helping shape up the patch.

Refs 22583.
2015-02-20 21:34:09 +07:00
Tim Graham
ad0be620ae Moved contrib.gis tests out of contrib. 2015-02-11 10:29:54 -05:00