| 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 "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 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 233 scoped_ptr<ClientSocketPoolHistograms> ssl_histograms_; | 233 scoped_ptr<ClientSocketPoolHistograms> ssl_histograms_; |
| 234 scoped_ptr<SSLClientSocketPool> pool_; | 234 scoped_ptr<SSLClientSocketPool> pool_; |
| 235 | 235 |
| 236 bool enable_ssl_connect_job_waiting_; | 236 bool enable_ssl_connect_job_waiting_; |
| 237 }; | 237 }; |
| 238 | 238 |
| 239 INSTANTIATE_TEST_CASE_P( | 239 INSTANTIATE_TEST_CASE_P( |
| 240 NextProto, | 240 NextProto, |
| 241 SSLClientSocketPoolTest, | 241 SSLClientSocketPoolTest, |
| 242 testing::Values(kProtoDeprecatedSPDY2, | 242 testing::Values(kProtoDeprecatedSPDY2, |
| 243 kProtoSPDY3, kProtoSPDY31, kProtoSPDY4)); | 243 kProtoSPDY3, kProtoSPDY31, kProtoSPDY4_14, kProtoSPDY4_15)); |
| 244 | 244 |
| 245 // Tests that the final socket will connect even if all sockets | 245 // Tests that the final socket will connect even if all sockets |
| 246 // prior to it fail. | 246 // prior to it fail. |
| 247 // | 247 // |
| 248 // All sockets should wait for the first socket to attempt to | 248 // All sockets should wait for the first socket to attempt to |
| 249 // connect. Once it fails to connect, all other sockets should | 249 // connect. Once it fails to connect, all other sockets should |
| 250 // attempt to connect. All should fail, except the final socket. | 250 // attempt to connect. All should fail, except the final socket. |
| 251 TEST_P(SSLClientSocketPoolTest, AllSocketsFailButLast) { | 251 TEST_P(SSLClientSocketPoolTest, AllSocketsFailButLast) { |
| 252 // Although we request four sockets, the first three socket connect | 252 // Although we request four sockets, the first three socket connect |
| 253 // failures cause the socket pool to create three more sockets because | 253 // failures cause the socket pool to create three more sockets because |
| (...skipping 1142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1396 ssl.channel_id_sent = true; | 1396 ssl.channel_id_sent = true; |
| 1397 ssl.SetNextProto(GetParam()); | 1397 ssl.SetNextProto(GetParam()); |
| 1398 TestIPPoolingDisabled(&ssl); | 1398 TestIPPoolingDisabled(&ssl); |
| 1399 } | 1399 } |
| 1400 | 1400 |
| 1401 // It would be nice to also test the timeouts in SSLClientSocketPool. | 1401 // It would be nice to also test the timeouts in SSLClientSocketPool. |
| 1402 | 1402 |
| 1403 } // namespace | 1403 } // namespace |
| 1404 | 1404 |
| 1405 } // namespace net | 1405 } // namespace net |
| OLD | NEW |