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

Unified Diff: net/quic/quic_sent_packet_manager_test.cc

Issue 573763003: client-only - Change QUIC clients to use the initial RTT estimate that (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Increase_flow_control_receive_window_75381087
Patch Set: Created 6 years, 3 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_sent_packet_manager.cc ('k') | net/tools/quic/end_to_end_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_sent_packet_manager_test.cc
diff --git a/net/quic/quic_sent_packet_manager_test.cc b/net/quic/quic_sent_packet_manager_test.cc
index 6b33f45661fc34c5bba6712b7d2c6e7d865aff20..98dfdef6af83430357a3b2a522ecc88b784df4f4 100644
--- a/net/quic/quic_sent_packet_manager_test.cc
+++ b/net/quic/quic_sent_packet_manager_test.cc
@@ -1450,6 +1450,23 @@ TEST_F(QuicSentPacketManagerTest, NegotiatePacingFromOptions) {
EXPECT_TRUE(manager_.using_pacing());
}
+TEST_F(QuicSentPacketManagerTest, UseInitialRoundTripTimeToSend) {
+ uint32 initial_rtt_us = 325000;
+ EXPECT_NE(initial_rtt_us,
+ manager_.GetRttStats()->SmoothedRtt().ToMicroseconds());
+
+ QuicConfig config;
+ config.SetInitialRoundTripTimeUsToSend(initial_rtt_us);
+ EXPECT_CALL(*send_algorithm_, SetFromConfig(_, _));
+ EXPECT_CALL(*network_change_visitor_, OnCongestionWindowChange(_));
+ EXPECT_CALL(*send_algorithm_, GetCongestionWindow())
+ .WillOnce(Return(100 * kDefaultTCPMSS));
+ manager_.SetFromConfig(config);
+
+ EXPECT_EQ(initial_rtt_us,
+ manager_.GetRttStats()->SmoothedRtt().ToMicroseconds());
+}
+
} // namespace
} // namespace test
} // namespace net
« no previous file with comments | « net/quic/quic_sent_packet_manager.cc ('k') | net/tools/quic/end_to_end_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698