Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed failing aggregation tests on MySQL

  • Loading branch information...
commit bd0cba58aafe582526086de86136060cedde38cf 1 parent 747f7d2
@akaariai akaariai authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 tests/aggregation_regress/tests.py
View
6 tests/aggregation_regress/tests.py
@@ -901,7 +901,7 @@ def test_aggregate_duplicate_columns(self):
# There should only be one GROUP BY clause, for the `id` column.
# `name` and `age` should not be grouped on.
- grouping, gb_params = results.query.get_compiler(using='default').get_grouping([])
+ grouping, gb_params = results.query.get_compiler(using='default').get_grouping([], [])
self.assertEqual(len(grouping), 1)
assert 'id' in grouping[0]
assert 'name' not in grouping[0]
@@ -930,7 +930,7 @@ def test_aggregate_duplicate_columns(self):
def test_aggregate_duplicate_columns_only(self):
# Works with only() too.
results = Author.objects.only('id', 'name').annotate(num_contacts=Count('book_contact_set'))
- grouping, gb_params = results.query.get_compiler(using='default').get_grouping([])
+ grouping, gb_params = results.query.get_compiler(using='default').get_grouping([], [])
self.assertEqual(len(grouping), 1)
assert 'id' in grouping[0]
assert 'name' not in grouping[0]
@@ -960,7 +960,7 @@ def test_aggregate_duplicate_columns_select_related(self):
# And select_related()
results = Book.objects.select_related('contact').annotate(
num_authors=Count('authors'))
- grouping, gb_params = results.query.get_compiler(using='default').get_grouping([])
+ grouping, gb_params = results.query.get_compiler(using='default').get_grouping([], [])
self.assertEqual(len(grouping), 1)
assert 'id' in grouping[0]
assert 'name' not in grouping[0]
Please sign in to comment.
Something went wrong with that request. Please try again.