[1.9.x] Refs #25532 -- Removed a failing test on Django 1.9

That test is failing on Django 1.9, that issue has been fixed on master
only as it touches a part of form validation that is too important to
touch for a stable release.
This commit is contained in:
Claude Paroz 2016-04-01 15:51:16 +02:00
parent 6a8ba2eef4
commit 97ccab126c

View File

@ -260,14 +260,6 @@ class TestFormField(PostgreSQLTestCase):
form_field = model_field.formfield() form_field = model_field.formfield()
self.assertIsInstance(form_field, forms.JSONField) self.assertIsInstance(form_field, forms.JSONField)
def test_formfield_disabled(self):
class JsonForm(Form):
name = CharField()
jfield = forms.JSONField(disabled=True)
form = JsonForm({'name': 'xyz', 'jfield': '["bar"]'}, initial={'jfield': ['foo']})
self.assertIn('[&quot;foo&quot;]</textarea>', form.as_p())
def test_prepare_value(self): def test_prepare_value(self):
field = forms.JSONField() field = forms.JSONField()
self.assertEqual(field.prepare_value({'a': 'b'}), '{"a": "b"}') self.assertEqual(field.prepare_value({'a': 'b'}), '{"a": "b"}')