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

Unified Diff: net/quic/quic_connection_test.cc

Issue 731863007: Changes QUIC's SentPacketManager to pass in HAS_RETRANSMITTABLE_DATA to (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Record_last_packet_send_time_80138676
Patch Set: Created 6 years, 1 month 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/time_loss_algorithm_test.cc ('k') | net/quic/quic_protocol.h » ('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 95dcd12eda369019738af751ee03c1cdbabd104b..52d9d8e439467def8efc89414761c0794c024b09 100644
--- a/net/quic/quic_connection_test.cc
+++ b/net/quic/quic_connection_test.cc
@@ -1654,7 +1654,8 @@ TEST_P(QuicConnectionTest, FECSending) {
creator->set_max_packet_length(length);
// Send 4 protected data packets, which should also trigger 1 FEC packet.
- EXPECT_CALL(*send_algorithm_, OnPacketSent(_, _, _, _, _)).Times(5);
+ EXPECT_CALL(*send_algorithm_,
+ OnPacketSent(_, _, _, _, HAS_RETRANSMITTABLE_DATA)).Times(5);
// The first stream frame will have 2 fewer overhead bytes than the other 3.
const string payload(payload_length * 4 + 2, 'a');
connection_.SendStreamDataWithStringWithFec(1, payload, 0, !kFin, nullptr);
@@ -1690,7 +1691,8 @@ TEST_P(QuicConnectionTest, AbandonFECFromCongestionWindow) {
&connection_)->IsFecEnabled());
// 1 Data and 1 FEC packet.
- EXPECT_CALL(*send_algorithm_, OnPacketSent(_, _, _, _, _)).Times(2);
+ EXPECT_CALL(*send_algorithm_,
+ OnPacketSent(_, _, _, _, HAS_RETRANSMITTABLE_DATA)).Times(2);
connection_.SendStreamDataWithStringWithFec(3, "foo", 0, !kFin, nullptr);
const QuicTime::Delta retransmission_time =
@@ -1709,8 +1711,9 @@ TEST_P(QuicConnectionTest, DontAbandonAckedFEC) {
EXPECT_TRUE(QuicConnectionPeer::GetPacketCreator(
&connection_)->IsFecEnabled());
- // 1 Data and 1 FEC packet.
- EXPECT_CALL(*send_algorithm_, OnPacketSent(_, _, _, _, _)).Times(6);
+ // 3 Data and 3 FEC packets.
+ EXPECT_CALL(*send_algorithm_,
+ OnPacketSent(_, _, _, _, HAS_RETRANSMITTABLE_DATA)).Times(6);
connection_.SendStreamDataWithStringWithFec(3, "foo", 0, !kFin, nullptr);
// Send some more data afterwards to ensure early retransmit doesn't trigger.
connection_.SendStreamDataWithStringWithFec(3, "foo", 3, !kFin, nullptr);
@@ -1737,8 +1740,9 @@ TEST_P(QuicConnectionTest, AbandonAllFEC) {
EXPECT_TRUE(QuicConnectionPeer::GetPacketCreator(
&connection_)->IsFecEnabled());
- // 1 Data and 1 FEC packet.
- EXPECT_CALL(*send_algorithm_, OnPacketSent(_, _, _, _, _)).Times(6);
+ // 3 Data and 3 FEC packet.
+ EXPECT_CALL(*send_algorithm_,
+ OnPacketSent(_, _, _, _, HAS_RETRANSMITTABLE_DATA)).Times(6);
connection_.SendStreamDataWithStringWithFec(3, "foo", 0, !kFin, nullptr);
// Send some more data afterwards to ensure early retransmit doesn't trigger.
connection_.SendStreamDataWithStringWithFec(3, "foo", 3, !kFin, nullptr);
« no previous file with comments | « net/quic/congestion_control/time_loss_algorithm_test.cc ('k') | net/quic/quic_protocol.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698