From 85ba44c23172e086de68787b2c3d00007c016705 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20P=C3=A9pin?= Date: Tue, 4 Apr 2017 16:32:46 +0100 Subject: [PATCH] Tests the redirection using the appropriate method --- kfet/tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kfet/tests.py b/kfet/tests.py index ffca7a44..991b2545 100644 --- a/kfet/tests.py +++ b/kfet/tests.py @@ -66,5 +66,5 @@ class TestStats(TestCase): for url in articles_urls: resp = client.get(url) self.assertEqual(200, resp.status_code) - resp2 = client2.get(url) - self.assertEqual(302, resp2.status_code) + resp2 = client2.get(url, follow=True) + self.assertRedirects(resp2, "/")