| 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 <vector> | 5 #include <vector> |
| 6 | 6 |
| 7 #include "base/compiler_specific.h" | 7 #include "base/compiler_specific.h" |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/run_loop.h" | 10 #include "base/run_loop.h" |
| (...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 424 params_.cert_verifier = &cert_verifier_; | 424 params_.cert_verifier = &cert_verifier_; |
| 425 params_.transport_security_state = &transport_security_state_; | 425 params_.transport_security_state = &transport_security_state_; |
| 426 params_.cert_transparency_verifier = cert_transparency_verifier_.get(); | 426 params_.cert_transparency_verifier = cert_transparency_verifier_.get(); |
| 427 params_.socket_performance_watcher_factory = | 427 params_.socket_performance_watcher_factory = |
| 428 test_network_quality_estimator_.get(); | 428 test_network_quality_estimator_.get(); |
| 429 params_.proxy_service = proxy_service_.get(); | 429 params_.proxy_service = proxy_service_.get(); |
| 430 params_.ssl_config_service = ssl_config_service_.get(); | 430 params_.ssl_config_service = ssl_config_service_.get(); |
| 431 params_.http_auth_handler_factory = auth_handler_factory_.get(); | 431 params_.http_auth_handler_factory = auth_handler_factory_.get(); |
| 432 params_.http_server_properties = http_server_properties_.GetWeakPtr(); | 432 params_.http_server_properties = http_server_properties_.GetWeakPtr(); |
| 433 params_.quic_supported_versions = SupportedVersions(GetParam()); | 433 params_.quic_supported_versions = SupportedVersions(GetParam()); |
| 434 for (const char* host : | |
| 435 {kDefaultServerHostName, "www.example.com", "news.example.com", | |
| 436 "bar.example.com", "foo.example.com", "www.example.org", | |
| 437 "invalid.example.org", "docs.example.org"}) { | |
| 438 params_.quic_host_whitelist.insert(host); | |
| 439 } | |
| 440 | 434 |
| 441 test_network_quality_estimator_->AddRTTObserver(&rtt_observer_); | 435 test_network_quality_estimator_->AddRTTObserver(&rtt_observer_); |
| 442 | 436 |
| 443 if (use_next_protos) { | 437 if (use_next_protos) { |
| 444 params_.use_alternative_services = true; | 438 params_.use_alternative_services = true; |
| 445 params_.next_protos = NextProtosWithSpdyAndQuic(true, true); | 439 params_.next_protos = NextProtosWithSpdyAndQuic(true, true); |
| 446 } | 440 } |
| 447 | 441 |
| 448 session_.reset(new HttpNetworkSession(params_)); | 442 session_.reset(new HttpNetworkSession(params_)); |
| 449 session_->quic_stream_factory()->set_require_confirmation(false); | 443 session_->quic_stream_factory()->set_require_confirmation(false); |
| (...skipping 1804 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2254 request_.url = GURL("https://www.example.org:443"); | 2248 request_.url = GURL("https://www.example.org:443"); |
| 2255 AddHangingNonAlternateProtocolSocketData(); | 2249 AddHangingNonAlternateProtocolSocketData(); |
| 2256 CreateSessionWithNextProtos(); | 2250 CreateSessionWithNextProtos(); |
| 2257 AddQuicAlternateProtocolMapping(MockCryptoClientStream::CONFIRM_HANDSHAKE); | 2251 AddQuicAlternateProtocolMapping(MockCryptoClientStream::CONFIRM_HANDSHAKE); |
| 2258 SendRequestAndExpectQuicResponse("hello!"); | 2252 SendRequestAndExpectQuicResponse("hello!"); |
| 2259 EXPECT_TRUE(rtt_observer_.rtt_notification_received()); | 2253 EXPECT_TRUE(rtt_observer_.rtt_notification_received()); |
| 2260 } | 2254 } |
| 2261 | 2255 |
| 2262 } // namespace test | 2256 } // namespace test |
| 2263 } // namespace net | 2257 } // namespace net |
| OLD | NEW |