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

Side by Side Diff: net/tools/quic/quic_client_session_test.cc

Issue 605163004: Land Recent QUIC Changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Final_0925
Patch Set: Created 6 years, 2 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/tools/quic/end_to_end_test.cc ('k') | net/tools/quic/quic_server_session_test.cc » ('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 "net/tools/quic/quic_client_session.h" 5 #include "net/tools/quic/quic_client_session.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "net/base/ip_endpoint.h" 9 #include "net/base/ip_endpoint.h"
10 #include "net/quic/crypto/aes_128_gcm_12_encrypter.h" 10 #include "net/quic/crypto/aes_128_gcm_12_encrypter.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 }; 62 };
63 63
64 INSTANTIATE_TEST_CASE_P(Tests, ToolsQuicClientSessionTest, 64 INSTANTIATE_TEST_CASE_P(Tests, ToolsQuicClientSessionTest,
65 ::testing::ValuesIn(QuicSupportedVersions())); 65 ::testing::ValuesIn(QuicSupportedVersions()));
66 66
67 TEST_P(ToolsQuicClientSessionTest, CryptoConnect) { 67 TEST_P(ToolsQuicClientSessionTest, CryptoConnect) {
68 CompleteCryptoHandshake(); 68 CompleteCryptoHandshake();
69 } 69 }
70 70
71 TEST_P(ToolsQuicClientSessionTest, MaxNumStreams) { 71 TEST_P(ToolsQuicClientSessionTest, MaxNumStreams) {
72 session_->config()->set_max_streams_per_connection(1, 1); 72 session_->config()->SetMaxStreamsPerConnection(1, 1);
73 // FLAGS_max_streams_per_connection = 1; 73 // FLAGS_max_streams_per_connection = 1;
74 // Initialize crypto before the client session will create a stream. 74 // Initialize crypto before the client session will create a stream.
75 CompleteCryptoHandshake(); 75 CompleteCryptoHandshake();
76 76
77 QuicSpdyClientStream* stream = 77 QuicSpdyClientStream* stream =
78 session_->CreateOutgoingDataStream(); 78 session_->CreateOutgoingDataStream();
79 ASSERT_TRUE(stream); 79 ASSERT_TRUE(stream);
80 EXPECT_FALSE(session_->CreateOutgoingDataStream()); 80 EXPECT_FALSE(session_->CreateOutgoingDataStream());
81 81
82 // Close a stream and ensure I can now open a new one. 82 // Close a stream and ensure I can now open a new one.
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 // Close connection shouldn't be called. 144 // Close connection shouldn't be called.
145 EXPECT_CALL(*connection_, SendConnectionCloseWithDetails(_, _)).Times(0); 145 EXPECT_CALL(*connection_, SendConnectionCloseWithDetails(_, _)).Times(0);
146 session_->connection()->ProcessUdpPacket(client_address, server_address, 146 session_->connection()->ProcessUdpPacket(client_address, server_address,
147 valid_packet); 147 valid_packet);
148 } 148 }
149 149
150 } // namespace 150 } // namespace
151 } // namespace test 151 } // namespace test
152 } // namespace tools 152 } // namespace tools
153 } // namespace net 153 } // namespace net
OLDNEW
« no previous file with comments | « net/tools/quic/end_to_end_test.cc ('k') | net/tools/quic/quic_server_session_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698