Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(720)

Unified Diff: content/public/test/browser_test_utils.h

Issue 1993093002: Test for navigating back to navigation that posts to a cross-site 307 redirect. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed remaining CR feedback from creis@. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/session_history_browsertest.cc ('k') | content/public/test/browser_test_utils.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/browser_test_utils.h
diff --git a/content/public/test/browser_test_utils.h b/content/public/test/browser_test_utils.h
index 6b2adffa3bf69b7ba6ad4f2e961b0e8ad9277de4..a0f3dd8c9805be461f5ee3dce822a2486a4afe3a 100644
--- a/content/public/test/browser_test_utils.h
+++ b/content/public/test/browser_test_utils.h
@@ -264,6 +264,12 @@ void FetchHistogramsFromChildProcesses();
// "/cross-site/hostname/rest/of/path" to redirect the request to
// "<scheme>://hostname:<port>/rest/of/path", where <scheme> and <port>
// are the values for the instance of EmbeddedTestServer.
+//
+// By default, redirection will be done using HTTP 302 response, but in some
+// cases (e.g. to preserve HTTP method and POST body across redirects as
+// prescribed by https://tools.ietf.org/html/rfc7231#section-6.4.7) a test might
+// want to use HTTP 307 response instead. This can be accomplished by replacing
+// "/cross-site/" URL substring above with "/cross-site-307/".
void SetupCrossSiteRedirector(net::EmbeddedTestServer* embedded_test_server);
// Waits for an interstitial page to attach to given web contents.
« no previous file with comments | « content/browser/session_history_browsertest.cc ('k') | content/public/test/browser_test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698