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

Side by Side Diff: net/socket/ssl_client_socket_pool_unittest.cc

Issue 517693002: Add embedder-specific headers to HTTP CONNECT tunnel request (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added tests Created 6 years, 3 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
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 "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/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 &transport_socket_pool_), 112 &transport_socket_pool_),
113 http_proxy_socket_params_( 113 http_proxy_socket_params_(
114 new HttpProxySocketParams(proxy_transport_socket_params_, 114 new HttpProxySocketParams(proxy_transport_socket_params_,
115 NULL, 115 NULL,
116 GURL("http://host"), 116 GURL("http://host"),
117 std::string(), 117 std::string(),
118 HostPortPair("host", 80), 118 HostPortPair("host", 80),
119 session_->http_auth_cache(), 119 session_->http_auth_cache(),
120 session_->http_auth_handler_factory(), 120 session_->http_auth_handler_factory(),
121 session_->spdy_session_pool(), 121 session_->spdy_session_pool(),
122 true)), 122 true,
123 base::Callback<void(
124 const HostPortPair&,
125 HttpRequestHeaders*)>())),
123 http_proxy_histograms_("MockHttpProxy"), 126 http_proxy_histograms_("MockHttpProxy"),
124 http_proxy_socket_pool_(kMaxSockets, 127 http_proxy_socket_pool_(kMaxSockets,
125 kMaxSocketsPerGroup, 128 kMaxSocketsPerGroup,
126 &http_proxy_histograms_, 129 &http_proxy_histograms_,
127 &host_resolver_, 130 &host_resolver_,
128 &transport_socket_pool_, 131 &transport_socket_pool_,
129 NULL, 132 NULL,
133 base::Callback<void(const HostPortPair&,
134 HttpRequestHeaders*)>(),
130 NULL), 135 NULL),
131 enable_ssl_connect_job_waiting_(false) { 136 enable_ssl_connect_job_waiting_(false) {
132 scoped_refptr<SSLConfigService> ssl_config_service( 137 scoped_refptr<SSLConfigService> ssl_config_service(
133 new SSLConfigServiceDefaults); 138 new SSLConfigServiceDefaults);
134 ssl_config_service->GetSSLConfig(&ssl_config_); 139 ssl_config_service->GetSSLConfig(&ssl_config_);
135 } 140 }
136 141
137 void CreatePool(bool transport_pool, bool http_proxy_pool, bool socks_pool) { 142 void CreatePool(bool transport_pool, bool http_proxy_pool, bool socks_pool) {
138 ssl_histograms_.reset(new ClientSocketPoolHistograms("SSLUnitTest")); 143 ssl_histograms_.reset(new ClientSocketPoolHistograms("SSLUnitTest"));
139 pool_.reset(new SSLClientSocketPool( 144 pool_.reset(new SSLClientSocketPool(
(...skipping 1250 matching lines...) Expand 10 before | Expand all | Expand 10 after
1390 ssl.channel_id_sent = true; 1395 ssl.channel_id_sent = true;
1391 ssl.SetNextProto(GetParam()); 1396 ssl.SetNextProto(GetParam());
1392 TestIPPoolingDisabled(&ssl); 1397 TestIPPoolingDisabled(&ssl);
1393 } 1398 }
1394 1399
1395 // It would be nice to also test the timeouts in SSLClientSocketPool. 1400 // It would be nice to also test the timeouts in SSLClientSocketPool.
1396 1401
1397 } // namespace 1402 } // namespace
1398 1403
1399 } // namespace net 1404 } // namespace net
OLDNEW
« net/http/http_network_session.h ('K') | « net/socket/client_socket_pool_manager_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698