From aed4ffe1897c51c0dfd8689c0834ca4ca0a8a03e Mon Sep 17 00:00:00 2001 From: David Sanders Date: Mon, 5 Aug 2024 08:22:29 +0200 Subject: [5.1.x] Fixed #35638 -- Updated validate_constraints to consider db_default. Backport of 509763c79952cde02d9f5b584af4278bdbed77b2 from main. --- tests/validation/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/validation/models.py') diff --git a/tests/validation/models.py b/tests/validation/models.py index f6b1e0cd62..beec524758 100644 --- a/tests/validation/models.py +++ b/tests/validation/models.py @@ -48,7 +48,7 @@ class ModelToValidate(models.Model): class UniqueFieldsModel(models.Model): unique_charfield = models.CharField(max_length=100, unique=True) - unique_integerfield = models.IntegerField(unique=True) + unique_integerfield = models.IntegerField(unique=True, db_default=42) non_unique_field = models.IntegerField() -- cgit v1.3