Merge pull request #1768 from normanjaeckel/FixTest

Fixed test.
This commit is contained in:
Norman Jäckel 2015-12-22 20:28:15 +01:00
commit 9a6ebdb2cf

View File

@ -13,7 +13,7 @@ class TestWhoAmIView(TestCase):
self.assertEqual(response.status_code, 200)
self.assertEqual(
json.loads(response.content.decode('utf-8')),
json.loads(response.content.decode()),
{'user_id': None, 'guest_enabled': False})
def test_get_authenticated_user(self):
@ -23,7 +23,7 @@ class TestWhoAmIView(TestCase):
self.assertEqual(response.status_code, 200)
self.assertEqual(
json.loads(response.content.decode('utf-8')),
json.loads(response.content.decode()),
{'user_id': 1, 'guest_enabled': False})
def test_post(self):
@ -78,7 +78,7 @@ class TestUserLoginView(TestCase):
self.assertEqual(response.status_code, 200)
self.assertEqual(
json.loads(response.content.decode('utf-8')),
json.loads(response.content.decode()),
{'user_id': 1})
def test_post_incorrect_data(self):