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

Unified Diff: webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc

Issue 2368983002: Replace RtcpReceiveTimeInfo with rtcp::ReceiveTimeInfo (Closed)
Patch Set: Rebase Created 4 years, 3 months 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 | « webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc ('k') | webrtc/modules/rtp_rtcp/source/rtcp_sender.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc
diff --git a/webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc b/webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc
index 6f8fe45e3168c2004e543a3b143209fad614a721..6a393cd785f117a579ead4b66dc0bb5c017df9c7 100644
--- a/webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc
@@ -719,19 +719,19 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsReceiverReferenceTimePacket) {
xr.SetSenderSsrc(kSenderSsrc);
xr.AddRrtr(rrtr);
- RtcpReceiveTimeInfo rrtime;
+ rtcp::ReceiveTimeInfo rrtime;
EXPECT_FALSE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&rrtime));
InjectRtcpPacket(xr);
EXPECT_TRUE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&rrtime));
- EXPECT_EQ(rrtime.sourceSSRC, kSenderSsrc);
- EXPECT_EQ(rrtime.lastRR, CompactNtp(kNtp));
- EXPECT_EQ(0u, rrtime.delaySinceLastRR);
+ EXPECT_EQ(rrtime.ssrc, kSenderSsrc);
+ EXPECT_EQ(rrtime.last_rr, CompactNtp(kNtp));
+ EXPECT_EQ(0U, rrtime.delay_since_last_rr);
system_clock_.AdvanceTimeMilliseconds(1500);
EXPECT_TRUE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&rrtime));
- EXPECT_NEAR(1500, CompactNtpRttToMs(rrtime.delaySinceLastRR), 1);
+ EXPECT_NEAR(1500, CompactNtpRttToMs(rrtime.delay_since_last_rr), 1);
}
TEST_F(RtcpReceiverTest, ExtendedReportsDlrrPacketNotToUsIgnored) {
@@ -809,7 +809,7 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsPacketWithMultipleReportBlocks) {
InjectRtcpPacket(xr);
- RtcpReceiveTimeInfo rrtime;
+ rtcp::ReceiveTimeInfo rrtime;
EXPECT_TRUE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&rrtime));
int64_t rtt_ms = 0;
EXPECT_TRUE(rtcp_receiver_.GetAndResetXrRrRtt(&rtt_ms));
@@ -836,7 +836,7 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsPacketWithUnknownReportBlock) {
InjectRtcpPacket(packet);
// Validate Rrtr was received and processed.
- RtcpReceiveTimeInfo rrtime;
+ rtcp::ReceiveTimeInfo rrtime;
EXPECT_TRUE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&rrtime));
// Validate Dlrr report wasn't processed.
int64_t rtt_ms = 0;
@@ -897,7 +897,7 @@ TEST_F(RtcpReceiverTest, XrDlrrCalculatesNegativeRttAsOne) {
}
TEST_F(RtcpReceiverTest, LastReceivedXrReferenceTimeInfoInitiallyFalse) {
- RtcpReceiveTimeInfo info;
+ rtcp::ReceiveTimeInfo info;
EXPECT_FALSE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&info));
}
@@ -913,15 +913,15 @@ TEST_F(RtcpReceiverTest, GetLastReceivedExtendedReportsReferenceTimeInfo) {
InjectRtcpPacket(xr);
- RtcpReceiveTimeInfo info;
+ rtcp::ReceiveTimeInfo info;
EXPECT_TRUE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&info));
- EXPECT_EQ(kSenderSsrc, info.sourceSSRC);
- EXPECT_EQ(kNtpMid, info.lastRR);
- EXPECT_EQ(0U, info.delaySinceLastRR);
+ EXPECT_EQ(kSenderSsrc, info.ssrc);
+ EXPECT_EQ(kNtpMid, info.last_rr);
+ EXPECT_EQ(0U, info.delay_since_last_rr);
system_clock_.AdvanceTimeMilliseconds(1000);
EXPECT_TRUE(rtcp_receiver_.LastReceivedXrReferenceTimeInfo(&info));
- EXPECT_EQ(65536U, info.delaySinceLastRR);
+ EXPECT_EQ(65536U, info.delay_since_last_rr);
}
TEST_F(RtcpReceiverTest, ReceiveReportTimeout) {
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc ('k') | webrtc/modules/rtp_rtcp/source/rtcp_sender.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698