mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Refs #31829 -- Added DatabaseFeatures.json_key_contains_list_matching_requires_list.
CockroachDB's behavior matches PostgreSQL.
This commit is contained in:
@@ -714,8 +714,9 @@ class TestQuerying(TestCase):
|
||||
)),
|
||||
),
|
||||
]
|
||||
# PostgreSQL requires a layer of nesting.
|
||||
if connection.vendor != 'postgresql':
|
||||
# For databases where {'f': 'g'} (without surrounding []) matches
|
||||
# [{'f': 'g'}].
|
||||
if not connection.features.json_key_contains_list_matching_requires_list:
|
||||
tests.append(('value__d__contains', {'f': 'g'}))
|
||||
for lookup, value in tests:
|
||||
with self.subTest(lookup=lookup, value=value):
|
||||
|
||||
Reference in New Issue
Block a user