diff options
| author | Marko Tibold | 2011-12-30 16:35:22 +0100 |
|---|---|---|
| committer | Marko Tibold | 2011-12-30 16:35:22 +0100 |
| commit | b137b5ee5606a182dab4ff68a29f805b72e81ad3 (patch) | |
| tree | ff272330f1e1c8924477768436a6d6b49444af4b /djangorestframework/tests/validators.py | |
| parent | 28f1b027aa8b452378a89118b938f24b2383dc9a (diff) | |
| parent | b8bfebc83719a7c286fee413bb44fffedac1a8d0 (diff) | |
| download | django-rest-framework-b137b5ee5606a182dab4ff68a29f805b72e81ad3.tar.bz2 | |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'djangorestframework/tests/validators.py')
| -rw-r--r-- | djangorestframework/tests/validators.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/djangorestframework/tests/validators.py b/djangorestframework/tests/validators.py index 1f696422..18c8c313 100644 --- a/djangorestframework/tests/validators.py +++ b/djangorestframework/tests/validators.py @@ -149,7 +149,7 @@ class TestFormValidation(TestCase): try: validator.validate_request(content, None) except ErrorResponse, exc: - self.assertEqual(exc.response.raw_content, {'field-errors': {'qwerty': ['This field is required.']}}) + self.assertEqual(exc.response.raw_content, {'field_errors': {'qwerty': ['This field is required.']}}) else: self.fail('ResourceException was not raised') #pragma: no cover @@ -159,7 +159,7 @@ class TestFormValidation(TestCase): try: validator.validate_request(content, None) except ErrorResponse, exc: - self.assertEqual(exc.response.raw_content, {'field-errors': {'qwerty': ['This field is required.']}}) + self.assertEqual(exc.response.raw_content, {'field_errors': {'qwerty': ['This field is required.']}}) else: self.fail('ResourceException was not raised') #pragma: no cover @@ -169,7 +169,7 @@ class TestFormValidation(TestCase): try: validator.validate_request(content, None) except ErrorResponse, exc: - self.assertEqual(exc.response.raw_content, {'field-errors': {'extra': ['This field does not exist.']}}) + self.assertEqual(exc.response.raw_content, {'field_errors': {'extra': ['This field does not exist.']}}) else: self.fail('ResourceException was not raised') #pragma: no cover @@ -179,7 +179,7 @@ class TestFormValidation(TestCase): try: validator.validate_request(content, None) except ErrorResponse, exc: - self.assertEqual(exc.response.raw_content, {'field-errors': {'qwerty': ['This field is required.'], + self.assertEqual(exc.response.raw_content, {'field_errors': {'qwerty': ['This field is required.'], 'extra': ['This field does not exist.']}}) else: self.fail('ResourceException was not raised') #pragma: no cover |
