Commit 9be178a8 authored by Mustaq Ahmed's avatar Mustaq Ahmed Committed by Commit Bot

Fix two fullscreen wpt tests for UAv2.

Also marks one currently untestable test.

Bug: 906791
Change-Id: I17fd03f16e93244be80f9572db8c43e8e0b95678
Reviewed-on: https://chromium-review.googlesource.com/c/1347092
Commit-Queue: Mustaq Ahmed <mustaq@chromium.org>
Reviewed-by: default avatarPhilip Jägenstedt <foolip@chromium.org>
Cr-Commit-Position: refs/heads/master@{#610651}
parent 128d9b67
...@@ -62,6 +62,7 @@ crbug.com/891427 virtual/threaded/http/tests/devtools/tracing/timeline-paint/tim ...@@ -62,6 +62,7 @@ crbug.com/891427 virtual/threaded/http/tests/devtools/tracing/timeline-paint/tim
# The following tests need to remove the assumption that user activation is # The following tests need to remove the assumption that user activation is
# available in child/sibling frames. This assumption doesn't hold with User # available in child/sibling frames. This assumption doesn't hold with User
# 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/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 ]
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 ]
...@@ -77,6 +78,9 @@ crbug.com/860713 external/wpt/bluetooth/service/getCharacteristic/gen-reconnect- ...@@ -77,6 +78,9 @@ 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.
crbug.com/906791 external/wpt/fullscreen/api/element-ready-check-containing-iframe-manual.tentative.html [ Failure ]
# 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 ]
crbug.com/891427 [ Mac ] fast/events/touch/gesture/touch-gesture-scroll-listbox.html [ Pass Failure Timeout Crash ] crbug.com/891427 [ Mac ] fast/events/touch/gesture/touch-gesture-scroll-listbox.html [ Pass Failure Timeout Crash ]
......
...@@ -26,7 +26,9 @@ async_test((t) => { ...@@ -26,7 +26,9 @@ async_test((t) => {
elem.addEventListener('load', () => { elem.addEventListener('load', () => {
trusted_click(t, () => { trusted_click(t, () => {
elem.contentWindow.postMessage({"action": "report"}, "*"); elem.contentWindow.postMessage({"action": "report"}, "*");
}, document.body); }, elem.contentDocument.body);
// TODO(mustaq): The click above should activate the subframe. But
// elem.contentDocument is inaccessible (null) from a cross origin parent!
}); });
}); });
</script> </script>
<!DOCTYPE html>
<!--
Tentative, due to:
https://github.com/whatwg/html/issues/1903
Once the issue is resolved, this test would replace the corresponding
non-tentative test (element-ready-check-containing-iframe-manual.html)
-->
<title>Element ready check for containing iframe</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="../trusted-click.js"></script>
<div id="log"></div>
<iframe allowfullscreen></iframe>
<iframe allowfullscreen></iframe>
<script>
// wait for load event to avoid https://bugzil.la/1493878
window.onload = function() {
async_test(function(t) {
var iframes = document.getElementsByTagName("iframe");
trusted_request(t, iframes[0].contentDocument.body, iframes[0].contentDocument.body);
iframes[0].contentDocument.onfullscreenchange = t.step_func(function() {
assert_equals(document.fullscreenElement, iframes[0]);
trusted_request(t, iframes[1].contentDocument.body, iframes[0].contentDocument.body);
iframes[1].contentDocument.onfullscreenchange = t.unreached_func("fullscreenchange event");
iframes[1].contentDocument.onfullscreenerror = t.step_func_done();
});
});
};
</script>
...@@ -21,19 +21,27 @@ async_test(t => { ...@@ -21,19 +21,27 @@ async_test(t => {
assert_in_array(document.fullscreenElement, [a, b]); assert_in_array(document.fullscreenElement, [a, b]);
order.push(document.fullscreenElement.id); order.push(document.fullscreenElement.id);
if (order.length == 2) { if (order.length == 2) {
// Since fullscreenchange event occurs at animation frame timing we might // When the second event arrived, the fullscreen element may still be the
// have not seen the transition from null -> 'b' but just see the // old one.
// resulting 'a' transition twice. //
// TODO(mustaq): We need a better explanation here to cover the tree-order
// idea of the spec.
assert_true(order[0] == 'a' || order[0] == 'b', 'first id seen is a or b'); assert_true(order[0] == 'a' || order[0] == 'b', 'first id seen is a or b');
assert_true(order[1] == 'a', 'second id seen is b'); assert_true(order[1] == 'a', 'second id seen is a');
t.done(); t.done();
} }
}); });
document.onfullscreenerror = t.unreached_func('fullscreenerror event'); document.onfullscreenerror = t.unreached_func('fullscreenerror event');
// Make a trusted click on frame 'b' to activate it.
trusted_click(t, () => { trusted_click(t, () => {
b.contentDocument.body.requestFullscreen(); // Now queue a trusted click on frame 'a' to make back-to-back calls.
a.contentDocument.body.requestFullscreen(); setTimeout(() => {
}, document.body); trusted_click(t, () => {
b.contentDocument.body.requestFullscreen();
a.contentDocument.body.requestFullscreen();
}, a.contentDocument.body);
}, 0);
}, b.contentDocument.body);
}); });
</script> </script>
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