mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Fixed #24687 -- Added select_related() validation for nested non-relational fields.
The removed test was added in the original select_related() validation
patch (45d4e43d2d
), but there doesn't
seem to be any reason for it.
Thanks Claude Paroz for help and review.
This commit is contained in:
parent
5171f56fae
commit
67732a9b18
7 changed files with 31 additions and 13 deletions
|
@ -62,6 +62,9 @@ class RelatedGeoModelTest(TestCase):
|
|||
qs = list(City.objects.filter(name=name).transform(srid, field_name='location__point'))
|
||||
check_pnt(GEOSGeometry(wkt, srid), qs[0].location.point)
|
||||
|
||||
# Relations more than one level deep can be queried.
|
||||
self.assertEqual(list(Parcel.objects.transform(srid, field_name='city__location__point')), [])
|
||||
|
||||
@skipUnlessDBFeature("supports_extent_aggr")
|
||||
def test_related_extent_aggregate(self):
|
||||
"Testing the `Extent` aggregate on related geographic models."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue