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

Unified Diff: net/quic/congestion_control/tcp_cubic_sender_bytes_test.cc

Issue 2005853002: Ignore the peer's receive buffer in QUIC and instead set the max CWND to 2000 packets. Protected b… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@122420070
Patch Set: Created 4 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
Index: net/quic/congestion_control/tcp_cubic_sender_bytes_test.cc
diff --git a/net/quic/congestion_control/tcp_cubic_sender_bytes_test.cc b/net/quic/congestion_control/tcp_cubic_sender_bytes_test.cc
index 7e2c0ad94ae7c01b677e100c573d1f89d97b3149..d790f6239076738062639baebe22e70c5e1d4902 100644
--- a/net/quic/congestion_control/tcp_cubic_sender_bytes_test.cc
+++ b/net/quic/congestion_control/tcp_cubic_sender_bytes_test.cc
@@ -811,5 +811,24 @@ TEST_F(TcpCubicSenderBytesTest, ResetAfterConnectionMigration) {
EXPECT_FALSE(sender_->hybrid_slow_start().started());
}
+TEST_F(TcpCubicSenderBytesTest, DefaultMaxCwnd) {
+ ValueRestore<bool> old_flag(&FLAGS_quic_ignore_srbf, true);
+ RttStats rtt_stats;
+ QuicConnectionStats stats;
+ std::unique_ptr<SendAlgorithmInterface> sender(SendAlgorithmInterface::Create(
+ &clock_, &rtt_stats, kCubicBytes, &stats, kInitialCongestionWindow));
+
+ SendAlgorithmInterface::CongestionVector acked_packets;
+ SendAlgorithmInterface::CongestionVector missing_packets;
+ for (uint64_t i = 1; i < kDefaultMaxCongestionWindowPackets; ++i) {
+ acked_packets.clear();
+ acked_packets.push_back(std::make_pair(i, 1350));
+ sender->OnCongestionEvent(true, sender->GetCongestionWindow(),
+ acked_packets, missing_packets);
+ }
+ EXPECT_EQ(kDefaultMaxCongestionWindowPackets,
+ sender->GetCongestionWindow() / kDefaultTCPMSS);
+}
+
} // namespace test
} // namespace net
« no previous file with comments | « net/quic/congestion_control/tcp_cubic_sender_bytes.cc ('k') | net/quic/congestion_control/tcp_cubic_sender_packets.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698