Fixed a small collection of flake8 violations that had snuck in

This commit is contained in:
Alex Gaynor 2014-03-20 10:30:41 -07:00
parent 3ecc25bd58
commit 0cf158cf9a
1 changed files with 4 additions and 3 deletions

View File

@ -1297,7 +1297,7 @@ class ModelFormBasicTests(TestCase):
self.assertEqual(Category.objects.get(id=cat.id).name, 'Third')
def test_runtime_choicefield_populated(self):
self.maxDiff=None
self.maxDiff = None
# Here, we demonstrate that choices for a ForeignKey ChoiceField are determined
# at runtime, based on the data in the database when the form is displayed, not
# the data in the database when the form is instantiated.
@ -1395,10 +1395,10 @@ class ModelChoiceFieldTests(TestCase):
self.assertEqual(f.clean(str(self.c1.id)).name, "Entertainment")
with self.assertRaises(ValidationError):
f.clean('100')
# len can be called on choices
self.assertEqual(len(f.choices), 2)
# queryset can be changed after the field is created.
f.queryset = Category.objects.exclude(name='Third')
self.assertEqual(list(f.choices), [
@ -1988,6 +1988,7 @@ class FileAndImageFieldTests(TestCase):
self.assertEqual(instance.image.name, 'foo/test4.png')
instance.delete()
class ModelOtherFieldTests(TestCase):
def test_big_integer_field(self):
bif = BigIntForm({'biggie': '-9223372036854775808'})