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

Side by Side Diff: content/browser/renderer_host/media/video_capture_manager_unittest.cc

Issue 2673373003: getUserMeida: report device starting states (Closed)
Patch Set: rebase to Feb 10 Created 3 years, 10 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Unit test for VideoCaptureManager. 5 // Unit test for VideoCaptureManager.
6 6
7 #include "content/browser/renderer_host/media/video_capture_manager.h" 7 #include "content/browser/renderer_host/media/video_capture_manager.h"
8 8
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 130
131 MOCK_METHOD2(Opened, void(MediaStreamType, int)); 131 MOCK_METHOD2(Opened, void(MediaStreamType, int));
132 MOCK_METHOD2(Closed, void(MediaStreamType, int)); 132 MOCK_METHOD2(Closed, void(MediaStreamType, int));
133 MOCK_METHOD2(Aborted, void(MediaStreamType, int)); 133 MOCK_METHOD2(Aborted, void(MediaStreamType, int));
134 }; // class MockMediaStreamProviderListener 134 }; // class MockMediaStreamProviderListener
135 135
136 // Needed as an input argument to StartCaptureForClient(). 136 // Needed as an input argument to StartCaptureForClient().
137 class MockFrameObserver : public VideoCaptureControllerEventHandler { 137 class MockFrameObserver : public VideoCaptureControllerEventHandler {
138 public: 138 public:
139 MOCK_METHOD1(OnError, void(VideoCaptureControllerID id)); 139 MOCK_METHOD1(OnError, void(VideoCaptureControllerID id));
140 MOCK_METHOD1(OnStarted, void(VideoCaptureControllerID id));
140 141
141 void OnBufferCreated(VideoCaptureControllerID id, 142 void OnBufferCreated(VideoCaptureControllerID id,
142 mojo::ScopedSharedBufferHandle handle, 143 mojo::ScopedSharedBufferHandle handle,
143 int length, int buffer_id) override {} 144 int length, int buffer_id) override {}
144 void OnBufferDestroyed(VideoCaptureControllerID id, int buffer_id) override {} 145 void OnBufferDestroyed(VideoCaptureControllerID id, int buffer_id) override {}
145 void OnBufferReady(VideoCaptureControllerID id, 146 void OnBufferReady(VideoCaptureControllerID id,
146 int buffer_id, 147 int buffer_id,
147 const scoped_refptr<media::VideoFrame>& frame) override {} 148 const scoped_refptr<media::VideoFrame>& frame) override {}
148 void OnEnded(VideoCaptureControllerID id) override {} 149 void OnEnded(VideoCaptureControllerID id) override {}
149 150
(...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after
732 // Wait to check callbacks before removing the listener. 733 // Wait to check callbacks before removing the listener.
733 base::RunLoop().RunUntilIdle(); 734 base::RunLoop().RunUntilIdle();
734 vcm_->Unregister(); 735 vcm_->Unregister();
735 } 736 }
736 #endif 737 #endif
737 738
738 // TODO(mcasas): Add a test to check consolidation of the supported formats 739 // TODO(mcasas): Add a test to check consolidation of the supported formats
739 // provided by the device when http://crbug.com/323913 is closed. 740 // provided by the device when http://crbug.com/323913 is closed.
740 741
741 } // namespace content 742 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698