1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

Removed unused __str__() methods in tests models.

Follow up to 6461583b6c.
This commit is contained in:
Mariusz Felisiak
2020-04-30 09:13:23 +02:00
committed by GitHub
parent bb13711451
commit 555e3a848e
35 changed files with 2 additions and 400 deletions

View File

@@ -20,9 +20,6 @@ class Article(models.Model):
class Meta:
ordering = ['author__name']
def __str__(self):
return 'Article titled: %s' % self.title
# These following 4 models represent a far more complex ordering case.
class SystemInfo(models.Model):
@@ -38,9 +35,6 @@ class Post(models.Model):
forum = models.ForeignKey(Forum, models.SET_NULL, null=True)
title = models.CharField(max_length=32)
def __str__(self):
return self.title
class Comment(models.Model):
post = models.ForeignKey(Post, models.SET_NULL, null=True)
@@ -48,6 +42,3 @@ class Comment(models.Model):
class Meta:
ordering = ['post__forum__system_info__system_name', 'comment_text']
def __str__(self):
return self.comment_text