Django

Code

Changeset 7174

Show
Ignore:
Timestamp:
02/28/08 11:53:00 (6 months ago)
Author:
mtredinnick
Message:

queryset-refactor: Fixed a problem in the test-suite that was annoying.
Only fails on PostgreSQL and only fails on the next test.

Also identified the other area that causes both PostgreSQL backends (only) to
fail. Don't really understand why at the moment, but this is the culprit.
Tricky to reproduce, too, you have to run "queries" and "views" together, in
that order to see it.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/branches/queryset-refactor/tests/modeltests/one_to_one/models.py

    r7096 r7174  
    77""" 
    88 
    9 from django.db import models 
     9from django.db import models, connection 
    1010 
    1111class Place(models.Model): 
     
    186186    ... 
    187187IntegrityError: ... 
     188 
     189# Because the unittests all use a single connection, we need to force a 
     190# reconnect here to ensure the connection is clean (after the previous 
     191# IntegrityError). 
     192>>> connection.close() 
    188193"""} 
  • django/branches/queryset-refactor/tests/regressiontests/queries/models.py

    r7170 r7174  
    538538We can do slicing beyond what is currently in the result cache, too. 
    539539 
     540# FIXME!! This next test causes really weird PostgreSQL behaviour, but it's 
     541# only apparent much later when the full test suite runs. I don't understand 
     542# what's going on here yet. 
     543 
    540544# We need to mess with the implemenation internals a bit here to decrease the 
    541545# cache fill size so that we don't read all the results at once.