Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[1.5.x] Fixed qs ordering related randomly failing test

The failure wasn't present in 1.6+, so this is not a backpatch.
  • Loading branch information...
commit bf4c8d8c9810b2c21cfc2fd619fcdf2f5ad5c7fd 1 parent b5ac25d
@akaariai akaariai authored
Showing with 6 additions and 1 deletion.
  1. +6 −1 tests/regressiontests/aggregation_regress/tests.py
View
7 tests/regressiontests/aggregation_regress/tests.py
@@ -588,10 +588,15 @@ def test_more_more_more(self):
)
publishers = publishers.annotate(n_books=Count("book"))
+ sorted_publishers = sorted(publishers, key=lambda x: x.name)
self.assertEqual(
- publishers[0].n_books,
+ sorted_publishers[0].n_books,
2
)
+ self.assertEqual(
+ sorted_publishers[1].n_books,
+ 1
+ )
self.assertEqual(
sorted(p.name for p in publishers),
Please sign in to comment.
Something went wrong with that request. Please try again.