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

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

Issue 1557593002: [rtp_rtcp] rtcp::ExtenededReports packet got Parse function (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebase & fix win compile errors Created 4 years, 11 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
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 7ec10bdb29f769f58cd1399f33d5d38c4bb1863c..e0c70c2b5cd08a1f5c61581cede0c8df7cbef4f4 100644
--- a/webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtcp_receiver_unittest.cc
@@ -602,7 +602,7 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsVoipPacket) {
voip_metric.WithVoipMetric(metric);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithVoipMetric(&voip_metric);
+ xr.WithVoipMetric(voip_metric);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
ASSERT_TRUE(rtcp_packet_info_.VoIPMetric != nullptr);
@@ -620,7 +620,7 @@ TEST_F(RtcpReceiverTest, ExtendedReportsVoipPacketNotToUsIgnored) {
voip_metric.To(kSourceSsrc + 1);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithVoipMetric(&voip_metric);
+ xr.WithVoipMetric(voip_metric);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
EXPECT_EQ(0U, rtcp_packet_info_.rtcpPacketTypeFlags);
@@ -631,7 +631,7 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsReceiverReferenceTimePacket) {
rrtr.WithNtp(NtpTime(0x10203, 0x40506));
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithRrtr(&rrtr);
+ xr.WithRrtr(rrtr);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
@@ -649,7 +649,7 @@ TEST_F(RtcpReceiverTest, ExtendedReportsDlrrPacketNotToUsIgnored) {
dlrr.WithDlrrItem(kSourceSsrc + 1, 0x12345, 0x67890);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithDlrr(&dlrr);
+ xr.WithDlrr(dlrr);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
EXPECT_EQ(0U, rtcp_packet_info_.rtcpPacketTypeFlags);
@@ -666,7 +666,7 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsDlrrPacketWithSubBlock) {
dlrr.WithDlrrItem(kSourceSsrc, 0x12345, 0x67890);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithDlrr(&dlrr);
+ xr.WithDlrr(dlrr);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
// The parser should note the DLRR report block item, but not flag the packet
@@ -686,7 +686,7 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsDlrrPacketWithMultipleSubBlocks) {
dlrr.WithDlrrItem(kSourceSsrc, 0x12345, 0x67890);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithDlrr(&dlrr);
+ xr.WithDlrr(dlrr);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
// The parser should note the DLRR report block item, but not flag the packet
@@ -707,9 +707,9 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsPacketWithMultipleReportBlocks) {
metric.To(kSourceSsrc);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithRrtr(&rrtr);
- xr.WithDlrr(&dlrr);
- xr.WithVoipMetric(&metric);
+ xr.WithRrtr(rrtr);
+ xr.WithDlrr(dlrr);
+ xr.WithVoipMetric(metric);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
EXPECT_EQ(static_cast<unsigned int>(kRtcpXrReceiverReferenceTime +
@@ -735,9 +735,9 @@ TEST_F(RtcpReceiverTest, InjectExtendedReportsPacketWithUnknownReportBlock) {
metric.To(kSourceSsrc);
rtcp::ExtendedReports xr;
xr.From(0x2345);
- xr.WithRrtr(&rrtr);
- xr.WithDlrr(&dlrr);
- xr.WithVoipMetric(&metric);
+ xr.WithRrtr(rrtr);
+ xr.WithDlrr(dlrr);
+ xr.WithVoipMetric(metric);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
// Modify the DLRR block to have an unsupported block type, from 5 to 6.
uint8_t* buffer = const_cast<uint8_t*>(packet->Buffer());
@@ -771,7 +771,7 @@ TEST_F(RtcpReceiverTest, GetLastReceivedExtendedReportsReferenceTimeInfo) {
rrtr.WithNtp(kNtp);
rtcp::ExtendedReports xr;
xr.From(kSenderSsrc);
- xr.WithRrtr(&rrtr);
+ xr.WithRrtr(rrtr);
rtc::scoped_ptr<rtcp::RawPacket> packet(xr.Build());
EXPECT_EQ(0, InjectRtcpPacket(packet->Buffer(), packet->Length()));
EXPECT_EQ(kRtcpXrReceiverReferenceTime,
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtcp_packet/extended_reports_unittest.cc ('k') | webrtc/modules/rtp_rtcp/source/rtcp_sender.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698