In QUIC client with TLS versions, delay retransmission of 0-RTT packets until 1-RTT keys are available.
Protected by enabled gfe2_reloadable_flag_quic_do_not_retransmit_immediately_on_zero_rtt_reject as this only affects client side.
PiperOrigin-RevId: 317142127
Change-Id: I21a297e9e1f181558fc27406960d56e3327a2778
diff --git a/quic/core/quic_connection_test.cc b/quic/core/quic_connection_test.cc
index b1409bf..d273bbe 100644
--- a/quic/core/quic_connection_test.cc
+++ b/quic/core/quic_connection_test.cc
@@ -4543,6 +4543,8 @@
}
TEST_P(QuicConnectionTest, RetransmitPacketsWithInitialEncryption) {
+ SetQuicReloadableFlag(quic_do_not_retransmit_immediately_on_zero_rtt_reject,
+ true);
use_tagging_decrypter();
connection_.SetEncrypter(ENCRYPTION_INITIAL,
std::make_unique<TaggingEncrypter>(0x01));
@@ -4555,9 +4557,9 @@
connection_.SetDefaultEncryptionLevel(ENCRYPTION_ZERO_RTT);
SendStreamDataToPeer(2, "bar", 0, NO_FIN, nullptr);
- EXPECT_CALL(*send_algorithm_, OnPacketSent(_, _, _, _, _)).Times(1);
-
+ EXPECT_FALSE(notifier_.HasLostStreamData());
connection_.RetransmitZeroRttPackets();
+ EXPECT_TRUE(notifier_.HasLostStreamData());
}
TEST_P(QuicConnectionTest, BufferNonDecryptablePackets) {