1
0
mirror of https://github.com/django/django.git synced 2025-10-24 14:16:09 +00:00

Refs #34013 -- Registered instance lookups as documented in tests.

This commit is contained in:
Simon Charette
2023-12-16 14:05:36 -05:00
committed by GitHub
parent c83c639ba0
commit eea4f92f9a
2 changed files with 2 additions and 2 deletions

View File

@@ -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))