mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Removed hardcoded paths to SpatialRefSys models in tests.
This commit is contained in:
parent
a7a4ff1026
commit
71ae1ab012
2 changed files with 14 additions and 23 deletions
|
@ -52,21 +52,6 @@ spatialite = _default_db == 'spatialite'
|
|||
# MySQL spatial indices can't handle NULL geometries.
|
||||
gisfield_may_be_null = not mysql
|
||||
|
||||
if oracle and 'gis' in settings.DATABASES[DEFAULT_DB_ALIAS]['ENGINE']:
|
||||
from django.contrib.gis.db.backends.oracle.models import (
|
||||
OracleSpatialRefSys as SpatialRefSys,
|
||||
)
|
||||
elif postgis:
|
||||
from django.contrib.gis.db.backends.postgis.models import (
|
||||
PostGISSpatialRefSys as SpatialRefSys,
|
||||
)
|
||||
elif spatialite:
|
||||
from django.contrib.gis.db.backends.spatialite.models import (
|
||||
SpatialiteSpatialRefSys as SpatialRefSys,
|
||||
)
|
||||
else:
|
||||
SpatialRefSys = None
|
||||
|
||||
|
||||
class FuncTestMixin:
|
||||
"""Assert that Func expressions aren't mutated during their as_sql()."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue