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

Side by Side Diff: content/shell/browser/layout_test/layout_test_url_request_context_getter.cc

Issue 651883002: Content Shell: Introduce LayoutTestURLRequestContextGetter. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@LayoutTestBrowserMainParts
Patch Set: Fix. Created 6 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "content/shell/browser/layout_test/layout_test_url_request_context_gett er.h"
6
7 #include "base/command_line.h"
8 #include "base/logging.h"
9 #include "content/public/browser/browser_thread.h"
10 #include "content/shell/browser/shell_network_delegate.h"
11 #include "net/proxy/proxy_service.h"
12
13 namespace content {
14
15 LayoutTestURLRequestContextGetter::LayoutTestURLRequestContextGetter(
16 bool ignore_certificate_errors,
17 const base::FilePath& base_path,
18 base::MessageLoop* io_loop,
19 base::MessageLoop* file_loop,
20 ProtocolHandlerMap* protocol_handlers,
21 URLRequestInterceptorScopedVector request_interceptors,
22 net::NetLog* net_log)
23 : ShellURLRequestContextGetter(ignore_certificate_errors,
24 base_path,
25 io_loop,
26 file_loop,
27 protocol_handlers,
28 request_interceptors.Pass(),
29 net_log) {
30 // Must first be created on the UI thread.
31 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
32 }
33
34 LayoutTestURLRequestContextGetter::~LayoutTestURLRequestContextGetter() {
35 }
36
37 net::NetworkDelegate*
38 LayoutTestURLRequestContextGetter::CreateNetworkDelegate() {
39 ShellNetworkDelegate::SetAcceptAllCookies(false);
40 return new ShellNetworkDelegate;
41 }
42
43 net::ProxyConfigService*
44 LayoutTestURLRequestContextGetter::GetProxyConfigService() {
45 return nullptr;
46 }
47
48 net::ProxyService* LayoutTestURLRequestContextGetter::GetProxyService() {
49 return net::ProxyService::CreateDirect();
50 }
51
52 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698