From 9026f8651cef4b21a73165ab1b21a951e2d63aca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Mas=C5=82owski?= Date: Sun, 5 Oct 2014 13:17:26 +0200 Subject: Fix public tests and download URL. --- public/tests.py | 13 ++++++++++--- public/views.py | 2 +- 2 files changed, 11 insertions(+), 4 deletions(-) (limited to 'public') diff --git a/public/tests.py b/public/tests.py index 565d57ec..49bbd2bb 100644 --- a/public/tests.py +++ b/public/tests.py @@ -17,10 +17,16 @@ class PublicTest(TestCase): def test_svn(self): response = self.client.get('/svn/') - self.assertEqual(response.status_code, 200) + # Parabola has no SVN. + self.assertEqual(response.status_code, 404) def test_developers(self): response = self.client.get('/developers/') + self.assertEqual(response.status_code, 301) + self.assertTrue(response['Location'].endswith('/hackers/')) + + def test_hackers(self): + response = self.client.get('/hackers/') self.assertEqual(response.status_code, 200) def test_fellows(self): @@ -33,5 +39,6 @@ class PublicTest(TestCase): def test_download(self): response = self.client.get('/download/') - self.assertEqual(response.status_code, 200) - + self.assertEqual(response.status_code, 302) + self.assertEqual(response['Location'], + 'https://wiki.parabola.nu/Get_Parabola') diff --git a/public/views.py b/public/views.py index f04f357b..19a62fca 100644 --- a/public/views.py +++ b/public/views.py @@ -83,7 +83,7 @@ def _mirror_urls(): @cache_control(max_age=300) def download(request): - return HttpResponseRedirect('https://wiki.parabolagnulinux.org/get') + return HttpResponseRedirect('https://wiki.parabola.nu/Get_Parabola') @cache_control(max_age=300) def feeds(request): -- cgit v1.2.3