diff --git a/djangoproject/tests.py b/djangoproject/tests.py index 759f0a3292..9337e7bc6e 100644 --- a/djangoproject/tests.py +++ b/djangoproject/tests.py @@ -104,7 +104,8 @@ def test_docs_host_excluded(self): "We get no Content-Language or Vary headers when docs host is excluded" with self.settings(LOCALE_MIDDLEWARE_EXCLUDED_HOSTS=[self.docs_host]): resp = self.client.get("/", headers={"host": self.docs_host}) - self.assertEqual(resp.status_code, HTTPStatus.FOUND) + + self.assertEqual(resp.status_code, HTTPStatus.OK) self.assertNotIn("Content-Language", resp) self.assertNotIn("Vary", resp) @@ -128,7 +129,8 @@ def test_docs_host_forwarded_excluded(self): LOCALE_MIDDLEWARE_EXCLUDED_HOSTS=[self.docs_host], USE_X_FORWARDED_HOST=True ): resp = self.client.get("/", headers={"x-forwarded-host": self.docs_host}) - self.assertEqual(resp.status_code, HTTPStatus.FOUND) + + self.assertEqual(resp.status_code, HTTPStatus.OK) self.assertNotIn("Content-Language", resp) self.assertNotIn("Vary", resp) @@ -136,7 +138,8 @@ def test_docs_host_not_excluded(self): "We still get Content-Language when docs host is not excluded" with self.settings(LOCALE_MIDDLEWARE_EXCLUDED_HOSTS=[]): resp = self.client.get("/", headers={"host": self.docs_host}) - self.assertEqual(resp.status_code, HTTPStatus.FOUND) + + self.assertEqual(resp.status_code, HTTPStatus.OK) self.assertIn("Content-Language", resp) self.assertIn("Vary", resp) diff --git a/requirements/common.txt b/requirements/common.txt index 7488cd775a..53c1eb194b 100644 --- a/requirements/common.txt +++ b/requirements/common.txt @@ -1,7 +1,7 @@ Babel==2.17.0 django-contact-form==5.2.0 django-countries==7.6.1 -django-hosts==5.1 +django-hosts==7.0.0 django-money==3.5.4 django-push @ git+https://github.com/brutasse/django-push.git@22fda99641cfbd2f3075a723d92652a8e38220a5 django-read-only==1.21.0