diff options
Diffstat (limited to 'tests/regressiontests/datatypes/models.py')
| -rw-r--r-- | tests/regressiontests/datatypes/models.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/regressiontests/datatypes/models.py b/tests/regressiontests/datatypes/models.py index d220d0893a..8e6027dd0f 100644 --- a/tests/regressiontests/datatypes/models.py +++ b/tests/regressiontests/datatypes/models.py @@ -4,8 +4,10 @@ types, which in the past were problematic for some database backends. """ from django.db import models +from django.utils.encoding import python_2_unicode_compatible +@python_2_unicode_compatible class Donut(models.Model): name = models.CharField(max_length=100) is_frosted = models.BooleanField(default=False) @@ -18,7 +20,7 @@ class Donut(models.Model): class Meta: ordering = ('consumed_at',) - def __unicode__(self): + def __str__(self): return self.name class RumBaba(models.Model): |
