mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Replaced @no_oracle skips with DatabaseFeatures.allows_group_by_lob.
This commit is contained in:
committed by
Mariusz Felisiak
parent
ad11f5b8c9
commit
755dbf39fc
@@ -222,10 +222,7 @@ class RelatedGeoModelTest(TestCase):
|
||||
self.assertIn('Aurora', names)
|
||||
self.assertIn('Kecksburg', names)
|
||||
|
||||
# TODO: fix on Oracle -- get the following error because the SQL is ordered
|
||||
# by a geometry object, which Oracle apparently doesn't like:
|
||||
# ORA-22901: cannot compare nested table or VARRAY or LOB attributes of an object type
|
||||
@no_oracle
|
||||
@skipUnlessDBFeature('allows_group_by_lob')
|
||||
def test12a_count(self):
|
||||
"Testing `Count` aggregate on geo-fields."
|
||||
# The City, 'Fort Worth' uses the same location as Dallas.
|
||||
@@ -247,10 +244,7 @@ class RelatedGeoModelTest(TestCase):
|
||||
self.assertEqual(1, len(vqs))
|
||||
self.assertEqual(3, vqs[0]['num_books'])
|
||||
|
||||
# TODO: fix on Oracle -- get the following error because the SQL is ordered
|
||||
# by a geometry object, which Oracle apparently doesn't like:
|
||||
# ORA-22901: cannot compare nested table or VARRAY or LOB attributes of an object type
|
||||
@no_oracle
|
||||
@skipUnlessDBFeature('allows_group_by_lob')
|
||||
def test13c_count(self):
|
||||
"Testing `Count` aggregate with `.values()`. See #15305."
|
||||
qs = Location.objects.filter(id=5).annotate(num_cities=Count('city')).values('id', 'point', 'num_cities')
|
||||
|
||||
Reference in New Issue
Block a user