| Index: net/quic/quic_connection_test.cc
|
| diff --git a/net/quic/quic_connection_test.cc b/net/quic/quic_connection_test.cc
|
| index 921ca9cc2b462bcf86967c27d4951fce8a7a9e7d..102bb3340ae4be4157c3eda946e4391e34f6fe7c 100644
|
| --- a/net/quic/quic_connection_test.cc
|
| +++ b/net/quic/quic_connection_test.cc
|
| @@ -476,6 +476,11 @@ class TestConnection : public QuicConnection {
|
| QuicConnectionPeer::GetSendAlarm(this));
|
| }
|
|
|
| + TestConnectionHelper::TestAlarm* GetResumeWritesAlarm() {
|
| + return reinterpret_cast<TestConnectionHelper::TestAlarm*>(
|
| + QuicConnectionPeer::GetResumeWritesAlarm(this));
|
| + }
|
| +
|
| TestConnectionHelper::TestAlarm* GetTimeoutAlarm() {
|
| return reinterpret_cast<TestConnectionHelper::TestAlarm*>(
|
| QuicConnectionPeer::GetTimeoutAlarm(this));
|
| @@ -1699,6 +1704,18 @@ TEST_P(QuicConnectionTest, QueueAfterTwoRTOs) {
|
| connection_.OnCanWrite();
|
| }
|
|
|
| +TEST_P(QuicConnectionTest, ResumptionAlarmThenWriteBlocked) {
|
| + // Set the send and resumption alarm, then block the connection.
|
| + connection_.GetResumeWritesAlarm()->Set(clock_.ApproximateNow());
|
| + connection_.GetSendAlarm()->Set(clock_.ApproximateNow());
|
| + QuicConnectionPeer::SetIsWriteBlocked(&connection_, true);
|
| +
|
| + // Fire the alarms and ensure the connection is still write blocked.
|
| + connection_.GetResumeWritesAlarm()->Fire();
|
| + connection_.GetSendAlarm()->Fire();
|
| + EXPECT_TRUE(QuicConnectionPeer::IsWriteBlocked(&connection_));
|
| +}
|
| +
|
| TEST_P(QuicConnectionTest, LimitPacketsPerNack) {
|
| EXPECT_CALL(visitor_, OnSuccessfulVersionNegotiation(_));
|
| EXPECT_CALL(*send_algorithm_, OnIncomingAck(12, _, _)).Times(1);
|
|
|