OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 int count_rtx_ssrc_; | 162 int count_rtx_ssrc_; |
163 RTPPayloadRegistry* rtp_payload_registry_; | 163 RTPPayloadRegistry* rtp_payload_registry_; |
164 RtpReceiver* rtp_receiver_; | 164 RtpReceiver* rtp_receiver_; |
165 RtpRtcp* module_; | 165 RtpRtcp* module_; |
166 std::set<uint16_t> expected_sequence_numbers_; | 166 std::set<uint16_t> expected_sequence_numbers_; |
167 }; | 167 }; |
168 | 168 |
169 class RtpRtcpRtxNackTest : public ::testing::Test { | 169 class RtpRtcpRtxNackTest : public ::testing::Test { |
170 protected: | 170 protected: |
171 RtpRtcpRtxNackTest() | 171 RtpRtcpRtxNackTest() |
172 : rtp_payload_registry_(RTPPayloadStrategy::CreateStrategy(false)), | 172 : rtp_rtcp_module_(nullptr), |
173 rtp_rtcp_module_(nullptr), | |
174 transport_(kTestSsrc + 1), | 173 transport_(kTestSsrc + 1), |
175 receiver_(), | 174 receiver_(), |
176 payload_data_length(sizeof(payload_data)), | 175 payload_data_length(sizeof(payload_data)), |
177 fake_clock(123456), | 176 fake_clock(123456), |
178 retransmission_rate_limiter_(&fake_clock, kMaxRttMs) {} | 177 retransmission_rate_limiter_(&fake_clock, kMaxRttMs) {} |
179 ~RtpRtcpRtxNackTest() {} | 178 ~RtpRtcpRtxNackTest() {} |
180 | 179 |
181 void SetUp() override { | 180 void SetUp() override { |
182 RtpRtcp::Configuration configuration; | 181 RtpRtcp::Configuration configuration; |
183 configuration.audio = false; | 182 configuration.audio = false; |
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
335 RunRtxTest(kRtxRetransmitted, 10); | 334 RunRtxTest(kRtxRetransmitted, 10); |
336 EXPECT_EQ(kTestSequenceNumber, *(receiver_.sequence_numbers_.begin())); | 335 EXPECT_EQ(kTestSequenceNumber, *(receiver_.sequence_numbers_.begin())); |
337 EXPECT_EQ(kTestSequenceNumber + kTestNumberOfPackets - 1, | 336 EXPECT_EQ(kTestSequenceNumber + kTestNumberOfPackets - 1, |
338 *(receiver_.sequence_numbers_.rbegin())); | 337 *(receiver_.sequence_numbers_.rbegin())); |
339 EXPECT_EQ(kTestNumberOfPackets, receiver_.sequence_numbers_.size()); | 338 EXPECT_EQ(kTestNumberOfPackets, receiver_.sequence_numbers_.size()); |
340 EXPECT_EQ(kTestNumberOfRtxPackets, transport_.count_rtx_ssrc_); | 339 EXPECT_EQ(kTestNumberOfRtxPackets, transport_.count_rtx_ssrc_); |
341 EXPECT_TRUE(ExpectedPacketsReceived()); | 340 EXPECT_TRUE(ExpectedPacketsReceived()); |
342 } | 341 } |
343 | 342 |
344 } // namespace webrtc | 343 } // namespace webrtc |
OLD | NEW |