mirror of
https://github.com/django/django.git
synced 2025-08-03 18:38:50 +00:00
Enforced uniqueness of natural keys used in tests.
This commit is contained in:
parent
678f958ef9
commit
cf21fc9bf0
4 changed files with 13 additions and 13 deletions
|
@ -25,7 +25,7 @@ class PersonManager(models.Manager):
|
|||
|
||||
|
||||
class Person(models.Model):
|
||||
name = models.CharField(max_length=100)
|
||||
name = models.CharField(max_length=100, unique=True)
|
||||
|
||||
objects = PersonManager()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue