Index: webrtc/modules/rtp_rtcp/source/nack_rtx_unittest.cc |
diff --git a/webrtc/modules/rtp_rtcp/source/nack_rtx_unittest.cc b/webrtc/modules/rtp_rtcp/source/nack_rtx_unittest.cc |
index f8d92438589aed763dfa881adb8fe1d6bec44ef6..b12c08e6424fa06f21dc04d65884ee97eaf732ff 100644 |
--- a/webrtc/modules/rtp_rtcp/source/nack_rtx_unittest.cc |
+++ b/webrtc/modules/rtp_rtcp/source/nack_rtx_unittest.cc |
@@ -15,6 +15,7 @@ |
#include <set> |
#include "testing/gtest/include/gtest/gtest.h" |
+#include "webrtc/base/rate_limiter.h" |
#include "webrtc/common_types.h" |
#include "webrtc/modules/rtp_rtcp/include/receive_statistics.h" |
#include "webrtc/modules/rtp_rtcp/include/rtp_header_parser.h" |
@@ -34,6 +35,7 @@ |
const int kNumFrames = 30; |
const int kPayloadType = 123; |
const int kRtxPayloadType = 98; |
+const int64_t kMaxRttMs = 1000; |
class VerifyingRtxReceiver : public NullRtpData { |
public: |
@@ -168,11 +170,12 @@ |
protected: |
RtpRtcpRtxNackTest() |
: rtp_payload_registry_(RTPPayloadStrategy::CreateStrategy(false)), |
- rtp_rtcp_module_(NULL), |
+ rtp_rtcp_module_(nullptr), |
transport_(kTestSsrc + 1), |
receiver_(), |
payload_data_length(sizeof(payload_data)), |
- fake_clock(123456) {} |
+ fake_clock(123456), |
+ retranmission_rate_limiter_(&fake_clock, kMaxRttMs) {} |
~RtpRtcpRtxNackTest() {} |
void SetUp() override { |
@@ -182,6 +185,7 @@ |
receive_statistics_.reset(ReceiveStatistics::Create(&fake_clock)); |
configuration.receive_statistics = receive_statistics_.get(); |
configuration.outgoing_transport = &transport_; |
+ configuration.retransmission_rate_limiter = &retranmission_rate_limiter_; |
rtp_rtcp_module_ = RtpRtcp::CreateRtpRtcp(configuration); |
rtp_feedback_.reset(new TestRtpFeedback(rtp_rtcp_module_)); |
@@ -288,6 +292,7 @@ |
uint8_t payload_data[65000]; |
size_t payload_data_length; |
SimulatedClock fake_clock; |
+ RateLimiter retranmission_rate_limiter_; |
}; |
TEST_F(RtpRtcpRtxNackTest, LongNackList) { |