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

Unified Diff: content/renderer/media/video_capture_message_filter_unittest.cc

Issue 500653003: Video capture frame size: separate coded size and visible size. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix content_unittests build. Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/media/video_capture_message_filter.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/video_capture_message_filter_unittest.cc
diff --git a/content/renderer/media/video_capture_message_filter_unittest.cc b/content/renderer/media/video_capture_message_filter_unittest.cc
index 742de87e14f538ff3ad6190e6d64ee90bfc17dd6..4030ba749ab63ffb34e50893969c1268618e297d 100644
--- a/content/renderer/media/video_capture_message_filter_unittest.cc
+++ b/content/renderer/media/video_capture_message_filter_unittest.cc
@@ -29,9 +29,10 @@ class MockVideoCaptureDelegate : public VideoCaptureMessageFilter::Delegate {
int length,
int buffer_id));
MOCK_METHOD1(OnBufferDestroyed, void(int buffer_id));
- MOCK_METHOD3(OnBufferReceived,
+ MOCK_METHOD4(OnBufferReceived,
void(int buffer_id,
const media::VideoCaptureFormat& format,
+ const gfx::Rect& visible_rect,
base::TimeTicks timestamp));
MOCK_METHOD4(OnMailboxBufferReceived,
void(int buffer_id,
@@ -94,10 +95,11 @@ TEST(VideoCaptureMessageFilterTest, Basic) {
const media::VideoCaptureFormat shm_format(
gfx::Size(234, 512), 30, media::PIXEL_FORMAT_I420);
media::VideoCaptureFormat saved_format;
- EXPECT_CALL(delegate, OnBufferReceived(buffer_id, _, timestamp))
+ EXPECT_CALL(delegate, OnBufferReceived(buffer_id, _, _, timestamp))
.WillRepeatedly(SaveArg<1>(&saved_format));
filter->OnMessageReceived(VideoCaptureMsg_BufferReady(
- delegate.device_id(), buffer_id, shm_format, timestamp));
+ delegate.device_id(), buffer_id, shm_format, gfx::Rect(234, 512),
+ timestamp));
Mock::VerifyAndClearExpectations(&delegate);
EXPECT_EQ(shm_format.frame_size, saved_format.frame_size);
EXPECT_EQ(shm_format.frame_rate, saved_format.frame_rate);
« no previous file with comments | « content/renderer/media/video_capture_message_filter.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698