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

Unified Diff: webrtc/modules/rtp_rtcp/test/testAPI/test_api_audio.cc

Issue 2089773002: Add EncodedImageCallback::OnEncodedImage(). (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: . Created 4 years, 4 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/test/testAPI/test_api_audio.cc
diff --git a/webrtc/modules/rtp_rtcp/test/testAPI/test_api_audio.cc b/webrtc/modules/rtp_rtcp/test/testAPI/test_api_audio.cc
index f9e50015872604ca6a7d6fd6e2939a586db87fa0..4bbcc326e9a86f0d0743c116693c33b6c0b9a063 100644
--- a/webrtc/modules/rtp_rtcp/test/testAPI/test_api_audio.cc
+++ b/webrtc/modules/rtp_rtcp/test/testAPI/test_api_audio.cc
@@ -171,8 +171,9 @@ TEST_F(RtpRtcpAudioTest, Basic) {
// Send an empty RTP packet.
// Should fail since we have not registered the payload type.
- EXPECT_EQ(-1, module1->SendOutgoingData(webrtc::kAudioFrameSpeech,
- 96, 0, -1, NULL, 0));
+ EXPECT_FALSE(module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96, 0, -1,
+ nullptr, 0, nullptr, nullptr,
+ nullptr));
CodecInst voice_codec;
memset(&voice_codec, 0, sizeof(voice_codec));
@@ -197,8 +198,9 @@ TEST_F(RtpRtcpAudioTest, Basic) {
(voice_codec.rate < 0) ? 0 : voice_codec.rate));
const uint8_t test[5] = "test";
- EXPECT_EQ(0, module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96,
- 0, -1, test, 4));
+ EXPECT_EQ(true,
+ module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96, 0, -1,
+ test, 4, nullptr, nullptr, nullptr));
EXPECT_EQ(test_ssrc, rtp_receiver2_->SSRC());
uint32_t timestamp;
@@ -271,9 +273,9 @@ TEST_F(RtpRtcpAudioTest, RED) {
const uint8_t test[5] = "test";
// Send a RTP packet.
- EXPECT_EQ(0, module1->SendOutgoingData(webrtc::kAudioFrameSpeech,
- 96, 160, -1, test, 4,
- &fragmentation));
+ EXPECT_TRUE(module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96, 160, -1,
+ test, 4, &fragmentation, nullptr,
+ nullptr));
EXPECT_EQ(0, module1->SetSendREDPayloadType(-1));
EXPECT_EQ(-1, module1->SendREDPayloadType(&red));
@@ -333,16 +335,18 @@ TEST_F(RtpRtcpAudioTest, DTMF) {
// Send RTP packets for 16 tones a 160 ms 100ms
// pause between = 2560ms + 1600ms = 4160ms
for (; timeStamp <= 250 * 160; timeStamp += 160) {
- EXPECT_EQ(0, module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96,
- timeStamp, -1, test, 4));
+ EXPECT_TRUE(module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96,
+ timeStamp, -1, test, 4, nullptr,
+ nullptr, nullptr));
fake_clock.AdvanceTimeMilliseconds(20);
module1->Process();
}
EXPECT_EQ(0, module1->SendTelephoneEventOutband(32, 9000, 10));
for (; timeStamp <= 740 * 160; timeStamp += 160) {
- EXPECT_EQ(0, module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96,
- timeStamp, -1, test, 4));
+ EXPECT_TRUE(module1->SendOutgoingData(webrtc::kAudioFrameSpeech, 96,
+ timeStamp, -1, test, 4, nullptr,
+ nullptr, nullptr));
fake_clock.AdvanceTimeMilliseconds(20);
module1->Process();
}
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc ('k') | webrtc/modules/rtp_rtcp/test/testAPI/test_api_rtcp.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698