diff options
| author | David Sanders <shang.xiao.sanders@gmail.com> | 2024-08-05 08:22:29 +0200 |
|---|---|---|
| committer | Sarah Boyce <42296566+sarahboyce@users.noreply.github.com> | 2024-08-05 17:36:15 +0200 |
| commit | aed4ffe1897c51c0dfd8689c0834ca4ca0a8a03e (patch) | |
| tree | 409778e06c17bbc9f828db340b431c030e5e400b /tests/validation/models.py | |
| parent | 78654a29b851751f347d51dbfe5ba8a996c012ba (diff) | |
[5.1.x] Fixed #35638 -- Updated validate_constraints to consider db_default.
Backport of 509763c79952cde02d9f5b584af4278bdbed77b2 from main.
Diffstat (limited to 'tests/validation/models.py')
| -rw-r--r-- | tests/validation/models.py | 2 |
1 files changed, 1 insertions, 1 deletions
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() |
