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

Unified Diff: third_party/WebKit/LayoutTests/vr/requestPresent_reject_badrightbounds.html

Issue 2616403002: Revert of Add more WebVR layout tests, adjust test format (Closed)
Patch Set: Created 3 years, 11 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
Index: third_party/WebKit/LayoutTests/vr/requestPresent_reject_badrightbounds.html
diff --git a/third_party/WebKit/LayoutTests/vr/requestPresent_reject_badrightbounds.html b/third_party/WebKit/LayoutTests/vr/requestPresent_reject_badrightbounds.html
index 8fa5169faec73c2b2422d31f0658562c41edb69d..0ff2a67389d71ebd9be1bfd8eda5db0f34dcd13d 100644
--- a/third_party/WebKit/LayoutTests/vr/requestPresent_reject_badrightbounds.html
+++ b/third_party/WebKit/LayoutTests/vr/requestPresent_reject_badrightbounds.html
@@ -9,34 +9,30 @@
<script>
let fakeDisplays = fakeVRDisplays();
-vr_test( (t) => {
- return navigator.getVRDisplays().then( (displays) => {
- var display = displays[0];
-
- runWithUserGesture( () => {
- display.requestPresent([{
- source : webglCanvas,
- rightBounds: [0, 1, 2, 3, 4] // Too long
- }])
- .then( () => {
- t.step( () => {
- assert_unreached();
- }, "Display should not be presenting");
- }, (err) => {
- t.step( () => {
- assert_false(display.isPresenting);
- }, "requestPresent rejected and not presenting");
- }).then( () => {
- t.done();
+vr_test((service) => {
+ return navigator.getVRDisplays().then(displays => {
+ assert_true(displays != null);
+ assert_equals(1, displays.length);
+ var asyncTest = async_test(
+ "requestPresent rejects and does not present");
+ runWithUserGesture( () => {
+ displays[0].requestPresent([{
+ source : webglCanvas,
+ rightBounds: [0, 1, 2, 3, 4] // Too long
+ }]).then( () => {
+ asyncTest.step( () => {
+ assert_unreached();
+ }, "Display should not be presenting");
+ }, (err) => {
+ asyncTest.step( () => {
+ assert_false(displays[0].isPresenting);
+ }, "requestPresent rejected and not presenting");
+ }).then( () => {
+ asyncTest.done();
+ });
});
});
- }, (err) => {
- t.step( () => {
- assert_unreached(err);
- }, "getVRDisplays rejected");
- t.done();
- });
-}, [fakeDisplays["Pixel"]],
-"Test requestPresent rejects if provided a bad rightBounds");
+}, [fakeDisplays['Pixel']],
+'Test requestPresent rejects if provided a bad rightBounds');
</script>

Powered by Google App Engine
This is Rietveld 408576698