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

Side by Side Diff: third_party/WebKit/Source/core/html/parser/HTMLPreloadScannerTest.cpp

Issue 2584423002: Loading: move core/fetch to platform/loader/fetch (Closed)
Patch Set: rebase Created 3 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/html/parser/HTMLPreloadScanner.h" 5 #include "core/html/parser/HTMLPreloadScanner.h"
6 6
7 #include "core/MediaTypeNames.h" 7 #include "core/MediaTypeNames.h"
8 #include "core/css/MediaValuesCached.h" 8 #include "core/css/MediaValuesCached.h"
9 #include "core/fetch/ClientHintsPreferences.h"
10 #include "core/frame/Settings.h" 9 #include "core/frame/Settings.h"
11 #include "core/html/CrossOriginAttribute.h" 10 #include "core/html/CrossOriginAttribute.h"
12 #include "core/html/parser/HTMLParserOptions.h" 11 #include "core/html/parser/HTMLParserOptions.h"
13 #include "core/html/parser/HTMLResourcePreloader.h" 12 #include "core/html/parser/HTMLResourcePreloader.h"
14 #include "core/html/parser/PreloadRequest.h" 13 #include "core/html/parser/PreloadRequest.h"
15 #include "core/testing/DummyPageHolder.h" 14 #include "core/testing/DummyPageHolder.h"
15 #include "platform/loader/fetch/ClientHintsPreferences.h"
16 #include "testing/gtest/include/gtest/gtest.h" 16 #include "testing/gtest/include/gtest/gtest.h"
17 #include <memory> 17 #include <memory>
18 18
19 namespace blink { 19 namespace blink {
20 20
21 struct TestCase { 21 struct TestCase {
22 const char* baseURL; 22 const char* baseURL;
23 const char* inputHTML; 23 const char* inputHTML;
24 const char* preloadedURL; // Or nullptr if no preload is expected. 24 const char* preloadedURL; // Or nullptr if no preload is expected.
25 const char* outputBaseURL; 25 const char* outputBaseURL;
(...skipping 810 matching lines...) Expand 10 before | Expand all | Expand 10 after
836 "http://example.test/", Resource::Script, 0}, 836 "http://example.test/", Resource::Script, 0},
837 {"http://example.test", "<link rel=preload href=bla as=fOnT>", "bla", 837 {"http://example.test", "<link rel=preload href=bla as=fOnT>", "bla",
838 "http://example.test/", Resource::Font, 0}, 838 "http://example.test/", Resource::Font, 0},
839 }; 839 };
840 840
841 for (const auto& testCase : testCases) 841 for (const auto& testCase : testCases)
842 test(testCase); 842 test(testCase);
843 } 843 }
844 844
845 } // namespace blink 845 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698