aboutsummaryrefslogtreecommitdiffstats
path: root/djangorestframework/tests/content.py
diff options
context:
space:
mode:
authorTom Christie2012-01-21 17:55:25 +0000
committerTom Christie2012-01-21 17:55:25 +0000
commitc94423151b5e135c5d977d63a7092cc4a8ab5de4 (patch)
tree896f6a8e9ae8309d9ec3400573967134077e63f8 /djangorestframework/tests/content.py
parenta99a449c8844e6f55f9a1ecb341701f2719117df (diff)
downloaddjango-rest-framework-c94423151b5e135c5d977d63a7092cc4a8ab5de4.tar.bz2
Drop short status codes.
Diffstat (limited to 'djangorestframework/tests/content.py')
-rw-r--r--djangorestframework/tests/content.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/djangorestframework/tests/content.py b/djangorestframework/tests/content.py
index 47dfce80..6bae8feb 100644
--- a/djangorestframework/tests/content.py
+++ b/djangorestframework/tests/content.py
@@ -17,7 +17,7 @@ class MockView(View):
authentication = (UserLoggedInAuthentication,)
def post(self, request):
if request.POST.get('example') is not None:
- return Response(status.OK)
+ return Response(status.HTTP_200_OK)
return Response(status.INTERNAL_SERVER_ERROR)
@@ -215,10 +215,10 @@ class TestContentParsingWithAuthentication(TestCase):
content = {'example': 'example'}
response = self.client.post('/', content)
- self.assertEqual(status.OK, response.status_code, "POST data is malformed")
+ self.assertEqual(status.HTTP_200_OK, response.status_code, "POST data is malformed")
response = self.csrf_client.post('/', content)
- self.assertEqual(status.OK, response.status_code, "POST data is malformed")
+ self.assertEqual(status.HTTP_200_OK, response.status_code, "POST data is malformed")
# def test_user_logged_in_authentication_has_post_when_logged_in(self):
# """Ensures request.POST exists after UserLoggedInAuthentication when user does log in"""