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

Side by Side Diff: third_party/WebKit/Source/core/fetch/MockFetchContext.h

Issue 2510603002: Loading: split tests depend on FontResource to loader/resource/FontResourceTest (Closed)
Patch Set: rebase for cache aware loading Created 4 years, 1 month 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef MockFetchContext_h 5 #ifndef MockFetchContext_h
6 #define MockFetchContext_h 6 #define MockFetchContext_h
7 7
8 #include "core/fetch/FetchContext.h" 8 #include "core/fetch/FetchContext.h"
9 #include "core/fetch/FetchRequest.h" 9 #include "core/fetch/FetchRequest.h"
10 #include "core/fetch/ResourceLoaderOptions.h"
11 #include "platform/network/ResourceTimingInfo.h" 10 #include "platform/network/ResourceTimingInfo.h"
12 #include "platform/scheduler/test/fake_web_task_runner.h" 11 #include "platform/scheduler/test/fake_web_task_runner.h"
13 #include "wtf/PtrUtil.h" 12 #include "wtf/PtrUtil.h"
14 13
15 #include <memory> 14 #include <memory>
16 15
17 namespace blink { 16 namespace blink {
18 17
19 class KURL; 18 class KURL;
20 class ResourceRequest; 19 class ResourceRequest;
21 class WebTaskRunner; 20 class WebTaskRunner;
21 struct ResourceLoaderOptions;
22 22
23 // Mocked FetchContext for testing. 23 // Mocked FetchContext for testing.
24 // TODO(toyoshim): Use this class by other unit tests that currently have own 24 // TODO(toyoshim): Use this class by other unit tests that currently have own
25 // mocked FetchContext respectively. 25 // mocked FetchContext respectively.
26 class MockFetchContext : public FetchContext { 26 class MockFetchContext : public FetchContext {
27 public: 27 public:
28 enum LoadPolicy { 28 enum LoadPolicy {
29 kShouldLoadNewResource, 29 kShouldLoadNewResource,
30 kShouldNotLoadNewResource, 30 kShouldNotLoadNewResource,
31 }; 31 };
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 enum LoadPolicy m_loadPolicy; 73 enum LoadPolicy m_loadPolicy;
74 CachePolicy m_policy; 74 CachePolicy m_policy;
75 std::unique_ptr<scheduler::FakeWebTaskRunner> m_runner; 75 std::unique_ptr<scheduler::FakeWebTaskRunner> m_runner;
76 bool m_complete; 76 bool m_complete;
77 long long m_transferSize; 77 long long m_transferSize;
78 }; 78 };
79 79
80 } // namespace blink 80 } // namespace blink
81 81
82 #endif 82 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/fetch/FontResource.h ('k') | third_party/WebKit/Source/core/fetch/ResourceFetcherTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698