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

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

Issue 446253002: QUIC congestion option that forces ICWND to 10. Not flag protected. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@allow_receiving_CongestionFeedbackFrame_72322097
Patch Set: Created 6 years, 4 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/congestion_control/tcp_cubic_sender.cc ('k') | net/quic/crypto/crypto_protocol.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/congestion_control/tcp_cubic_sender_test.cc
diff --git a/net/quic/congestion_control/tcp_cubic_sender_test.cc b/net/quic/congestion_control/tcp_cubic_sender_test.cc
index ef2e1c0a2cf0ff5a68305f1ae2a209aa138b6635..d80c4f80a779221693ad89dacce2e8198fed0b13 100644
--- a/net/quic/congestion_control/tcp_cubic_sender_test.cc
+++ b/net/quic/congestion_control/tcp_cubic_sender_test.cc
@@ -9,6 +9,7 @@
#include "net/quic/congestion_control/rtt_stats.h"
#include "net/quic/congestion_control/tcp_cubic_sender.h"
#include "net/quic/congestion_control/tcp_receiver.h"
+#include "net/quic/crypto/crypto_protocol.h"
#include "net/quic/quic_utils.h"
#include "net/quic/test_tools/mock_clock.h"
#include "net/quic/test_tools/quic_config_peer.h"
@@ -612,6 +613,14 @@ TEST_F(TcpCubicSenderTest, ConfigureMaxInitialWindow) {
sender_->SetFromConfig(config, true);
EXPECT_EQ(2 * congestion_window, sender_->congestion_window());
+
+ // Verify that kCOPT: kIW10 forces the congestion window to the
+ // default of 10 regardless of ReceivedInitialWindow.
+ QuicTagVector options;
+ options.push_back(kIW10);
+ QuicConfigPeer::SetReceivedConnectionOptions(&config, options);
+ sender_->SetFromConfig(config, true);
+ EXPECT_EQ(congestion_window, sender_->congestion_window());
}
TEST_F(TcpCubicSenderTest, CongestionAvoidanceAtEndOfRecovery) {
« no previous file with comments | « net/quic/congestion_control/tcp_cubic_sender.cc ('k') | net/quic/crypto/crypto_protocol.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698