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

Side by Side Diff: webrtc/video/end_to_end_tests.cc

Issue 2542413002: Generalize FlexfecReceiveStream::Config. (CL1) (Closed)
Patch Set: Rebase. Created 4 years 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 unified diff | Download patch
« no previous file with comments | « webrtc/test/call_test.cc ('k') | webrtc/video/video_quality_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include <algorithm> 10 #include <algorithm>
(...skipping 3837 matching lines...) Expand 10 before | Expand all | Expand 10 after
3848 << "Enabling ULPFEC requires rtpmap: ulpfec negotiation."; 3848 << "Enabling ULPFEC requires rtpmap: ulpfec negotiation.";
3849 EXPECT_EQ(-1, config.red_payload_type) 3849 EXPECT_EQ(-1, config.red_payload_type)
3850 << "Enabling ULPFEC requires rtpmap: red negotiation."; 3850 << "Enabling ULPFEC requires rtpmap: red negotiation.";
3851 EXPECT_EQ(-1, config.red_rtx_payload_type) 3851 EXPECT_EQ(-1, config.red_rtx_payload_type)
3852 << "Enabling RTX in ULPFEC requires rtpmap: rtx negotiation."; 3852 << "Enabling RTX in ULPFEC requires rtpmap: rtx negotiation.";
3853 } 3853 }
3854 3854
3855 void VerifyEmptyFlexfecConfig(const FlexfecConfig& config) { 3855 void VerifyEmptyFlexfecConfig(const FlexfecConfig& config) {
3856 EXPECT_EQ(-1, config.flexfec_payload_type) 3856 EXPECT_EQ(-1, config.flexfec_payload_type)
3857 << "Enabling FlexFEC requires rtpmap: flexfec negotiation."; 3857 << "Enabling FlexFEC requires rtpmap: flexfec negotiation.";
3858 EXPECT_EQ(0U, config.flexfec_ssrc)
3859 << "Enabling FlexFEC requires ssrc-group: FEC-FR negotiation.";
3858 EXPECT_TRUE(config.protected_media_ssrcs.empty()) 3860 EXPECT_TRUE(config.protected_media_ssrcs.empty())
3859 << "Enabling FlexFEC requires ssrc-group: FEC-FR negotiation."; 3861 << "Enabling FlexFEC requires ssrc-group: FEC-FR negotiation.";
3860 } 3862 }
3861 3863
3862 TEST_P(EndToEndTest, VerifyDefaultSendConfigParameters) { 3864 TEST_P(EndToEndTest, VerifyDefaultSendConfigParameters) {
3863 VideoSendStream::Config default_send_config(nullptr); 3865 VideoSendStream::Config default_send_config(nullptr);
3864 EXPECT_EQ(0, default_send_config.rtp.nack.rtp_history_ms) 3866 EXPECT_EQ(0, default_send_config.rtp.nack.rtp_history_ms)
3865 << "Enabling NACK require rtcp-fb: nack negotiation."; 3867 << "Enabling NACK require rtcp-fb: nack negotiation.";
3866 EXPECT_TRUE(default_send_config.rtp.rtx.ssrcs.empty()) 3868 EXPECT_TRUE(default_send_config.rtp.rtx.ssrcs.empty())
3867 << "Enabling RTX requires rtpmap: rtx negotiation."; 3869 << "Enabling RTX requires rtpmap: rtx negotiation.";
(...skipping 18 matching lines...) Expand all
3886 << "Enabling RTX requires rtpmap: rtx negotiation."; 3888 << "Enabling RTX requires rtpmap: rtx negotiation.";
3887 EXPECT_TRUE(default_receive_config.rtp.extensions.empty()) 3889 EXPECT_TRUE(default_receive_config.rtp.extensions.empty())
3888 << "Enabling RTP extensions require negotiation."; 3890 << "Enabling RTP extensions require negotiation.";
3889 3891
3890 VerifyEmptyNackConfig(default_receive_config.rtp.nack); 3892 VerifyEmptyNackConfig(default_receive_config.rtp.nack);
3891 VerifyEmptyUlpfecConfig(default_receive_config.rtp.ulpfec); 3893 VerifyEmptyUlpfecConfig(default_receive_config.rtp.ulpfec);
3892 } 3894 }
3893 3895
3894 TEST_P(EndToEndTest, VerifyDefaultFlexfecReceiveConfigParameters) { 3896 TEST_P(EndToEndTest, VerifyDefaultFlexfecReceiveConfigParameters) {
3895 FlexfecReceiveStream::Config default_receive_config; 3897 FlexfecReceiveStream::Config default_receive_config;
3896 VerifyEmptyFlexfecConfig(default_receive_config); 3898 EXPECT_EQ(-1, default_receive_config.payload_type)
3899 << "Enabling FlexFEC requires rtpmap: flexfec negotiation.";
3900 EXPECT_EQ(0U, default_receive_config.remote_ssrc)
3901 << "Enabling FlexFEC requires ssrc-group: FEC-FR negotiation.";
3902 EXPECT_TRUE(default_receive_config.protected_media_ssrcs.empty())
3903 << "Enabling FlexFEC requires ssrc-group: FEC-FR negotiation.";
3897 } 3904 }
3898 3905
3899 TEST_P(EndToEndTest, TransportSeqNumOnAudioAndVideo) { 3906 TEST_P(EndToEndTest, TransportSeqNumOnAudioAndVideo) {
3900 static const int kExtensionId = 8; 3907 static const int kExtensionId = 8;
3901 class TransportSequenceNumberTest : public test::EndToEndTest { 3908 class TransportSequenceNumberTest : public test::EndToEndTest {
3902 public: 3909 public:
3903 TransportSequenceNumberTest() 3910 TransportSequenceNumberTest()
3904 : EndToEndTest(kDefaultTimeoutMs), 3911 : EndToEndTest(kDefaultTimeoutMs),
3905 video_observed_(false), 3912 video_observed_(false),
3906 audio_observed_(false) { 3913 audio_observed_(false) {
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
4063 std::unique_ptr<VideoEncoder> encoder_; 4070 std::unique_ptr<VideoEncoder> encoder_;
4064 std::unique_ptr<VideoDecoder> decoder_; 4071 std::unique_ptr<VideoDecoder> decoder_;
4065 rtc::CriticalSection crit_; 4072 rtc::CriticalSection crit_;
4066 int recorded_frames_ GUARDED_BY(crit_); 4073 int recorded_frames_ GUARDED_BY(crit_);
4067 } test(this); 4074 } test(this);
4068 4075
4069 RunBaseTest(&test); 4076 RunBaseTest(&test);
4070 } 4077 }
4071 4078
4072 } // namespace webrtc 4079 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/test/call_test.cc ('k') | webrtc/video/video_quality_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698