Django

Code

Changeset 8091

Show
Ignore:
Timestamp:
07/26/08 09:49:39 (6 months ago)
Author:
russellm
Message:

Added an ordering definition to make test output reliable across database backends.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/tests/modeltests/model_formsets/models.py

    r8060 r8091  
    33class Author(models.Model): 
    44    name = models.CharField(max_length=100) 
     5 
     6    class Meta: 
     7        ordering = ('name',) 
    58 
    69    def __unicode__(self): 
     
    197200>>> formset.save_m2m() 
    198201>>> instances[0].authors.all() 
    199 [<Author: Charles Baudelaire>, <Author: Walt Whitman>, <Author: Paul Verlaine>, <Author: John Steinbeck>] 
     202[<Author: Charles Baudelaire>, <Author: John Steinbeck>, <Author: Paul Verlaine>, <Author: Walt Whitman>] 
    200203 
    201204# delete the author we created to allow later tests to continue working.