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

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

Issue 1747593002: Change the type for byte counts to size_t in WebMediaPlayer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Made changes in the unittests Created 4 years, 9 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 "base/memory/weak_ptr.h" 5 #include "base/memory/weak_ptr.h"
6 #include "base/run_loop.h" 6 #include "base/run_loop.h"
7 #include "base/thread_task_runner_handle.h" 7 #include "base/thread_task_runner_handle.h"
8 #include "content/renderer/media/html_video_element_capturer_source.h" 8 #include "content/renderer/media/html_video_element_capturer_source.h"
9 #include "media/base/limits.h" 9 #include "media/base/limits.h"
10 #include "testing/gmock/include/gmock/gmock.h" 10 #include "testing/gmock/include/gmock/gmock.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 ReadyState readyState() const override { 60 ReadyState readyState() const override {
61 return ReadyStateHaveNothing; 61 return ReadyStateHaveNothing;
62 } 62 }
63 bool didLoadingProgress() override { return true; } 63 bool didLoadingProgress() override { return true; }
64 bool hasSingleSecurityOrigin() const override { return true; } 64 bool hasSingleSecurityOrigin() const override { return true; }
65 bool didPassCORSAccessCheck() const override { return true; } 65 bool didPassCORSAccessCheck() const override { return true; }
66 double mediaTimeForTimeValue(double timeValue) const override { return 0.0; } 66 double mediaTimeForTimeValue(double timeValue) const override { return 0.0; }
67 unsigned decodedFrameCount() const override { return 0; } 67 unsigned decodedFrameCount() const override { return 0; }
68 unsigned droppedFrameCount() const override { return 0; } 68 unsigned droppedFrameCount() const override { return 0; }
69 unsigned corruptedFrameCount() const override { return 0; } 69 unsigned corruptedFrameCount() const override { return 0; }
70 unsigned audioDecodedByteCount() const override { return 0; } 70 size_t audioDecodedByteCount() const override { return 0; }
71 unsigned videoDecodedByteCount() const override { return 0; } 71 size_t videoDecodedByteCount() const override { return 0; }
72 72
73 void paint(blink::WebCanvas* canvas, 73 void paint(blink::WebCanvas* canvas,
74 const blink::WebRect& paint_rectangle, 74 const blink::WebRect& paint_rectangle,
75 unsigned char alpha, 75 unsigned char alpha,
76 SkXfermode::Mode mode) override { 76 SkXfermode::Mode mode) override {
77 // We could fill in |canvas| with a meaningful pattern in ARGB and verify 77 // We could fill in |canvas| with a meaningful pattern in ARGB and verify
78 // that is correctly captured (as I420) by HTMLVideoElementCapturerSource 78 // that is correctly captured (as I420) by HTMLVideoElementCapturerSource
79 // but I don't think that'll be easy/useful/robust, so just let go here. 79 // but I don't think that'll be easy/useful/robust, so just let go here.
80 return; 80 return;
81 } 81 }
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 base::Bind(&HTMLVideoElementCapturerSourceTest::OnRunning, 160 base::Bind(&HTMLVideoElementCapturerSourceTest::OnRunning,
161 base::Unretained(this))); 161 base::Unretained(this)));
162 162
163 run_loop.Run(); 163 run_loop.Run();
164 164
165 html_video_capturer_->StopCapture(); 165 html_video_capturer_->StopCapture();
166 Mock::VerifyAndClearExpectations(this); 166 Mock::VerifyAndClearExpectations(this);
167 } 167 }
168 168
169 } // namespace content 169 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/media/android/webmediaplayer_android.cc ('k') | content/renderer/media/webmediaplayer_ms.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698