Opened 11 years ago
Closed 11 years ago
#22793 closed Bug (fixed)
GIS migrations tests attempt to import GeometryColumns from non-existing location
| Reported by: | Aymeric Augustin | Owned by: | nobody |
|---|---|---|---|
| Component: | GIS | Version: | dev |
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Accepted | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
In django/contrib/gis/tests/gis_migrations/test_operations.py:
try:
from django.contrib.gis.models import GeometryColumns
HAS_GEOMETRY_COLUMNS = True
except ImportError:
HAS_GEOMETRY_COLUMNS = False
But GeometryColumns isn't imported in django.contrib.gis.models any more since [cebd8753]. This results in tests being silently skipped.
The API to obtain the SpatialRefSys and GeometryColumns models for a given database connection is:
connection.ops.spatial_ref_sys() connection.ops.geometry_columns()
This bug doesn't affect the 1.7 branch.
Note:
See TracTickets
for help on using tickets.
In bc19ff6479261d80f3b1751700b7b9d4d7428211: