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

Unified Diff: third_party/WebKit/Source/platform/network/LinkHeaderTest.cpp

Issue 2424943002: Add ReferrerPolicy support to preload (Closed)
Patch Set: Fix test. Again Created 4 years, 2 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
Index: third_party/WebKit/Source/platform/network/LinkHeaderTest.cpp
diff --git a/third_party/WebKit/Source/platform/network/LinkHeaderTest.cpp b/third_party/WebKit/Source/platform/network/LinkHeaderTest.cpp
index 4c23d31f1fc476bf79adeb54a81a096a1fbac716..5f18f3aa05094c754c5819d4499b548a3f771d8d 100644
--- a/third_party/WebKit/Source/platform/network/LinkHeaderTest.cpp
+++ b/third_party/WebKit/Source/platform/network/LinkHeaderTest.cpp
@@ -26,6 +26,7 @@ struct SingleTestCase {
const char* rel;
const char* as;
const char* media;
+ const char* referrerPolicy;
} singleTestCases[] = {
{"</images/cat.jpg>; rel=prefetch", true, "/images/cat.jpg", "prefetch", "",
""},
@@ -150,6 +151,8 @@ struct SingleTestCase {
"/images/cat.jpg", "prefetch", "", "(max-width: 5000px)"},
{"</images/cat.jpg>; rel=prefetch;media=(max-width:5000px)", true,
"/images/cat.jpg", "prefetch", "", "(max-width:5000px)"},
+ {"</images/cat.jpg>; rel=preload;referrerpolicy=somevalue", true,
Mike West 2016/10/23 05:25:46 I guess this is a reasonable addition, but it need
Yoav Weiss 2016/10/23 13:27:09 I considered it as a "link-extension" defined in h
+ "/images/cat.jpg", "preload", "", "", "somevalue"},
Mike West 2016/10/23 05:25:46 I don't understand how this test works. You've add
Yoav Weiss 2016/10/23 13:27:09 my bad. Forgot to add an actual check for the valu
};
void PrintTo(const SingleTestCase& test, std::ostream* os) {

Powered by Google App Engine
This is Rietveld 408576698