#10420: Running gis tests via runtests doesn't work.
----------------------------------+-----------------------------------------
Reporter: mtredinnick | Owner: nobody
Status: new | Milestone: 1.1
Component: GIS | Version: SVN
Resolution: | Keywords:
Stage: Accepted | Has_patch: 0
Needs_docs: 0 | Needs_tests: 0
Needs_better_patch: 0 |
----------------------------------+-----------------------------------------
Comment (by mtredinnick):
I poked at this a bit more. The problem is all the places
`django.contrib.gis` imports `django.contrib.gis.db.backend`, which
requires actually executing database operations immediately (such as
querying the library version). Many of those imports aren't in the test
code, so delaying them affects mainline code
(`django.contrib.gis.db.models.aggregates`, for example)
It looks to be fairly fiddly to easily change that, although it's probably
something to look at in the future (post-1.1). Everywhere else in Django
we've aimed for being able to import things and then call
`settings.configure()` and the current gis behaviour doesn't allow that,
for example.
For right now, though, it's probably not worth investing a lot of time
pre-1.1 to fix this. It looks a little too invasive. I'll leave the
milestone alone for now in case I've missed something obvious that Justin
notices, but I could live with punting this until after the release. It's
still possible to test things via another app and it's a nice-to-have, not
a necessity.
--
Ticket URL: <http://code.djangoproject.com/ticket/10420#comment:2>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---