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

Side by Side Diff: webrtc/media/base/videoengine_unittest.h

Issue 2458863002: Start probes only after network is connected. (Closed)
Patch Set: sync 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/call/call.cc ('k') | webrtc/media/engine/webrtcvideoengine2_unittest.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) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 virtual cricket::VideoCodec DefaultCodec() = 0; 77 virtual cricket::VideoCodec DefaultCodec() = 0;
78 78
79 virtual cricket::StreamParams DefaultSendStreamParams() { 79 virtual cricket::StreamParams DefaultSendStreamParams() {
80 return cricket::StreamParams::CreateLegacy(kSsrc); 80 return cricket::StreamParams::CreateLegacy(kSsrc);
81 } 81 }
82 82
83 virtual void SetUp() { 83 virtual void SetUp() {
84 engine_.Init(); 84 engine_.Init();
85 channel_.reset(engine_.CreateChannel(call_.get(), cricket::MediaConfig(), 85 channel_.reset(engine_.CreateChannel(call_.get(), cricket::MediaConfig(),
86 cricket::VideoOptions())); 86 cricket::VideoOptions()));
87 channel_->OnReadyToSend(true);
87 EXPECT_TRUE(channel_.get() != NULL); 88 EXPECT_TRUE(channel_.get() != NULL);
88 network_interface_.SetDestination(channel_.get()); 89 network_interface_.SetDestination(channel_.get());
89 channel_->SetInterface(&network_interface_); 90 channel_->SetInterface(&network_interface_);
90 media_error_ = cricket::VideoMediaChannel::ERROR_NONE; 91 media_error_ = cricket::VideoMediaChannel::ERROR_NONE;
91 cricket::VideoRecvParameters parameters; 92 cricket::VideoRecvParameters parameters;
92 parameters.codecs = engine_.codecs(); 93 parameters.codecs = engine_.codecs();
93 channel_->SetRecvParameters(parameters); 94 channel_->SetRecvParameters(parameters);
94 EXPECT_TRUE(channel_->AddSendStream(DefaultSendStreamParams())); 95 EXPECT_TRUE(channel_->AddSendStream(DefaultSendStreamParams()));
95 video_capturer_.reset(CreateFakeVideoCapturer()); 96 video_capturer_.reset(CreateFakeVideoCapturer());
96 cricket::VideoFormat format(640, 480, 97 cricket::VideoFormat format(640, 480,
(...skipping 842 matching lines...) Expand 10 before | Expand all | Expand 10 after
939 std::unique_ptr<C> channel_; 940 std::unique_ptr<C> channel_;
940 cricket::FakeNetworkInterface network_interface_; 941 cricket::FakeNetworkInterface network_interface_;
941 cricket::FakeVideoRenderer renderer_; 942 cricket::FakeVideoRenderer renderer_;
942 cricket::VideoMediaChannel::Error media_error_; 943 cricket::VideoMediaChannel::Error media_error_;
943 944
944 // Used by test cases where 2 streams are run on the same channel. 945 // Used by test cases where 2 streams are run on the same channel.
945 cricket::FakeVideoRenderer renderer2_; 946 cricket::FakeVideoRenderer renderer2_;
946 }; 947 };
947 948
948 #endif // WEBRTC_MEDIA_BASE_VIDEOENGINE_UNITTEST_H_ NOLINT 949 #endif // WEBRTC_MEDIA_BASE_VIDEOENGINE_UNITTEST_H_ NOLINT
OLDNEW
« no previous file with comments | « webrtc/call/call.cc ('k') | webrtc/media/engine/webrtcvideoengine2_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698