summaryrefslogtreecommitdiff
path: root/tests/test_client
diff options
context:
space:
mode:
authorMarc Gibbons <1726961+marcgibbons@users.noreply.github.com>2026-03-13 13:46:49 -0400
committerGitHub <noreply@github.com>2026-03-13 13:46:49 -0400
commit6c95af5c9d294a20d09f080d7c144e3b7362d65f (patch)
treebb3a239ca951c9657223725b31e6798362f1fbb4 /tests/test_client
parente0fd41c24e440956f7863524f0950ad9110e8ae8 (diff)
Fixed #36966 -- Fixed ValueError when `query_params` and `follow` are used on test client.
Diffstat (limited to 'tests/test_client')
-rw-r--r--tests/test_client/tests.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_client/tests.py b/tests/test_client/tests.py
index 211b5d9e6f..8e62c717eb 100644
--- a/tests/test_client/tests.py
+++ b/tests/test_client/tests.py
@@ -1053,6 +1053,13 @@ class ClientTest(TestCase):
query_params={"q": "terms"},
)
+ def test_follow_redirect_with_query_params(self):
+ response = self.client.get(
+ "/redirect_view/", query_params={"next": "x"}, follow=True
+ )
+ self.assertEqual(response.status_code, 200)
+ self.assertEqual(response.wsgi_request.get_full_path(), "/get_view/?next=x")
+
@override_settings(
MIDDLEWARE=["django.middleware.csrf.CsrfViewMiddleware"],