From 687fedfffa402e049c59668f2a6248ad2ba17910 Mon Sep 17 00:00:00 2001 From: Christopher Baklid Date: Sun, 20 May 2018 21:11:18 +0200 Subject: Tests directory (#73) moves all tests into a testing directory and splits the tests into separate files --- tests/test_staff.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 tests/test_staff.py (limited to 'tests/test_staff.py') diff --git a/tests/test_staff.py b/tests/test_staff.py new file mode 100644 index 00000000..68c182b5 --- /dev/null +++ b/tests/test_staff.py @@ -0,0 +1,16 @@ +import os +import json +from tests import SiteTest, app + +class StaffEndpoints(SiteTest): + """ Test cases for staff subdomain """ + + def test_staff_view(self): + """ Check staff view redirects """ + response = self.client.get('/', app.config['STAFF_SUBDOMAIN']) + self.assertEqual(response.status_code, 302) + + def test_jams_infractions(self): + """ Check staff jams infractions view redirects """ + response = self.client.get('/jams/infractions', app.config['STAFF_SUBDOMAIN']) + self.assertEqual(response.status_code, 302) -- cgit v1.2.3