Added additional quiz accessibility test.
This commit is contained in:
parent
ce79ffe566
commit
2164e73579
6
tests.py
6
tests.py
@ -52,6 +52,12 @@ class TestLogin(BaseTestCase):
|
||||
response = self.client.get('/quiz')
|
||||
self.assertRedirects(response, '/')
|
||||
|
||||
def test_quiz_accessible_with_login(self):
|
||||
self.login()
|
||||
response = self.client.get('/quiz')
|
||||
self.assert200(response)
|
||||
self.assertTemplateUsed("quiz.html")
|
||||
|
||||
def test_user_items_inaccessible_without_login(self):
|
||||
response = self.client.get('/user_items')
|
||||
self.assertRedirects(response, '/')
|
||||
|
Loading…
Reference in New Issue
Block a user