| 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 "net/http/http_proxy_client_socket_pool.h" | 5 #include "net/http/http_proxy_client_socket_pool.h" |
| 6 | 6 |
| 7 #include "base/callback.h" | 7 #include "base/callback.h" |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
| 10 #include "base/time.h" | 10 #include "base/time.h" |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 want_spdy_over_npn)); | 121 want_spdy_over_npn)); |
| 122 } | 122 } |
| 123 | 123 |
| 124 void AddAuthToCache() { | 124 void AddAuthToCache() { |
| 125 const string16 kFoo(ASCIIToUTF16("foo")); | 125 const string16 kFoo(ASCIIToUTF16("foo")); |
| 126 const string16 kBar(ASCIIToUTF16("bar")); | 126 const string16 kBar(ASCIIToUTF16("bar")); |
| 127 session_->http_auth_cache()->Add(GURL("http://proxy:443/"), | 127 session_->http_auth_cache()->Add(GURL("http://proxy:443/"), |
| 128 "MyRealm1", | 128 "MyRealm1", |
| 129 HttpAuth::AUTH_SCHEME_BASIC, | 129 HttpAuth::AUTH_SCHEME_BASIC, |
| 130 "Basic realm=MyRealm1", | 130 "Basic realm=MyRealm1", |
| 131 kFoo, | 131 AuthCredentials(kFoo, kBar), |
| 132 kBar, | |
| 133 "/"); | 132 "/"); |
| 134 } | 133 } |
| 135 | 134 |
| 136 HttpNetworkSession* CreateNetworkSession() { | 135 HttpNetworkSession* CreateNetworkSession() { |
| 137 HttpNetworkSession::Params params; | 136 HttpNetworkSession::Params params; |
| 138 params.host_resolver = &host_resolver_; | 137 params.host_resolver = &host_resolver_; |
| 139 params.cert_verifier = &cert_verifier_; | 138 params.cert_verifier = &cert_verifier_; |
| 140 params.proxy_service = proxy_service_.get(); | 139 params.proxy_service = proxy_service_.get(); |
| 141 params.client_socket_factory = &socket_factory_; | 140 params.client_socket_factory = &socket_factory_; |
| 142 params.ssl_config_service = ssl_config_service_; | 141 params.ssl_config_service = ssl_config_service_; |
| (...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 736 EXPECT_TRUE(session_->spdy_session_pool()->HasSession(test_hosts[2].pair)); | 735 EXPECT_TRUE(session_->spdy_session_pool()->HasSession(test_hosts[2].pair)); |
| 737 | 736 |
| 738 session_->spdy_session_pool()->CloseAllSessions(); | 737 session_->spdy_session_pool()->CloseAllSessions(); |
| 739 } | 738 } |
| 740 | 739 |
| 741 // It would be nice to also test the timeouts in SSLClientSocketPool. | 740 // It would be nice to also test the timeouts in SSLClientSocketPool. |
| 742 | 741 |
| 743 } // namespace | 742 } // namespace |
| 744 | 743 |
| 745 } // namespace net | 744 } // namespace net |
| OLD | NEW |