Commit 19105678 authored by Mustaq Ahmed's avatar Mustaq Ahmed Committed by Commit Bot

Enable User Activation v2.

- Turns on UAv2 by default,
- copies test expectations from the virtual to main
  test suite, and
- changes few test expectations.

Intent to Ship discussion: https://groups.google.com/a/chromium.org/d/msg/blink-dev/nkTDR8AUlwM/xsPcojA5BAAJ

Bug: 904991
Change-Id: I213b5a723ffe08b859170ae8dfb539eee84ffaf3
Reviewed-on: https://chromium-review.googlesource.com/c/796938Reviewed-by: default avatarAlex Moshchuk <alexmos@chromium.org>
Reviewed-by: default avatarDave Tapuska <dtapuska@chromium.org>
Commit-Queue: Mustaq Ahmed <mustaq@chromium.org>
Cr-Commit-Position: refs/heads/master@{#611220}
parent b868a519
...@@ -440,7 +440,7 @@ const base::Feature kTouchpadAsyncPinchEvents{"TouchpadAsyncPinchEvents", ...@@ -440,7 +440,7 @@ const base::Feature kTouchpadAsyncPinchEvents{"TouchpadAsyncPinchEvents",
// tracked through a frame-based state instead of the gesture tokens we use // tracked through a frame-based state instead of the gesture tokens we use
// today. // today.
const base::Feature kUserActivationV2{"UserActivationV2", const base::Feature kUserActivationV2{"UserActivationV2",
base::FEATURE_DISABLED_BY_DEFAULT}; base::FEATURE_ENABLED_BY_DEFAULT};
// Enables to use a snapshot file in creating V8 contexts. // Enables to use a snapshot file in creating V8 contexts.
const base::Feature kV8ContextSnapshot{"V8ContextSnapshot", const base::Feature kV8ContextSnapshot{"V8ContextSnapshot",
......
...@@ -64,11 +64,11 @@ crbug.com/891427 virtual/threaded/http/tests/devtools/tracing/timeline-paint/tim ...@@ -64,11 +64,11 @@ crbug.com/891427 virtual/threaded/http/tests/devtools/tracing/timeline-paint/tim
# Activation v2 (UAv2). # Activation v2 (UAv2).
crbug.com/906791 external/wpt/fullscreen/api/element-ready-check-allowed-cross-origin-manual.sub.html [ Timeout ] crbug.com/906791 external/wpt/fullscreen/api/element-ready-check-allowed-cross-origin-manual.sub.html [ Timeout ]
crbug.com/860713 bluetooth/characteristic/notifications/notification-after-disconnection.html [ Failure ] crbug.com/860713 bluetooth/characteristic/notifications/notification-after-disconnection.html [ Failure ]
crbug.com/860713 external/wpt/bluetooth/requestDevice/cross-origin-iframe.sub.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/requestDevice/cross-origin-iframe.sub.https.html [ Failure Timeout ]
crbug.com/860713 external/wpt/bluetooth/requestDevice/request-from-iframe.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/requestDevice/request-from-iframe.https.html [ Failure Timeout ]
crbug.com/860713 external/wpt/bluetooth/requestDevice/request-from-sandboxed-iframe.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/requestDevice/request-from-sandboxed-iframe.https.html [ Failure Timeout ]
crbug.com/860713 external/wpt/bluetooth/server/disconnect/detach-gc.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/server/disconnect/detach-gc.https.html [ Failure Timeout ]
crbug.com/860713 external/wpt/bluetooth/server/disconnect/gc-detach.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/server/disconnect/gc-detach.https.html [ Failure Timeout ]
crbug.com/860713 external/wpt/bluetooth/server/getPrimaryService/gen-discovery-complete-no-permission-absent-service.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/server/getPrimaryService/gen-discovery-complete-no-permission-absent-service.https.html [ Failure ]
crbug.com/860713 external/wpt/bluetooth/server/getPrimaryService/gen-discovery-complete-service-not-found.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/server/getPrimaryService/gen-discovery-complete-service-not-found.https.html [ Failure ]
crbug.com/860713 external/wpt/bluetooth/server/getPrimaryService/two-iframes-from-same-origin.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/server/getPrimaryService/two-iframes-from-same-origin.https.html [ Failure ]
...@@ -78,8 +78,8 @@ crbug.com/860713 external/wpt/bluetooth/service/getCharacteristic/gen-reconnect- ...@@ -78,8 +78,8 @@ crbug.com/860713 external/wpt/bluetooth/service/getCharacteristic/gen-reconnect-
crbug.com/860713 external/wpt/bluetooth/service/getCharacteristics/gen-reconnect-during-with-uuid.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/service/getCharacteristics/gen-reconnect-during-with-uuid.https.html [ Failure ]
crbug.com/860713 external/wpt/bluetooth/service/getCharacteristics/gen-reconnect-during.https.html [ Failure ] crbug.com/860713 external/wpt/bluetooth/service/getCharacteristics/gen-reconnect-during.https.html [ Failure ]
# The following tests passes only with User Activation v2 (UAv2) enabled. # The following tests passes only with User Activation v2 (UAv2) disabled.
crbug.com/906791 external/wpt/fullscreen/api/element-ready-check-containing-iframe-manual.tentative.html [ Failure ] crbug.com/908841 external/wpt/fullscreen/api/element-ready-check-containing-iframe-manual.html [ Timeout ]
# The following fail only on Mac. # The following fail only on Mac.
crbug.com/891427 [ Mac ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen-desktop.html [ Pass Failure Timeout Crash ] crbug.com/891427 [ Mac ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen-desktop.html [ Pass Failure Timeout Crash ]
......
Test that user gesture is kept when postMessage() to self or across frames. Test that user gesture is available through postMessages to appropriate frames.
Click me Click me
PASS Stack postMessages on self window and the user gesture is only consumed once PASS Stack postMessages on self window and the user gesture is only consumed once
PASS Bounce postMessages between self and frame window and the user gesture is consumed only once in self window PASS Bounce postMessages between self and frame window and the user gesture is consumed only once in self window
PASS Bounce postMessages between self and frame window and the user gesture is consumed only once in frame PASS Bounce postMessages between self and frame window and the user gesture is consumed 0 times in frame
PASS successfullyParsed is true PASS successfullyParsed is true
TEST COMPLETE TEST COMPLETE
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<script src="../../../resources/js-test.js"></script> <script src="../../../resources/js-test.js"></script>
</head> </head>
<body> <body>
<div id="description">Test that user gesture is kept when postMessage() to self or across frames.</div> <div id="description">Test that user gesture is available through postMessages to appropriate frames.</div>
<div id="div1" onclick="clickHandler()">Click me</div> <div id="div1" onclick="clickHandler()">Click me</div>
<iframe id="subframe" src="resources/window-postmessage-user-gesture-frame.html" onload="startTest()"></iframe> <iframe id="subframe" src="resources/window-postmessage-user-gesture-frame.html" onload="startTest()"></iframe>
<div id="console"></div> <div id="console"></div>
......
This tests that window.open works across frames. This tests that window.open from a subframe doesn't work with main frame activation.
To run manually click the link below. To run manually click the link below.
GreenBox or Success page. GreenBox or Success page.
Window was opened! Test succeeded! Window was not opened! Test succeeded!
-------- --------
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
</script> </script>
</head> </head>
<body onload="test()"> <body onload="test()">
This tests that window.open works across frames.<br> This tests that window.open from a subframe doesn't work with main frame activation.<br>
To run manually click the link below.<br> To run manually click the link below.<br>
<a href="resources/greenbox.png" id="link">GreenBox or Success page.</a><br> <a href="resources/greenbox.png" id="link">GreenBox or Success page.</a><br>
<iframe src="resources/open-window-from-another-frame-otherFrame.html" name="otherFrame"></iframe> <iframe src="resources/open-window-from-another-frame-otherFrame.html" name="otherFrame"></iframe>
......
...@@ -3,5 +3,5 @@ PASS successfullyParsed is true ...@@ -3,5 +3,5 @@ PASS successfullyParsed is true
TEST COMPLETE TEST COMPLETE
Test calling window.open() in a nested call to setTimeout(). A popup should not be allowed. Test calling window.open() in a nested call to setTimeout(). A popup should be allowed.
PASS newWindow is null PASS newWindow is non-null.
<!DOCTYPE html> <!DOCTYPE html>
<html>
<head>
<style>
#block1 {
width: 200px;
height: 100px;
border: 4px solid darkgreen;
background-color: white;
z-index: 0;
}
#block2 {
width: 100px;
height: 50px;
border: 4px solid darkred;
background-color: red;
z-index: 500;
position: relative;
left: 50px;
top: 25px;
}
</style>
</head>
<body>
<div>This tests that an element with a positive z-index appears behind the full screen iframe element.
After entering full screen mode, the whole screen should be white.
Click <button>go full screen</button> to run the test.</div>
<div id="block2"></div>
<iframe id="block1"></iframe>
<div>EVENT(webkitfullscreenerror)<br>END OF TEST<br></div>
</body>
</html>
CONSOLE WARNING: line 20: Failed to execute 'requestFullscreen' on 'Element': API can only be initiated by a user gesture.
CONSOLE MESSAGE: line 37: This test requires User Activation V2. EVENT(gamepadconnected)
EVENT(fullscreenchange)
EXPECTED (document.fullscreenElement == '[object HTMLHtmlElement]') OK
EVENT(fullscreenchange)
EXPECTED (document.fullscreenElement == '[object HTMLSpanElement]') OK
EVENT(fullscreenchange)
EXPECTED (document.fullscreenElement == '[object HTMLHtmlElement]') OK
EVENT(fullscreenchange)
EXPECTED (document.fullscreenElement == 'undefined') OK
END OF TEST END OF TEST
...@@ -6,5 +6,6 @@ TEST COMPLETE ...@@ -6,5 +6,6 @@ TEST COMPLETE
============== Back Forward List ============== ============== Back Forward List ==============
http://127.0.0.1:8000/media/autoplay/document-user-activation-navigation-click.html
curr-> http://127.0.0.1:8000/media/autoplay/resources/test-autoplay.html curr-> http://127.0.0.1:8000/media/autoplay/resources/test-autoplay.html
=============================================== ===============================================
...@@ -6,5 +6,6 @@ TEST COMPLETE ...@@ -6,5 +6,6 @@ TEST COMPLETE
============== Back Forward List ============== ============== Back Forward List ==============
http://127.0.0.1:8000/media/autoplay/document-user-activation-navigation-keypress.html
curr-> http://127.0.0.1:8000/media/autoplay/resources/test-autoplay.html curr-> http://127.0.0.1:8000/media/autoplay/resources/test-autoplay.html
=============================================== ===============================================
...@@ -6,5 +6,6 @@ TEST COMPLETE ...@@ -6,5 +6,6 @@ TEST COMPLETE
============== Back Forward List ============== ============== Back Forward List ==============
http://127.0.0.1:8000/media/autoplay/document-user-activation-navigation-tap.html
curr-> http://127.0.0.1:8000/media/autoplay/resources/test-autoplay.html curr-> http://127.0.0.1:8000/media/autoplay/resources/test-autoplay.html
=============================================== ===============================================
Test that user gesture is kept when postMessage() to self or across frames. Test that user gesture is available through postMessages to appropriate frames.
Click me Click me
PASS Stack postMessages on self window and the user gesture is only consumed once PASS Stack postMessages on self window and the user gesture is only consumed once
......
This tests that window.open works across frames. This tests that window.open from a subframe doesn't work with main frame activation.
To run manually click the link below. To run manually click the link below.
GreenBox or Success page. GreenBox or Success page.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment