Skip to content

Commit

Permalink
Sort the lists before they are compared
Browse files Browse the repository at this point in the history
  • Loading branch information
FrostyX committed Apr 3, 2015
1 parent 5002585 commit 768cc73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/test_collections.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,6 @@ def test_packages_intersection(self):
p4 = Package("qux", 123)
p5 = Package("qux")
c1 = PackagesCollection([p1, p2, p3, p4])
self.assertEqual(c1.intersection([p1, p3]), PackagesCollection([p1, p3]))
self.assertEqual(c1.intersection([p1, p3]).sorted("name"), PackagesCollection([p1, p3]).sorted("name"))
self.assertEqual(c1.intersection(None), c1)
self.assertIsNotNone(c1.intersection([p5])[0].modified)

0 comments on commit 768cc73

Please sign in to comment.