| 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_stream_factory_impl.h" | 5 #include "net/http/http_stream_factory_impl.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 620 for (int i = 1; i <= 2; i++) { | 620 for (int i = 1; i <= 2; i++) { |
| 621 int mock_error = | 621 int mock_error = |
| 622 i == 1 ? ERR_QUIC_PROTOCOL_ERROR : ERR_QUIC_HANDSHAKE_FAILED; | 622 i == 1 ? ERR_QUIC_PROTOCOL_ERROR : ERR_QUIC_HANDSHAKE_FAILED; |
| 623 | 623 |
| 624 scoped_ptr<ProxyService> proxy_service; | 624 scoped_ptr<ProxyService> proxy_service; |
| 625 proxy_service.reset( | 625 proxy_service.reset( |
| 626 ProxyService::CreateFixedFromPacResult("QUIC bad:99; DIRECT")); | 626 ProxyService::CreateFixedFromPacResult("QUIC bad:99; DIRECT")); |
| 627 | 627 |
| 628 HttpNetworkSession::Params params; | 628 HttpNetworkSession::Params params; |
| 629 params.enable_quic = true; | 629 params.enable_quic = true; |
| 630 params.enable_quic_for_proxies = true; |
| 630 scoped_refptr<SSLConfigServiceDefaults> ssl_config_service( | 631 scoped_refptr<SSLConfigServiceDefaults> ssl_config_service( |
| 631 new SSLConfigServiceDefaults); | 632 new SSLConfigServiceDefaults); |
| 632 HttpServerPropertiesImpl http_server_properties; | 633 HttpServerPropertiesImpl http_server_properties; |
| 633 MockClientSocketFactory socket_factory; | 634 MockClientSocketFactory socket_factory; |
| 634 params.client_socket_factory = &socket_factory; | 635 params.client_socket_factory = &socket_factory; |
| 635 MockHostResolver host_resolver; | 636 MockHostResolver host_resolver; |
| 636 params.host_resolver = &host_resolver; | 637 params.host_resolver = &host_resolver; |
| 637 TransportSecurityState transport_security_state; | 638 TransportSecurityState transport_security_state; |
| 638 params.transport_security_state = &transport_security_state; | 639 params.transport_security_state = &transport_security_state; |
| 639 params.proxy_service = proxy_service.get(); | 640 params.proxy_service = proxy_service.get(); |
| (...skipping 719 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1359 EXPECT_TRUE(waiter.used_proxy_info().is_direct()); | 1360 EXPECT_TRUE(waiter.used_proxy_info().is_direct()); |
| 1360 | 1361 |
| 1361 // Make sure there is no orphaned job. it is already canceled. | 1362 // Make sure there is no orphaned job. it is already canceled. |
| 1362 ASSERT_EQ(0u, static_cast<HttpStreamFactoryImpl*>( | 1363 ASSERT_EQ(0u, static_cast<HttpStreamFactoryImpl*>( |
| 1363 session->http_stream_factory_for_websocket())->num_orphaned_jobs()); | 1364 session->http_stream_factory_for_websocket())->num_orphaned_jobs()); |
| 1364 } | 1365 } |
| 1365 | 1366 |
| 1366 } // namespace | 1367 } // namespace |
| 1367 | 1368 |
| 1368 } // namespace net | 1369 } // namespace net |
| OLD | NEW |