#8138: Switch django tests to use transactions
----------------------------------------+-----------------------------------
          Reporter:  mremolt            |         Owner:  nobody  
            Status:  new                |     Milestone:  post-1.0
         Component:  Testing framework  |       Version:  SVN     
        Resolution:                     |      Keywords:          
             Stage:  Accepted           |     Has_patch:  1       
        Needs_docs:  0                  |   Needs_tests:  0       
Needs_better_patch:  0                  |  
----------------------------------------+-----------------------------------
Comment (by kmtracey):

 I've updated the patch in response to comments on the dev list:
 http://groups.google.com/group/django-
 developers/browse_thread/thread/1e4f4c840b180895/b1ed88f5ace403b4#

 The test suite is now reordered so that all the tests that are going to
 use rollback are run first.  That way they can count on a clean DB, just
 as they could when they did the flush/syncdb to begin.

 Consensus seems to be to leave the doctest running outside of any
 transaction, so changes made by doctests may bleed over into other tests
 (as they can today).

 I removed the commit of the timezone setting for postgres since it is not
 necessary to avoid the fixtures doctest error when doctests are not
 enclosed in a transaction.  If it can be observed in other tests, though,
 I'd be interested in hearing about it.  Having the timezone setting
 vulnerable to rollback seems odd to me.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/8138#comment:28>
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 django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to