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

Side by Side Diff: webrtc/modules/rtp_rtcp/test/testAPI/test_api_video.cc

Issue 1335353005: Remove channel ids from various interfaces. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebase Created 5 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 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 15 matching lines...) Expand all
26 26
27 const unsigned char kPayloadType = 100; 27 const unsigned char kPayloadType = 100;
28 28
29 }; 29 };
30 30
31 namespace webrtc { 31 namespace webrtc {
32 32
33 class RtpRtcpVideoTest : public ::testing::Test { 33 class RtpRtcpVideoTest : public ::testing::Test {
34 protected: 34 protected:
35 RtpRtcpVideoTest() 35 RtpRtcpVideoTest()
36 : test_id_(123), 36 : rtp_payload_registry_(RTPPayloadStrategy::CreateStrategy(false)),
37 rtp_payload_registry_(RTPPayloadStrategy::CreateStrategy(false)),
38 test_ssrc_(3456), 37 test_ssrc_(3456),
39 test_timestamp_(4567), 38 test_timestamp_(4567),
40 test_sequence_number_(2345), 39 test_sequence_number_(2345),
41 fake_clock(123456) { 40 fake_clock(123456) {}
42 }
43 ~RtpRtcpVideoTest() {} 41 ~RtpRtcpVideoTest() {}
44 42
45 virtual void SetUp() { 43 virtual void SetUp() {
46 transport_ = new LoopBackTransport(); 44 transport_ = new LoopBackTransport();
47 receiver_ = new TestRtpReceiver(); 45 receiver_ = new TestRtpReceiver();
48 receive_statistics_.reset(ReceiveStatistics::Create(&fake_clock)); 46 receive_statistics_.reset(ReceiveStatistics::Create(&fake_clock));
49 RtpRtcp::Configuration configuration; 47 RtpRtcp::Configuration configuration;
50 configuration.id = test_id_;
51 configuration.audio = false; 48 configuration.audio = false;
52 configuration.clock = &fake_clock; 49 configuration.clock = &fake_clock;
53 configuration.outgoing_transport = transport_; 50 configuration.outgoing_transport = transport_;
54 51
55 video_module_ = RtpRtcp::CreateRtpRtcp(configuration); 52 video_module_ = RtpRtcp::CreateRtpRtcp(configuration);
56 rtp_receiver_.reset(RtpReceiver::CreateVideoReceiver( 53 rtp_receiver_.reset(RtpReceiver::CreateVideoReceiver(
57 test_id_, &fake_clock, receiver_, NULL, &rtp_payload_registry_)); 54 &fake_clock, receiver_, NULL, &rtp_payload_registry_));
58 55
59 video_module_->SetRTCPStatus(kRtcpCompound); 56 video_module_->SetRTCPStatus(kRtcpCompound);
60 video_module_->SetSSRC(test_ssrc_); 57 video_module_->SetSSRC(test_ssrc_);
61 rtp_receiver_->SetNACKStatus(kNackRtcp); 58 rtp_receiver_->SetNACKStatus(kNackRtcp);
62 video_module_->SetStorePacketsStatus(true, 600); 59 video_module_->SetStorePacketsStatus(true, 600);
63 EXPECT_EQ(0, video_module_->SetSendingStatus(true)); 60 EXPECT_EQ(0, video_module_->SetSendingStatus(true));
64 61
65 transport_->SetSendModule(video_module_, &rtp_payload_registry_, 62 transport_->SetSendModule(video_module_, &rtp_payload_registry_,
66 rtp_receiver_.get(), receive_statistics_.get()); 63 rtp_receiver_.get(), receive_statistics_.get());
67 64
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 payload_specific, true)); 182 payload_specific, true));
186 EXPECT_EQ(0u, receiver_->payload_size()); 183 EXPECT_EQ(0u, receiver_->payload_size());
187 EXPECT_EQ(payload_length, receiver_->rtp_header().header.paddingLength); 184 EXPECT_EQ(payload_length, receiver_->rtp_header().header.paddingLength);
188 } 185 }
189 timestamp += 3000; 186 timestamp += 3000;
190 fake_clock.AdvanceTimeMilliseconds(33); 187 fake_clock.AdvanceTimeMilliseconds(33);
191 } 188 }
192 } 189 }
193 190
194 } // namespace webrtc 191 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/rtp_rtcp/test/testAPI/test_api_rtcp.cc ('k') | webrtc/modules/video_coding/main/test/rtp_player.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698