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

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

Issue 903213003: Enable QUIC for proxies based on Finch config and command line switch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added comment Created 5 years, 10 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_stream_factory_impl_unittest.cc ('k') | no next file » | 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 402 matching lines...) Expand 10 before | Expand all | Expand 10 after
413 net::NetLog::TYPE_QUIC_SESSION_STREAM_FRAME_RECEIVED, 413 net::NetLog::TYPE_QUIC_SESSION_STREAM_FRAME_RECEIVED,
414 net::NetLog::PHASE_NONE); 414 net::NetLog::PHASE_NONE);
415 EXPECT_LT(0, pos); 415 EXPECT_LT(0, pos);
416 416
417 int log_stream_id; 417 int log_stream_id;
418 ASSERT_TRUE(entries[pos].GetIntegerValue("stream_id", &log_stream_id)); 418 ASSERT_TRUE(entries[pos].GetIntegerValue("stream_id", &log_stream_id));
419 EXPECT_EQ(3, log_stream_id); 419 EXPECT_EQ(3, log_stream_id);
420 } 420 }
421 421
422 TEST_P(QuicNetworkTransactionTest, QuicProxy) { 422 TEST_P(QuicNetworkTransactionTest, QuicProxy) {
423 params_.enable_quic_for_proxies = true;
423 proxy_service_.reset( 424 proxy_service_.reset(
424 ProxyService::CreateFixedFromPacResult("QUIC myproxy:70")); 425 ProxyService::CreateFixedFromPacResult("QUIC myproxy:70"));
425 426
426 MockQuicData mock_quic_data; 427 MockQuicData mock_quic_data;
427 mock_quic_data.AddWrite( 428 mock_quic_data.AddWrite(
428 ConstructRequestHeadersPacket(1, kClientDataStreamId1, true, true, 429 ConstructRequestHeadersPacket(1, kClientDataStreamId1, true, true,
429 GetRequestHeaders("GET", "http", "/"))); 430 GetRequestHeaders("GET", "http", "/")));
430 mock_quic_data.AddRead( 431 mock_quic_data.AddRead(
431 ConstructResponseHeadersPacket(1, kClientDataStreamId1, false, false, 432 ConstructResponseHeadersPacket(1, kClientDataStreamId1, false, false,
432 GetResponseHeaders("200 OK"))); 433 GetResponseHeaders("200 OK")));
(...skipping 630 matching lines...) Expand 10 before | Expand all | Expand 10 after
1063 nullptr, 1064 nullptr,
1064 net_log_.bound()); 1065 net_log_.bound());
1065 1066
1066 CreateSessionWithNextProtos(); 1067 CreateSessionWithNextProtos();
1067 AddQuicAlternateProtocolMapping(MockCryptoClientStream::ZERO_RTT); 1068 AddQuicAlternateProtocolMapping(MockCryptoClientStream::ZERO_RTT);
1068 SendRequestAndExpectHttpResponse("hello world"); 1069 SendRequestAndExpectHttpResponse("hello world");
1069 } 1070 }
1070 1071
1071 } // namespace test 1072 } // namespace test
1072 } // namespace net 1073 } // namespace net
OLDNEW
« no previous file with comments | « net/http/http_stream_factory_impl_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698