OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "webkit/tools/test_shell/test_shell_request_context.h" | 5 #include "webkit/tools/test_shell/test_shell_request_context.h" |
6 | 6 |
7 #include "build/build_config.h" | 7 #include "build/build_config.h" |
8 | 8 |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 #else | 70 #else |
71 // Use the system proxy settings. | 71 // Use the system proxy settings. |
72 scoped_ptr<net::ProxyConfigService> proxy_config_service( | 72 scoped_ptr<net::ProxyConfigService> proxy_config_service( |
73 net::ProxyService::CreateSystemProxyConfigService( | 73 net::ProxyService::CreateSystemProxyConfigService( |
74 MessageLoop::current(), NULL)); | 74 MessageLoop::current(), NULL)); |
75 #endif | 75 #endif |
76 storage_.set_host_resolver( | 76 storage_.set_host_resolver( |
77 net::CreateSystemHostResolver(net::HostResolver::kDefaultParallelism, | 77 net::CreateSystemHostResolver(net::HostResolver::kDefaultParallelism, |
78 net::HostResolver::kDefaultRetryAttempts, | 78 net::HostResolver::kDefaultRetryAttempts, |
79 NULL)); | 79 NULL)); |
80 storage_.set_cert_verifier(new net::CertVerifier); | 80 storage_.set_cert_verifier(net::CertVerifier::CreateDefault()); |
81 storage_.set_proxy_service(net::ProxyService::CreateUsingSystemProxyResolver( | 81 storage_.set_proxy_service(net::ProxyService::CreateUsingSystemProxyResolver( |
82 proxy_config_service.release(), 0, NULL)); | 82 proxy_config_service.release(), 0, NULL)); |
83 storage_.set_ssl_config_service( | 83 storage_.set_ssl_config_service( |
84 new net::SSLConfigServiceDefaults); | 84 new net::SSLConfigServiceDefaults); |
85 | 85 |
86 storage_.set_http_auth_handler_factory( | 86 storage_.set_http_auth_handler_factory( |
87 net::HttpAuthHandlerFactory::CreateDefault(host_resolver())); | 87 net::HttpAuthHandlerFactory::CreateDefault(host_resolver())); |
88 storage_.set_http_server_properties( | 88 storage_.set_http_server_properties( |
89 new net::HttpServerPropertiesImpl); | 89 new net::HttpServerPropertiesImpl); |
90 | 90 |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 storage_.set_job_factory(job_factory); | 130 storage_.set_job_factory(job_factory); |
131 } | 131 } |
132 | 132 |
133 TestShellRequestContext::~TestShellRequestContext() { | 133 TestShellRequestContext::~TestShellRequestContext() { |
134 } | 134 } |
135 | 135 |
136 const std::string& TestShellRequestContext::GetUserAgent( | 136 const std::string& TestShellRequestContext::GetUserAgent( |
137 const GURL& url) const { | 137 const GURL& url) const { |
138 return webkit_glue::GetUserAgent(url); | 138 return webkit_glue::GetUserAgent(url); |
139 } | 139 } |
OLD | NEW |