summaryrefslogtreecommitdiff
path: root/tests/admin_utils/models.py
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2025-11-20 20:18:09 -0500
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2025-11-23 11:53:24 +0100
commit57c50d8c1996733cef45204ea069a2c01b2860cc (patch)
treeef25923bfc179acb84d09c934fe50ff565a6a929 /tests/admin_utils/models.py
parentec60df6d1ea8939a316d9b180faa0b4ef2e83606 (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/models.py')
-rw-r--r--tests/admin_utils/models.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/admin_utils/models.py b/tests/admin_utils/models.py
index e5d2b67887..55810f0b50 100644
--- a/tests/admin_utils/models.py
+++ b/tests/admin_utils/models.py
@@ -55,6 +55,9 @@ class DBCascade(models.Model):
def __str__(self):
return str(self.num)
+ class Meta:
+ required_db_features = {"supports_on_delete_db_cascade"}
+
class Event(models.Model):
date = models.DateTimeField(auto_now_add=True)