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/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 params_.cert_verifier = &cert_verifier_; | 207 params_.cert_verifier = &cert_verifier_; |
208 params_.transport_security_state = &transport_security_state_; | 208 params_.transport_security_state = &transport_security_state_; |
209 params_.proxy_service = proxy_service_.get(); | 209 params_.proxy_service = proxy_service_.get(); |
210 params_.ssl_config_service = ssl_config_service_.get(); | 210 params_.ssl_config_service = ssl_config_service_.get(); |
211 params_.http_auth_handler_factory = auth_handler_factory_.get(); | 211 params_.http_auth_handler_factory = auth_handler_factory_.get(); |
212 params_.http_server_properties = http_server_properties.GetWeakPtr(); | 212 params_.http_server_properties = http_server_properties.GetWeakPtr(); |
213 params_.quic_supported_versions = SupportedVersions(GetParam()); | 213 params_.quic_supported_versions = SupportedVersions(GetParam()); |
214 | 214 |
215 if (use_next_protos) { | 215 if (use_next_protos) { |
216 params_.use_alternate_protocols = true; | 216 params_.use_alternate_protocols = true; |
217 params_.next_protos = NextProtosSpdy3(); | 217 params_.next_protos = NextProtosWithSpdyAndQuic(true, true); |
218 } | 218 } |
219 | 219 |
220 session_ = new HttpNetworkSession(params_); | 220 session_ = new HttpNetworkSession(params_); |
221 session_->quic_stream_factory()->set_require_confirmation(false); | 221 session_->quic_stream_factory()->set_require_confirmation(false); |
222 } | 222 } |
223 | 223 |
224 void CheckWasQuicResponse(const scoped_ptr<HttpNetworkTransaction>& trans) { | 224 void CheckWasQuicResponse(const scoped_ptr<HttpNetworkTransaction>& trans) { |
225 const HttpResponseInfo* response = trans->GetResponseInfo(); | 225 const HttpResponseInfo* response = trans->GetResponseInfo(); |
226 ASSERT_TRUE(response != nullptr); | 226 ASSERT_TRUE(response != nullptr); |
227 ASSERT_TRUE(response->headers.get() != nullptr); | 227 ASSERT_TRUE(response->headers.get() != nullptr); |
(...skipping 804 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1032 nullptr, | 1032 nullptr, |
1033 net_log_.bound()); | 1033 net_log_.bound()); |
1034 | 1034 |
1035 CreateSessionWithNextProtos(); | 1035 CreateSessionWithNextProtos(); |
1036 AddQuicAlternateProtocolMapping(MockCryptoClientStream::ZERO_RTT); | 1036 AddQuicAlternateProtocolMapping(MockCryptoClientStream::ZERO_RTT); |
1037 SendRequestAndExpectHttpResponse("hello world"); | 1037 SendRequestAndExpectHttpResponse("hello world"); |
1038 } | 1038 } |
1039 | 1039 |
1040 } // namespace test | 1040 } // namespace test |
1041 } // namespace net | 1041 } // namespace net |
OLD | NEW |