Issue #373 : Fix bug with get_real_instances on empty base_result_objects

This commit is contained in:
gtors
2019-01-30 14:36:21 +03:00
committed by Diederik van der Boor
parent 26fac56e31
commit f06a02a3d0
2 changed files with 9 additions and 1 deletions
+8
View File
@@ -332,6 +332,14 @@ class PolymorphicTests(TransactionTestCase):
transform=lambda o: o.__class__,
)
# from empty list
objects = Model2A.objects.get_real_instances([])
self.assertQuerysetEqual(
objects,
[],
transform=lambda o: o.__class__,
)
def test_translate_polymorphic_q_object(self):
self.create_model2abcd()