mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Refs #34013 -- Registered instance lookups as documented in tests.
This commit is contained in:
parent
c83c639ba0
commit
eea4f92f9a
2 changed files with 2 additions and 2 deletions
|
@ -1734,7 +1734,7 @@ class AggregateTestCase(TestCase):
|
|||
super().__init__(expr, 100)
|
||||
|
||||
sum_field = IntegerField()
|
||||
sum_field.register_instance_lookup(Mod100, "mod100")
|
||||
sum_field.register_lookup(Mod100, "mod100")
|
||||
publisher_pages = (
|
||||
Book.objects.values("publisher")
|
||||
.annotate(sum_pages=Sum("pages", output_field=sum_field))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue