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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/inspector/network/resources/set-cookie.php

Issue 2563083002: [DevTools] show warning if 'Set-Cookie' header length is > 4096 symbols (Closed)
Patch Set: addressed all comments Created 4 years 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 | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector/network/warning-for-long-cookie.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/inspector/network/resources/set-cookie.php
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/network/resources/set-cookie.php b/third_party/WebKit/LayoutTests/http/tests/inspector/network/resources/set-cookie.php
index b959612bdcd1d50b1806ce987139b9b7375c4425..f4b870105ca201be87e5d0c0e11970618cf44cc1 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/network/resources/set-cookie.php
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/network/resources/set-cookie.php
@@ -3,7 +3,16 @@
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Pragma: no-cache");
header("Content-Type: text/plain");
- setcookie("TestCookie", "TestCookieValue");
-
+ header("Access-Control-Allow-Origin: http://127.0.0.1:8000");
+ $length = isset($_GET["length"]) ? (int) $_GET["length"] : 0;
+ if (!$length) {
+ setcookie("TestCookie", "TestCookieValue");
+ } else {
+ $data = "";
+ for ($i = 0; $i < $length; $i++) {
+ $data .= "a";
+ }
+ header("Set-Cookie: $data");
+ }
echo("Cookie set.");
?>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector/network/warning-for-long-cookie.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698