diff --git a/tests/modeltests/manipulators/models.py b/tests/modeltests/manipulators/models.py index 9b69c5ee80..1dd5615a75 100644 --- a/tests/modeltests/manipulators/models.py +++ b/tests/modeltests/manipulators/models.py @@ -88,12 +88,10 @@ Ultimate Ella datetime.date(2005, 2, 13) # Test follow (inline editing) functionality. ->>> follow = {"albums":True} ->>> man = Musician.ChangeManipulator(m1 ,follow=follow) +>>> man = Musician.ChangeManipulator(m1, follow={"albums": True}) >>> data = man.flatten_data() ->>> sorted(data.items(), cmp=lambda x,y: cmp(x[0],y[0])) +>>> sorted_list = data.items() +>>> sorted_list.sort(lambda x, y: cmp(x[0], y[0])) +>>> sorted_list [('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')] - - - """