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

Side by Side Diff: chrome/android/javatests/src/org/chromium/chrome/browser/vr_shell/WebVrTest.java

Issue 2859533003: WebVR: lock focus while presenting to presenting window (Closed)
Patch Set: Add test + address comments Created 3 years, 7 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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 package org.chromium.chrome.browser.vr_shell; 5 package org.chromium.chrome.browser.vr_shell;
6 6
7 import static org.chromium.chrome.browser.vr_shell.VrUtils.POLL_TIMEOUT_SHORT_MS ; 7 import static org.chromium.chrome.browser.vr_shell.VrUtils.POLL_TIMEOUT_SHORT_MS ;
8 import static org.chromium.chrome.test.util.ChromeRestriction.RESTRICTION_TYPE_V IEWER_DAYDREAM; 8 import static org.chromium.chrome.test.util.ChromeRestriction.RESTRICTION_TYPE_V IEWER_DAYDREAM;
9 import static org.chromium.chrome.test.util.ChromeRestriction.RESTRICTION_TYPE_W EBVR_SUPPORTED; 9 import static org.chromium.chrome.test.util.ChromeRestriction.RESTRICTION_TYPE_W EBVR_SUPPORTED;
10 10
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 * devices the WebVR tests are run on continuously. 242 * devices the WebVR tests are run on continuously.
243 */ 243 */
244 @MediumTest 244 @MediumTest
245 public void testDeviceCapabilitiesMatchExpectations() throws InterruptedExce ption { 245 public void testDeviceCapabilitiesMatchExpectations() throws InterruptedExce ption {
246 String testName = "test_device_capabilities_match_expectations"; 246 String testName = "test_device_capabilities_match_expectations";
247 loadUrl(getHtmlTestFile(testName), PAGE_LOAD_TIMEOUT_S); 247 loadUrl(getHtmlTestFile(testName), PAGE_LOAD_TIMEOUT_S);
248 assertTrue("VRDisplayFound", vrDisplayFound(mWebContents)); 248 assertTrue("VRDisplayFound", vrDisplayFound(mWebContents));
249 executeStepAndWait("stepCheckDeviceCapabilities('" + Build.DEVICE + "')" , mWebContents); 249 executeStepAndWait("stepCheckDeviceCapabilities('" + Build.DEVICE + "')" , mWebContents);
250 endTest(mWebContents); 250 endTest(mWebContents);
251 } 251 }
252
253 /**
254 * Tests that Daydream controller clicks are registered as screen taps when
bsheedy 2017/05/04 20:17:45 Wrong test description?
mthiesse 2017/05/04 20:24:20 Done.
255 * the viewer is a Daydream View.
256 */
257 @MediumTest
258 public void testPresentationLocksFocus() throws InterruptedException {
259 String testName = "test_presentation_locks_focus";
260 loadUrl(getHtmlTestFile(testName), PAGE_LOAD_TIMEOUT_S);
bsheedy 2017/05/04 20:17:45 Since you're presenting in this test, probably goo
mthiesse 2017/05/04 20:24:20 I think tests should be as simple as possible. Ano
261 enterVrTapAndWait(mWebContents);
262 waitOnJavaScriptStep(mWebContents);
263 endTest(mWebContents);
264 }
252 } 265 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698