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

Side by Side Diff: content/renderer/media/media_stream_video_renderer_sink_unittest.cc

Issue 2972553002: Remove MediaStreamVideoSource::GetCurrentSupportedFormats() (Closed)
Patch Set: remove extra use in media_stream_video_capturer_source_unittest.cc Created 3 years, 5 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 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/media/media_stream_video_renderer_sink.h" 5 #include "content/renderer/media/media_stream_video_renderer_sink.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 22 matching lines...) Expand all
33 namespace content { 33 namespace content {
34 34
35 ACTION_P(RunClosure, closure) { 35 ACTION_P(RunClosure, closure) {
36 closure.Run(); 36 closure.Run();
37 } 37 }
38 38
39 class MediaStreamVideoRendererSinkTest : public testing::Test { 39 class MediaStreamVideoRendererSinkTest : public testing::Test {
40 public: 40 public:
41 MediaStreamVideoRendererSinkTest() 41 MediaStreamVideoRendererSinkTest()
42 : child_process_(new ChildProcess()), 42 : child_process_(new ChildProcess()),
43 mock_source_(new MockMediaStreamVideoSource(false)) { 43 mock_source_(new MockMediaStreamVideoSource()) {
44 blink_source_.Initialize(blink::WebString::FromASCII("dummy_source_id"), 44 blink_source_.Initialize(blink::WebString::FromASCII("dummy_source_id"),
45 blink::WebMediaStreamSource::kTypeVideo, 45 blink::WebMediaStreamSource::kTypeVideo,
46 blink::WebString::FromASCII("dummy_source_name"), 46 blink::WebString::FromASCII("dummy_source_name"),
47 false /* remote */); 47 false /* remote */);
48 blink_source_.SetExtraData(mock_source_); 48 blink_source_.SetExtraData(mock_source_);
49 blink_track_ = MediaStreamVideoTrack::CreateVideoTrack( 49 blink_track_ = MediaStreamVideoTrack::CreateVideoTrack(
50 mock_source_, MediaStreamSource::ConstraintsCallback(), true); 50 mock_source_, MediaStreamSource::ConstraintsCallback(), true);
51 mock_source_->StartMockedSource(); 51 mock_source_->StartMockedSource();
52 base::RunLoop().RunUntilIdle(); 52 base::RunLoop().RunUntilIdle();
53 53
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 const scoped_refptr<media::VideoFrame> video_frame = 223 const scoped_refptr<media::VideoFrame> video_frame =
224 media::VideoFrame::CreateFrame(media::PIXEL_FORMAT_YV12A, kSize, 224 media::VideoFrame::CreateFrame(media::PIXEL_FORMAT_YV12A, kSize,
225 gfx::Rect(kSize), kSize, kTimestamp); 225 gfx::Rect(kSize), kSize, kTimestamp);
226 OnVideoFrame(video_frame); 226 OnVideoFrame(video_frame);
227 base::RunLoop().RunUntilIdle(); 227 base::RunLoop().RunUntilIdle();
228 228
229 media_stream_video_renderer_sink_->Stop(); 229 media_stream_video_renderer_sink_->Stop();
230 } 230 }
231 231
232 } // namespace content 232 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698