Skip to content

Commit 496333f

Browse files
committed
Clean up.
1 parent 32ed358 commit 496333f

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

django_mongodb/features.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ class DatabaseFeatures(BaseDatabaseFeatures):
4242
# tuple index out of range in process_rhs()
4343
"lookup.tests.LookupTests.test_exact_sliced_queryset_limit_one",
4444
"lookup.tests.LookupTests.test_exact_sliced_queryset_limit_one_offset",
45+
# Regex lookup doesn't work on json fields.
46+
"model_fields.test_jsonfield.TestQuerying.test_icontains"
4547
# MongoDB gives the wrong result of log(number, base) when base is a
4648
# fractional Decimal: https://jira.mongodb.org/browse/SERVER-91223
4749
"db_functions.math.test_log.LogTests.test_decimal",
@@ -57,6 +59,10 @@ class DatabaseFeatures(BaseDatabaseFeatures):
5759
"model_fields.test_jsonfield.TestQuerying.test_usage_in_subquery",
5860
# Length of null considered zero rather than null.
5961
"db_functions.text.test_length.LengthTests.test_basic",
62+
# Django-mongo does not differentiate well between joins and key transforms.
63+
"model_fields.test_jsonfield.TestQuerying.test_order_grouping_custom_decoder",
64+
"model_fields.test_jsonfield.TestQuerying.test_ordering_by_transform",
65+
"model_fields.test_jsonfield.TestQuerying.test_ordering_grouping_by_key_transform",
6066
}
6167
# $bitAnd, #bitOr, and $bitXor are new in MongoDB 6.3.
6268
_django_test_expected_failures_bitwise = {
@@ -223,6 +229,8 @@ def django_test_expected_failures(self):
223229
"db_functions.datetime.test_extract_trunc.DateFunctionTests.test_trunc_subquery_with_parameters",
224230
"expressions_case.tests.CaseExpressionTests.test_in_subquery",
225231
"lookup.tests.LookupQueryingTests.test_filter_subquery_lhs",
232+
"model_fields.test_jsonfield.TestQuerying.test_nested_key_transform_on_subquery",
233+
"model_fields.test_jsonfield.TestQuerying.test_obj_subquery_lookup",
226234
# Invalid $project :: caused by :: Unknown expression $count,
227235
"annotations.tests.NonAggregateAnnotationTestCase.test_combined_expression_annotation_with_aggregation",
228236
"annotations.tests.NonAggregateAnnotationTestCase.test_combined_f_expression_annotation_with_aggregation",
@@ -244,7 +252,7 @@ def django_test_expected_failures(self):
244252
"expressions_case.tests.CaseExpressionTests.test_order_by_conditional_implicit",
245253
# annotate().filter().count() gives incorrect results.
246254
"db_functions.datetime.test_extract_trunc.DateFunctionTests.test_extract_year_exact_lookup",
247-
"model_fields.test_jsonfield.TestQuerying.test_nested_key_transform_on_subquery",
255+
# FieldDoesNotExist with ordering.
248256
"model_fields.test_jsonfield.TestQuerying.test_ordering_grouping_by_count",
249257
"model_fields.test_jsonfield.TestQuerying.test_obj_subquery_lookup",
250258
},
@@ -330,6 +338,7 @@ def django_test_expected_failures(self):
330338
"lookup.tests.LookupTests.test_lookup_rhs",
331339
"lookup.tests.LookupTests.test_isnull_non_boolean_value",
332340
"model_fields.test_manytomanyfield.ManyToManyFieldDBTests.test_value_from_object_instance_with_pk",
341+
"model_fields.test_jsonfield.TestQuerying.test_join_key_transform_annotation_expression",
333342
"model_fields.test_uuid.TestAsPrimaryKey.test_two_level_foreign_keys",
334343
"timezones.tests.LegacyDatabaseTests.test_query_annotation",
335344
"timezones.tests.NewDatabaseTests.test_query_annotation",
@@ -341,10 +350,6 @@ def django_test_expected_failures(self):
341350
"update.tests.SimpleTest.test_empty_update_with_inheritance",
342351
"update.tests.SimpleTest.test_foreign_key_update_with_id",
343352
"update.tests.SimpleTest.test_nonempty_update_with_inheritance",
344-
"model_fields.test_jsonfield.TestQuerying.test_join_key_transform_annotation_expression",
345-
"model_fields.test_jsonfield.TestQuerying.test_order_grouping_custom_decoder",
346-
"model_fields.test_jsonfield.TestQuerying.test_ordering_by_transform",
347-
"model_fields.test_jsonfield.TestQuerying.test_ordering_grouping_by_key_transform",
348353
},
349354
"Test inspects query for SQL": {
350355
"lookup.tests.LookupTests.test_in_ignore_none",

0 commit comments

Comments
 (0)