Changeset 1831
- Timestamp:
- 01/05/06 16:10:41 (3 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/branches/magic-removal/tests/modeltests/manipulators/models.py
r1765 r1831 89 89 90 90 # Test follow (inline editing) functionality. 91 >>> follow = {"albums":True} 92 >>> man = Musician.ChangeManipulator(m1 ,follow=follow) 91 >>> man = Musician.ChangeManipulator(m1, follow={"albums": True}) 93 92 >>> data = man.flatten_data() 94 >>> sorted(data.items(), cmp=lambda x,y: cmp(x[0],y[0])) 93 >>> sorted_list = data.items() 94 >>> sorted_list.sort(lambda x, y: cmp(x[0], y[0])) 95 >>> sorted_list 95 96 [('album.0.id', 1), ('album.0.name', 'Ella and Basie'), ('album.0.release_date', ''), ('album.1.id', 2), ('album.1.name', 'Ultimate Ella'), ('album.1.release_date', '2005-02-13'), ('first_name', 'Ella'), ('id', 1L), ('last_name', 'Fitzgerald')] 96 97 98 99 97 """
