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

Side by Side Diff: webrtc/api/androidtests/src/org/webrtc/Camera2CapturerTest.java

Issue 2377003002: Format all Java in WebRTC. (Closed)
Patch Set: Rebase. Created 4 years, 2 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 /* 1 /*
2 * Copyright 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2016 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 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 if (cameraDevice != null) { 136 if (cameraDevice != null) {
137 cameraDevice.close(); 137 cameraDevice.close();
138 } 138 }
139 } 139 }
140 140
141 looperThread.requestStop(); 141 looperThread.requestStop();
142 ThreadUtils.joinUninterruptibly(looperThread); 142 ThreadUtils.joinUninterruptibly(looperThread);
143 } 143 }
144 } 144 }
145 145
146 private class TestObjectFactory 146 private class TestObjectFactory extends CameraVideoCapturerTestFixtures.TestOb jectFactory {
147 extends CameraVideoCapturerTestFixtures.TestObjectFactory {
148 @Override 147 @Override
149 public CameraEnumerator getCameraEnumerator() { 148 public CameraEnumerator getCameraEnumerator() {
150 return new Camera2Enumerator(getAppContext()); 149 return new Camera2Enumerator(getAppContext());
151 } 150 }
152 151
153 @Override 152 @Override
154 public Context getAppContext() { 153 public Context getAppContext() {
155 return getInstrumentation().getTargetContext(); 154 return getInstrumentation().getTargetContext();
156 } 155 }
157 156
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 fixtures.startWhileCameraIsAlreadyOpenAndCloseCamera(); 289 fixtures.startWhileCameraIsAlreadyOpenAndCloseCamera();
291 } 290 }
292 291
293 // This test that CameraVideoCapturer.stop can be called while CameraVideoCapt urer is 292 // This test that CameraVideoCapturer.stop can be called while CameraVideoCapt urer is
294 // re-trying to start. 293 // re-trying to start.
295 @MediumTest 294 @MediumTest
296 public void testStartWhileCameraIsAlreadyOpenAndStop() throws InterruptedExcep tion { 295 public void testStartWhileCameraIsAlreadyOpenAndStop() throws InterruptedExcep tion {
297 fixtures.startWhileCameraIsAlreadyOpenAndStop(); 296 fixtures.startWhileCameraIsAlreadyOpenAndStop();
298 } 297 }
299 } 298 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698