@@ -59,10 +59,6 @@ class DatabaseFeatures(BaseDatabaseFeatures):
59
59
# the result back to UTC.
60
60
"db_functions.datetime.test_extract_trunc.DateFunctionWithTimeZoneTests.test_trunc_func_with_timezone" ,
61
61
"db_functions.datetime.test_extract_trunc.DateFunctionWithTimeZoneTests.test_trunc_timezone_applied_before_truncation" ,
62
- # pk__in=queryset doesn't work because subqueries aren't a thing in
63
- # MongoDB.
64
- "annotations.tests.NonAggregateAnnotationTestCase.test_annotation_and_alias_filter_in_subquery" ,
65
- "model_fields.test_jsonfield.TestQuerying.test_usage_in_subquery" ,
66
62
# Length of null considered zero rather than null.
67
63
"db_functions.text.test_length.LengthTests.test_basic" ,
68
64
# Key transforms are incorrectly treated as joins:
@@ -220,25 +216,11 @@ def django_test_expected_failures(self):
220
216
"timezones.tests.NewDatabaseTests.test_query_aggregation" ,
221
217
},
222
218
"QuerySet.annotate() has some limitations." : {
223
- # Exists not supported.
224
- "annotations.tests.NonAggregateAnnotationTestCase.test_annotation_exists_none_query" ,
225
- "lookup.tests.LookupTests.test_exact_exists" ,
226
- "lookup.tests.LookupTests.test_nested_outerref_lhs" ,
227
- "lookup.tests.LookupQueryingTests.test_filter_exists_lhs" ,
228
219
# annotate() with combined expressions doesn't work:
229
220
# 'WhereNode' object has no attribute 'field'
230
221
"lookup.tests.LookupQueryingTests.test_combined_annotated_lookups_in_filter" ,
231
222
"lookup.tests.LookupQueryingTests.test_combined_annotated_lookups_in_filter_false" ,
232
223
"lookup.tests.LookupQueryingTests.test_combined_lookups" ,
233
- # Subquery not supported.
234
- "annotations.tests.NonAggregateAnnotationTestCase.test_empty_queryset_annotation" ,
235
- "db_functions.comparison.test_coalesce.CoalesceTests.test_empty_queryset" ,
236
- "db_functions.datetime.test_extract_trunc.DateFunctionTests.test_extract_outerref" ,
237
- "db_functions.datetime.test_extract_trunc.DateFunctionTests.test_trunc_subquery_with_parameters" ,
238
- "expressions_case.tests.CaseExpressionTests.test_in_subquery" ,
239
- "lookup.tests.LookupQueryingTests.test_filter_subquery_lhs" ,
240
- "model_fields.test_jsonfield.TestQuerying.test_nested_key_transform_on_subquery" ,
241
- "model_fields.test_jsonfield.TestQuerying.test_obj_subquery_lookup" ,
242
224
# Invalid $project :: caused by :: Unknown expression $count,
243
225
"annotations.tests.NonAggregateAnnotationTestCase.test_combined_expression_annotation_with_aggregation" ,
244
226
"annotations.tests.NonAggregateAnnotationTestCase.test_combined_f_expression_annotation_with_aggregation" ,
@@ -263,6 +245,28 @@ def django_test_expected_failures(self):
263
245
# annotate().filter().count() gives incorrect results.
264
246
"db_functions.datetime.test_extract_trunc.DateFunctionTests.test_extract_year_exact_lookup" ,
265
247
},
248
+ "Exists is not supported on MongoDB." : {
249
+ "annotations.tests.NonAggregateAnnotationTestCase.test_annotation_exists_none_query" ,
250
+ "lookup.tests.LookupTests.test_exact_exists" ,
251
+ "lookup.tests.LookupTests.test_nested_outerref_lhs" ,
252
+ "lookup.tests.LookupQueryingTests.test_filter_exists_lhs" ,
253
+ },
254
+ "Subquery is not supported on MongoDB." : {
255
+ "annotations.tests.NonAggregateAnnotationTestCase.test_empty_queryset_annotation" ,
256
+ "db_functions.datetime.test_extract_trunc.DateFunctionTests.test_extract_outerref" ,
257
+ "db_functions.datetime.test_extract_trunc.DateFunctionTests.test_trunc_subquery_with_parameters" ,
258
+ "lookup.tests.LookupQueryingTests.test_filter_subquery_lhs" ,
259
+ "model_fields.test_jsonfield.TestQuerying.test_nested_key_transform_on_subquery" ,
260
+ "model_fields.test_jsonfield.TestQuerying.test_obj_subquery_lookup" ,
261
+ },
262
+ "Using a QuerySet in annotate() is not supported on MongoDB." : {
263
+ "annotations.tests.NonAggregateAnnotationTestCase.test_annotation_and_alias_filter_in_subquery" ,
264
+ "annotations.tests.NonAggregateAnnotationTestCase.test_empty_expression_annotation" ,
265
+ "db_functions.comparison.test_coalesce.CoalesceTests.test_empty_queryset" ,
266
+ "expressions_case.tests.CaseExpressionTests.test_in_subquery" ,
267
+ "lookup.tests.LookupTests.test_in_different_database" ,
268
+ "model_fields.test_jsonfield.TestQuerying.test_usage_in_subquery" ,
269
+ },
266
270
"Count doesn't work in QuerySet.annotate()" : {
267
271
"annotations.tests.AliasTests.test_alias_annotate_with_aggregation" ,
268
272
"annotations.tests.AliasTests.test_order_by_alias_aggregate" ,
0 commit comments