diff options
Diffstat (limited to 'tests/postgres_tests/test_array.py')
| -rw-r--r-- | tests/postgres_tests/test_array.py | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/postgres_tests/test_array.py b/tests/postgres_tests/test_array.py index 89603e24a0..9e20ab3baf 100644 --- a/tests/postgres_tests/test_array.py +++ b/tests/postgres_tests/test_array.py @@ -414,6 +414,21 @@ class TestQuerying(PostgreSQLTestCase): [obj_1, obj_2], ) + def test_overlap_values(self): + qs = NullableIntegerArrayModel.objects.filter(order__lt=3) + self.assertCountEqual( + NullableIntegerArrayModel.objects.filter( + field__overlap=qs.values_list("field"), + ), + self.objs[:3], + ) + self.assertCountEqual( + NullableIntegerArrayModel.objects.filter( + field__overlap=qs.values("field"), + ), + self.objs[:3], + ) + def test_lookups_autofield_array(self): qs = ( NullableIntegerArrayModel.objects.filter( |
