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

Fixed #24719 -- Restored the ability to use interators as queryset related object filters.

This commit is contained in:
Aric Coady
2015-04-27 15:23:56 -07:00
committed by Tim Graham
parent eaeea6f947
commit 9c2d8cde77
3 changed files with 8 additions and 1 deletions

View File

@@ -3502,6 +3502,7 @@ class RelatedLookupTypeTests(TestCase):
# child objects
self.assertQuerysetEqual(ObjectB.objects.filter(objecta__in=[self.coa]), [])
self.assertQuerysetEqual(ObjectB.objects.filter(objecta__in=[self.poa, self.coa]).order_by('name'), out_b)
self.assertQuerysetEqual(ObjectB.objects.filter(objecta__in=iter([self.poa, self.coa])).order_by('name'), out_b)
# parent objects
self.assertQuerysetEqual(ObjectC.objects.exclude(childobjecta=self.oa), out_c)