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

Side by Side Diff: net/quic/quic_network_transaction_unittest.cc

Issue 1238613004: [Merge to M45] Fix order of arguments in QuicStreamFactory constructor. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2454
Patch Set: Created 5 years, 5 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
« no previous file with comments | « net/http/http_network_session.cc ('k') | net/quic/quic_stream_factory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 <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 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 params_.http_server_properties = http_server_properties_.GetWeakPtr(); 245 params_.http_server_properties = http_server_properties_.GetWeakPtr();
246 params_.quic_supported_versions = SupportedVersions(GetParam()); 246 params_.quic_supported_versions = SupportedVersions(GetParam());
247 247
248 if (use_next_protos) { 248 if (use_next_protos) {
249 params_.use_alternate_protocols = true; 249 params_.use_alternate_protocols = true;
250 params_.next_protos = NextProtosWithSpdyAndQuic(true, true); 250 params_.next_protos = NextProtosWithSpdyAndQuic(true, true);
251 } 251 }
252 252
253 session_ = new HttpNetworkSession(params_); 253 session_ = new HttpNetworkSession(params_);
254 session_->quic_stream_factory()->set_require_confirmation(false); 254 session_->quic_stream_factory()->set_require_confirmation(false);
255 ASSERT_EQ(params_.quic_socket_receive_buffer_size,
256 session_->quic_stream_factory()->socket_receive_buffer_size());
255 } 257 }
256 258
257 void CheckWasQuicResponse(const scoped_ptr<HttpNetworkTransaction>& trans) { 259 void CheckWasQuicResponse(const scoped_ptr<HttpNetworkTransaction>& trans) {
258 const HttpResponseInfo* response = trans->GetResponseInfo(); 260 const HttpResponseInfo* response = trans->GetResponseInfo();
259 ASSERT_TRUE(response != nullptr); 261 ASSERT_TRUE(response != nullptr);
260 ASSERT_TRUE(response->headers.get() != nullptr); 262 ASSERT_TRUE(response->headers.get() != nullptr);
261 EXPECT_EQ("HTTP/1.1 200 OK", response->headers->GetStatusLine()); 263 EXPECT_EQ("HTTP/1.1 200 OK", response->headers->GetStatusLine());
262 EXPECT_TRUE(response->was_fetched_via_spdy); 264 EXPECT_TRUE(response->was_fetched_via_spdy);
263 EXPECT_TRUE(response->was_npn_negotiated); 265 EXPECT_TRUE(response->was_npn_negotiated);
264 EXPECT_EQ(HttpResponseInfo::CONNECTION_INFO_QUIC1_SPDY3, 266 EXPECT_EQ(HttpResponseInfo::CONNECTION_INFO_QUIC1_SPDY3,
(...skipping 1118 matching lines...) Expand 10 before | Expand all | Expand 10 after
1383 1385
1384 request_.url = GURL("https://www.example.org:443"); 1386 request_.url = GURL("https://www.example.org:443");
1385 AddHangingNonAlternateProtocolSocketData(); 1387 AddHangingNonAlternateProtocolSocketData();
1386 CreateSessionWithNextProtos(); 1388 CreateSessionWithNextProtos();
1387 AddQuicAlternateProtocolMapping(MockCryptoClientStream::CONFIRM_HANDSHAKE); 1389 AddQuicAlternateProtocolMapping(MockCryptoClientStream::CONFIRM_HANDSHAKE);
1388 SendRequestAndExpectQuicResponse("hello!"); 1390 SendRequestAndExpectQuicResponse("hello!");
1389 } 1391 }
1390 1392
1391 } // namespace test 1393 } // namespace test
1392 } // namespace net 1394 } // namespace net
OLDNEW
« no previous file with comments | « net/http/http_network_session.cc ('k') | net/quic/quic_stream_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698