| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 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 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 0, 1); | 117 0, 1); |
| 118 params.codecs.push_back(kTelephoneEventCodec); | 118 params.codecs.push_back(kTelephoneEventCodec); |
| 119 voice_media_channel_->SetSendParameters(params); | 119 voice_media_channel_->SetSendParameters(params); |
| 120 } | 120 } |
| 121 | 121 |
| 122 void AddVideoTrack() { AddVideoTrack(false); } | 122 void AddVideoTrack() { AddVideoTrack(false); } |
| 123 | 123 |
| 124 void AddVideoTrack(bool is_screencast) { | 124 void AddVideoTrack(bool is_screencast) { |
| 125 rtc::scoped_refptr<VideoTrackSourceInterface> source( | 125 rtc::scoped_refptr<VideoTrackSourceInterface> source( |
| 126 FakeVideoTrackSource::Create(is_screencast)); | 126 FakeVideoTrackSource::Create(is_screencast)); |
| 127 video_track_ = | 127 video_track_ = VideoTrack::Create(kVideoTrackId, source); |
| 128 VideoTrack::Create(kVideoTrackId, source, rtc::Thread::Current()); | |
| 129 EXPECT_TRUE(local_stream_->AddTrack(video_track_)); | 128 EXPECT_TRUE(local_stream_->AddTrack(video_track_)); |
| 130 } | 129 } |
| 131 | 130 |
| 132 void CreateAudioRtpSender() { CreateAudioRtpSender(nullptr); } | 131 void CreateAudioRtpSender() { CreateAudioRtpSender(nullptr); } |
| 133 | 132 |
| 134 void CreateAudioRtpSender(rtc::scoped_refptr<LocalAudioSource> source) { | 133 void CreateAudioRtpSender(rtc::scoped_refptr<LocalAudioSource> source) { |
| 135 audio_track_ = AudioTrack::Create(kAudioTrackId, source); | 134 audio_track_ = AudioTrack::Create(kAudioTrackId, source); |
| 136 EXPECT_TRUE(local_stream_->AddTrack(audio_track_)); | 135 EXPECT_TRUE(local_stream_->AddTrack(audio_track_)); |
| 137 audio_rtp_sender_ = | 136 audio_rtp_sender_ = |
| 138 new AudioRtpSender(local_stream_->GetAudioTracks()[0], | 137 new AudioRtpSender(local_stream_->GetAudioTracks()[0], |
| (...skipping 654 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 793 // Make sure the signal from "GetOnDestroyedSignal()" fires when the sender is | 792 // Make sure the signal from "GetOnDestroyedSignal()" fires when the sender is |
| 794 // destroyed, which is needed for the DTMF sender. | 793 // destroyed, which is needed for the DTMF sender. |
| 795 TEST_F(RtpSenderReceiverTest, TestOnDestroyedSignal) { | 794 TEST_F(RtpSenderReceiverTest, TestOnDestroyedSignal) { |
| 796 CreateAudioRtpSender(); | 795 CreateAudioRtpSender(); |
| 797 EXPECT_FALSE(audio_sender_destroyed_signal_fired_); | 796 EXPECT_FALSE(audio_sender_destroyed_signal_fired_); |
| 798 audio_rtp_sender_ = nullptr; | 797 audio_rtp_sender_ = nullptr; |
| 799 EXPECT_TRUE(audio_sender_destroyed_signal_fired_); | 798 EXPECT_TRUE(audio_sender_destroyed_signal_fired_); |
| 800 } | 799 } |
| 801 | 800 |
| 802 } // namespace webrtc | 801 } // namespace webrtc |
| OLD | NEW |