OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 scoped_ptr<net::ProxyConfigService> proxy_config_service( | 60 scoped_ptr<net::ProxyConfigService> proxy_config_service( |
61 new net::ProxyConfigServiceFixed(net::ProxyConfig())); | 61 new net::ProxyConfigServiceFixed(net::ProxyConfig())); |
62 #else | 62 #else |
63 // Use the system proxy settings. | 63 // Use the system proxy settings. |
64 scoped_ptr<net::ProxyConfigService> proxy_config_service( | 64 scoped_ptr<net::ProxyConfigService> proxy_config_service( |
65 net::ProxyService::CreateSystemProxyConfigService( | 65 net::ProxyService::CreateSystemProxyConfigService( |
66 MessageLoop::current(), NULL)); | 66 MessageLoop::current(), NULL)); |
67 #endif | 67 #endif |
68 storage_.set_host_resolver( | 68 storage_.set_host_resolver( |
69 net::CreateSystemHostResolver(net::HostResolver::kDefaultParallelism, | 69 net::CreateSystemHostResolver(net::HostResolver::kDefaultParallelism, |
| 70 net::HostResolver::kDefaultRetryAttempts, |
70 NULL)); | 71 NULL)); |
71 storage_.set_cert_verifier(new net::CertVerifier); | 72 storage_.set_cert_verifier(new net::CertVerifier); |
72 storage_.set_proxy_service(net::ProxyService::CreateUsingSystemProxyResolver( | 73 storage_.set_proxy_service(net::ProxyService::CreateUsingSystemProxyResolver( |
73 proxy_config_service.release(), 0, NULL)); | 74 proxy_config_service.release(), 0, NULL)); |
74 storage_.set_ssl_config_service( | 75 storage_.set_ssl_config_service( |
75 new net::SSLConfigServiceDefaults); | 76 new net::SSLConfigServiceDefaults); |
76 | 77 |
77 storage_.set_http_auth_handler_factory( | 78 storage_.set_http_auth_handler_factory( |
78 net::HttpAuthHandlerFactory::CreateDefault(host_resolver())); | 79 net::HttpAuthHandlerFactory::CreateDefault(host_resolver())); |
79 | 80 |
(...skipping 17 matching lines...) Expand all Loading... |
97 WebKit::webKitClient()->fileSystem())->file_system_context(); | 98 WebKit::webKitClient()->fileSystem())->file_system_context(); |
98 } | 99 } |
99 | 100 |
100 TestShellRequestContext::~TestShellRequestContext() { | 101 TestShellRequestContext::~TestShellRequestContext() { |
101 } | 102 } |
102 | 103 |
103 const std::string& TestShellRequestContext::GetUserAgent( | 104 const std::string& TestShellRequestContext::GetUserAgent( |
104 const GURL& url) const { | 105 const GURL& url) const { |
105 return webkit_glue::GetUserAgent(url); | 106 return webkit_glue::GetUserAgent(url); |
106 } | 107 } |
OLD | NEW |