@@ -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" ,
@@ -95,6 +98,10 @@ class DatabaseFeatures(BaseDatabaseFeatures):
95
98
# QuerySet.explain() not implemented:
96
99
# https://github.com/mongodb-labs/django-mongodb/issues/28
97
100
"queries.test_explain.ExplainUnsupportedTests.test_message" ,
101
+ # Sum returns 0 instead of None in mongodb.
102
+ "aggregation.test_filter_argument.FilteredAggregateTests.test_plain_annotate" ,
103
+ "aggregation.tests.AggregateTestCase.test_annotation_expressions" ,
104
+ "aggregation.tests.AggregateTestCase.test_reverse_fkey_annotate" ,
98
105
}
99
106
# $bitAnd, #bitOr, and $bitXor are new in MongoDB 6.3.
100
107
_django_test_expected_failures_bitwise = {
@@ -270,6 +277,7 @@ def django_test_expected_failures(self):
270
277
"timezones.tests.NewDatabaseTests.test_query_annotation" ,
271
278
},
272
279
"Exists is not supported on MongoDB." : {
280
+ "aggregation.test_filter_argument.FilteredAggregateTests.test_filtered_aggregate_ref_multiple_subquery_annotation" ,
273
281
"annotations.tests.NonAggregateAnnotationTestCase.test_annotation_exists_none_query" ,
274
282
"delete_regress.tests.DeleteTests.test_self_reference_with_through_m2m_at_second_level" ,
275
283
"expressions.tests.BasicExpressionsTests.test_annotation_with_deeply_nested_outerref" ,
@@ -314,6 +322,14 @@ def django_test_expected_failures(self):
314
322
"queries.tests.Ticket22429Tests.test_ticket_22429" ,
315
323
},
316
324
"Subquery is not supported on MongoDB." : {
325
+ "aggregation.tests.AggregateAnnotationPruningTests.test_referenced_composed_subquery_requires_wrapping" ,
326
+ "aggregation.tests.AggregateAnnotationPruningTests.test_referenced_subquery_requires_wrapping" ,
327
+ "aggregation.tests.AggregateTestCase.test_aggregation_nested_subquery_outerref" ,
328
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation" ,
329
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_multivalued" ,
330
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_related_field" ,
331
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_values" ,
332
+ "aggregation.tests.AggregateTestCase.test_aggregation_subquery_annotation_values_collision" ,
317
333
"annotations.tests.NonAggregateAnnotationTestCase.test_annotation_filter_with_subquery" ,
318
334
"annotations.tests.NonAggregateAnnotationTestCase.test_annotation_subquery_outerref_transform" ,
319
335
"annotations.tests.NonAggregateAnnotationTestCase.test_empty_queryset_annotation" ,
@@ -494,6 +510,7 @@ def django_test_expected_failures(self):
494
510
"queries.tests.Queries6Tests.test_col_alias_quoted" ,
495
511
},
496
512
"Test executes raw SQL." : {
513
+ "aggregation.tests.AggregateTestCase.test_coalesced_empty_result_set" ,
497
514
"annotations.tests.NonAggregateAnnotationTestCase.test_raw_sql_with_inherited_field" ,
498
515
"delete_regress.tests.DeleteLockingTest.test_concurrent_delete" ,
499
516
"expressions.tests.BasicExpressionsTests.test_annotate_values_filter" ,
@@ -585,6 +602,7 @@ def django_test_expected_failures(self):
585
602
"model_fields.test_jsonfield.TestQuerying.test_none_key_exclude" ,
586
603
},
587
604
"Randomized ordering isn't supported by MongoDB." : {
605
+ "aggregation.tests.AggregateTestCase.test_aggregation_random_ordering" ,
588
606
"ordering.tests.OrderingTests.test_random_ordering" ,
589
607
},
590
608
"Queries without a collection aren't supported on MongoDB." : {
@@ -600,6 +618,7 @@ def django_test_expected_failures(self):
600
618
"aggregation.tests.AggregateAnnotationPruningTests.test_non_aggregate_annotation_pruned" ,
601
619
"aggregation.tests.AggregateTestCase.test_add_implementation" ,
602
620
"aggregation.tests.AggregateTestCase.test_aggregation_default_using_datetime_from_database" ,
621
+ "aggregation.tests.AggregateTestCase.test_multi_arg_aggregate" ,
603
622
# SQL custom values.
604
623
"aggregation.tests.AggregateTestCase.test_aggregation_default_using_date_from_database" ,
605
624
# No sql generate
@@ -611,7 +630,17 @@ def django_test_expected_failures(self):
611
630
"aggregation.tests.AggregateAnnotationPruningTests.test_referenced_aggregate_annotation_kept" ,
612
631
# Using a QuerySet in annotate() is not supported on MongoDB
613
632
"aggregation.tests.AggregateTestCase.test_group_by_subquery_annotation" ,
614
- }
633
+ # Query set with annotate not supported.
634
+ "aggregation.tests.AggregateTestCase.test_group_by_reference_subquery" ,
635
+ "aggregation.tests.AggregateTestCase.test_filter_in_subquery_or_aggregation" ,
636
+ # Exists is not supported in mongodb
637
+ "aggregation.tests.AggregateTestCase.test_aggregation_exists_multivalued_outeref" ,
638
+ "aggregation.tests.AggregateTestCase.test_group_by_exists_annotation" ,
639
+ "aggregation.tests.AggregateTestCase.test_exists_none_with_aggregate" ,
640
+ "aggregation.tests.AggregateTestCase.test_exists_extra_where_with_aggregate" ,
641
+ # Queryset dates not supported
642
+ "aggregation.tests.AggregateTestCase.test_dates_with_aggregation" ,
643
+ },
615
644
}
616
645
617
646
@cached_property
0 commit comments