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

Unified Diff: net/quic/quic_connection_test.cc

Issue 286213002: Refactor: move flow controller from QuicConnection to QuicSession. (Closed) Base URL: https://chromium.googlesource.com/chromium/src
Patch Set: Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_connection.cc ('k') | net/quic/quic_crypto_client_stream.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_connection_test.cc
diff --git a/net/quic/quic_connection_test.cc b/net/quic/quic_connection_test.cc
index 6ca7c30e215b96fd8f31f9d7dc83192bfb183906..7cfd5ab42218c09334ef889e45076a7d46d72469 100644
--- a/net/quic/quic_connection_test.cc
+++ b/net/quic/quic_connection_test.cc
@@ -419,11 +419,9 @@ class TestConnection : public QuicConnection {
TestConnectionHelper* helper,
TestPacketWriter* writer,
bool is_server,
- QuicVersion version,
- uint32 flow_control_send_window)
+ QuicVersion version)
: QuicConnection(connection_id, address, helper, writer, is_server,
- SupportedVersions(version),
- flow_control_send_window),
+ SupportedVersions(version)),
writer_(writer) {
// Disable tail loss probes for most tests.
QuicSentPacketManagerPeer::SetMaxTailLossProbes(
@@ -588,8 +586,7 @@ class QuicConnectionTest : public ::testing::TestWithParam<QuicVersion> {
helper_(new TestConnectionHelper(&clock_, &random_generator_)),
writer_(new TestPacketWriter(version())),
connection_(connection_id_, IPEndPoint(), helper_.get(),
- writer_.get(), false, version(),
- kDefaultFlowControlSendWindow),
+ writer_.get(), false, version()),
frame1_(1, false, 0, MakeIOVector(data1)),
frame2_(1, false, 3, MakeIOVector(data2)),
sequence_number_length_(PACKET_6BYTE_SEQUENCE_NUMBER),
@@ -3948,11 +3945,9 @@ TEST_P(QuicConnectionTest, Pacing) {
ValueRestore<bool> old_flag(&FLAGS_enable_quic_pacing, true);
TestConnection server(connection_id_, IPEndPoint(), helper_.get(),
- writer_.get(), true, version(),
- kDefaultFlowControlSendWindow);
+ writer_.get(), true, version());
TestConnection client(connection_id_, IPEndPoint(), helper_.get(),
- writer_.get(), false, version(),
- kDefaultFlowControlSendWindow);
+ writer_.get(), false, version());
EXPECT_TRUE(client.sent_packet_manager().using_pacing());
EXPECT_FALSE(server.sent_packet_manager().using_pacing());
}
@@ -3980,17 +3975,6 @@ TEST_P(QuicConnectionTest, ControlFramesInstigateAcks) {
EXPECT_TRUE(ack_alarm->IsSet());
}
-TEST_P(QuicConnectionTest, InvalidFlowControlWindow) {
- ValueRestore<bool> old_flag(&FLAGS_enable_quic_pacing, true);
-
- const uint32 kSmallerFlowControlWindow = kDefaultFlowControlSendWindow - 1;
- TestConnection connection(connection_id_, IPEndPoint(), helper_.get(),
- writer_.get(), true, version(),
- kSmallerFlowControlWindow);
- EXPECT_EQ(kDefaultFlowControlSendWindow,
- connection.max_flow_control_receive_window_bytes());
-}
-
} // namespace
} // namespace test
} // namespace net
« no previous file with comments | « net/quic/quic_connection.cc ('k') | net/quic/quic_crypto_client_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698