@@ -38,6 +38,9 @@ class DatabaseFeatures(BaseDatabaseFeatures):
38
38
"expressions.tests.NegatedExpressionTests.test_filter" ,
39
39
"expressions_case.tests.CaseExpressionTests.test_order_by_conditional_implicit" ,
40
40
# NotSupportedError: order_by() expression not supported.
41
+ # Lookup in order_by() not supported:
42
+ # argument of type '<database function>' is not iterable
43
+ "aggregation.tests.AggregateTestCase.test_aggregation_order_by_not_selected_annotation_values" ,
41
44
"db_functions.comparison.test_coalesce.CoalesceTests.test_ordering" ,
42
45
"db_functions.tests.FunctionTests.test_nested_function_ordering" ,
43
46
"db_functions.text.test_length.LengthTests.test_ordering" ,
@@ -124,6 +127,13 @@ class DatabaseFeatures(BaseDatabaseFeatures):
124
127
"queries.test_explain.ExplainUnsupportedTests.test_message" ,
125
128
# filter() on related model + update() doesn't work.
126
129
"queries.tests.Queries5Tests.test_ticket9848" ,
130
+ # Variance is not implemented in mongo as an aggregation,
131
+ # we should transform it into StdDev * 2.
132
+ "aggregation.test_filter_argument.FilteredAggregateTests.test_filtered_numerical_aggregates" ,
133
+ # Sum returns 0 instead of None in mongodb.
134
+ "aggregation.test_filter_argument.FilteredAggregateTests.test_plain_annotate" ,
135
+ "aggregation.tests.AggregateTestCase.test_annotation_expressions" ,
136
+ "aggregation.tests.AggregateTestCase.test_reverse_fkey_annotate" ,
127
137
}
128
138
# $bitAnd, #bitOr, and $bitXor are new in MongoDB 6.3.
129
139
_django_test_expected_failures_bitwise = {
@@ -299,6 +309,7 @@ def django_test_expected_failures(self):
299
309
"timezones.tests.NewDatabaseTests.test_query_annotation" ,
300
310
},
301
311
"Exists is not supported on MongoDB." : {
312
+ "aggregation.test_filter_argument.FilteredAggregateTests.test_filtered_aggregate_ref_multiple_subquery_annotation" ,
302
313
"annotations.tests.NonAggregateAnnotationTestCase.test_annotation_exists_none_query" ,
303
314
"delete_regress.tests.DeleteTests.test_self_reference_with_through_m2m_at_second_level" ,
304
315
"expressions.tests.BasicExpressionsTests.test_annotation_with_deeply_nested_outerref" ,
@@ -343,6 +354,14 @@ def django_test_expected_failures(self):
343
354
"queries.tests.Ticket22429Tests.test_ticket_22429" ,
344
355
},
345
356
"Subquery is not supported on MongoDB." : {
357
+ "aggregation.tests.AggregateAnnotationPruningTests.test_referenced_composed_subquery_requires_wrapping" ,
358
+ "aggregation.tests.AggregateAnnotationPruningTests.test_referenced_subquery_requires_wrapping" ,
359
+ "aggregation.tests.AggregateTestCase.test_aggregation_nested_subquery_outerref" ,
360
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation" ,
361
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_multivalued" ,
362
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_related_field" ,
363
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_values" ,
364
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_values_collision" ,
346
365
"annotations.tests.NonAggregateAnnotationTestCase.test_annotation_filter_with_subquery" ,
347
366
"annotations.tests.NonAggregateAnnotationTestCase.test_annotation_subquery_outerref_transform" ,
348
367
"annotations.tests.NonAggregateAnnotationTestCase.test_empty_queryset_annotation" ,
@@ -519,6 +538,7 @@ def django_test_expected_failures(self):
519
538
"queries.tests.Queries6Tests.test_col_alias_quoted" ,
520
539
},
521
540
"Test executes raw SQL." : {
541
+ "aggregation.tests.AggregateTestCase.test_coalesced_empty_result_set" ,
522
542
"annotations.tests.NonAggregateAnnotationTestCase.test_raw_sql_with_inherited_field" ,
523
543
"delete_regress.tests.DeleteLockingTest.test_concurrent_delete" ,
524
544
"expressions.tests.BasicExpressionsTests.test_annotate_values_filter" ,
@@ -610,6 +630,7 @@ def django_test_expected_failures(self):
610
630
"model_fields.test_jsonfield.TestQuerying.test_none_key_exclude" ,
611
631
},
612
632
"Randomized ordering isn't supported by MongoDB." : {
633
+ "aggregation.tests.AggregateTestCase.test_aggregation_random_ordering" ,
613
634
"ordering.tests.OrderingTests.test_random_ordering" ,
614
635
},
615
636
"Queries without a collection aren't supported on MongoDB." : {
@@ -625,6 +646,7 @@ def django_test_expected_failures(self):
625
646
"aggregation.tests.AggregateAnnotationPruningTests.test_non_aggregate_annotation_pruned" ,
626
647
"aggregation.tests.AggregateTestCase.test_add_implementation" ,
627
648
"aggregation.tests.AggregateTestCase.test_aggregation_default_using_datetime_from_database" ,
649
+ "aggregation.tests.AggregateTestCase.test_multi_arg_aggregate" ,
628
650
# SQL custom values.
629
651
"aggregation.tests.AggregateTestCase.test_aggregation_default_using_date_from_database" ,
630
652
# No sql generate
@@ -636,7 +658,17 @@ def django_test_expected_failures(self):
636
658
"aggregation.tests.AggregateAnnotationPruningTests.test_referenced_aggregate_annotation_kept" ,
637
659
# Using a QuerySet in annotate() is not supported on MongoDB
638
660
"aggregation.tests.AggregateTestCase.test_group_by_subquery_annotation" ,
639
- }
661
+ # Query set with annotate not supported.
662
+ "aggregation.tests.AggregateTestCase.test_group_by_reference_subquery" ,
663
+ "aggregation.tests.AggregateTestCase.test_filter_in_subquery_or_aggregation" ,
664
+ # Exists is not supported in mongodb
665
+ "aggregation.tests.AggregateTestCase.test_aggregation_exists_multivalued_outeref" ,
666
+ "aggregation.tests.AggregateTestCase.test_group_by_exists_annotation" ,
667
+ "aggregation.tests.AggregateTestCase.test_exists_none_with_aggregate" ,
668
+ "aggregation.tests.AggregateTestCase.test_exists_extra_where_with_aggregate" ,
669
+ # Queryset dates not supported
670
+ "aggregation.tests.AggregateTestCase.test_dates_with_aggregation" ,
671
+ },
640
672
}
641
673
642
674
@cached_property
0 commit comments