Fixed #23395 -- Limited line lengths to 119 characters.

This commit is contained in:
Dražen Odobašić 2015-09-11 19:33:12 -04:00 committed by Tim Graham
parent 84b0a8d2aa
commit b1e33ceced
130 changed files with 5259 additions and 1501 deletions

View file

@ -37,7 +37,8 @@ class ValidationTestModel(models.Model):
is_active = models.BooleanField(default=False)
pub_date = models.DateTimeField()
band = models.ForeignKey(Band, models.CASCADE)
no = models.IntegerField(verbose_name="Number", blank=True, null=True) # This field is intentionally 2 characters long. See #16080.
# This field is intentionally 2 characters long (#16080).
no = models.IntegerField(verbose_name="Number", blank=True, null=True)
def decade_published_in(self):
return self.pub_date.strftime('%Y')[:3] + "0's"

View file

@ -1029,9 +1029,11 @@ class ListDisplayLinksCheckTests(CheckTestCase):
list_display_links = ('non_existent_field',)
self.assertIsInvalid(
ValidationTestModelAdmin, ValidationTestModel,
"The value of 'list_display_links[0]' refers to 'non_existent_field', which is not defined in 'list_display'.",
'admin.E111')
ValidationTestModelAdmin, ValidationTestModel, (
"The value of 'list_display_links[0]' refers to "
"'non_existent_field', which is not defined in 'list_display'."
), 'admin.E111'
)
def test_missing_in_list_display(self):
class ValidationTestModelAdmin(ModelAdmin):
@ -1244,9 +1246,10 @@ class OrderingCheckTests(CheckTestCase):
self.assertIsInvalid(
ValidationTestModelAdmin,
ValidationTestModel,
"The value of 'ordering[0]' refers to 'non_existent_field', which is not an attribute of 'modeladmin.ValidationTestModel'.",
'admin.E033',
ValidationTestModel, (
"The value of 'ordering[0]' refers to 'non_existent_field', "
"which is not an attribute of 'modeladmin.ValidationTestModel'."
), 'admin.E033'
)
def test_random_marker_not_alone(self):