diff options
| author | Tim Graham <timograham@gmail.com> | 2025-11-20 20:18:09 -0500 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2025-11-23 11:53:24 +0100 |
| commit | 57c50d8c1996733cef45204ea069a2c01b2860cc (patch) | |
| tree | ef25923bfc179acb84d09c934fe50ff565a6a929 /tests/admin_utils/tests.py | |
| parent | ec60df6d1ea8939a316d9b180faa0b4ef2e83606 (diff) | |
Refs #21961 -- Added DatabaseFeatures.supports_on_delete_db_(cascade/null) feature flags.
Needed on MongoDB.
Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
Diffstat (limited to 'tests/admin_utils/tests.py')
| -rw-r--r-- | tests/admin_utils/tests.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/admin_utils/tests.py b/tests/admin_utils/tests.py index ce32535c52..81c6f495f8 100644 --- a/tests/admin_utils/tests.py +++ b/tests/admin_utils/tests.py @@ -21,7 +21,7 @@ from django.contrib.auth.models import User from django.contrib.auth.templatetags.auth import render_password_as_hash from django.core.validators import EMPTY_VALUES from django.db import DEFAULT_DB_ALIAS, models -from django.test import SimpleTestCase, TestCase, override_settings +from django.test import SimpleTestCase, TestCase, override_settings, skipUnlessDBFeature from django.test.utils import isolate_apps from django.utils.formats import localize from django.utils.safestring import mark_safe @@ -115,6 +115,7 @@ class NestedObjectsTests(TestCase): n.collect([Vehicle.objects.first()]) +@skipUnlessDBFeature("supports_on_delete_db_cascade") class DBNestedObjectsTests(NestedObjectsTests): """ Exercise NestedObjectsTests but with a model that makes use of DB_CASCADE |
