Commit 8548a02a authored by Thomas Guilbert's avatar Thomas Guilbert Committed by Chromium LUCI CQ

Deflake video-overlay-menu.html

This CL uses video.requestVideoFrameCallback to make sure a frame is
displayed before ending the test. It's possible this test might
still flake if the overflow menu doesn't show up on screen in time.

Bug: 1145491
Change-Id: Ic402b396cf49d9c2e6853a039e44f739bb2cc014
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2567571
Commit-Queue: Mounir Lamouri <mlamouri@chromium.org>
Auto-Submit: Thomas Guilbert <tguilbert@chromium.org>
Reviewed-by: default avatarMounir Lamouri <mlamouri@chromium.org>
Cr-Commit-Position: refs/heads/master@{#832620}
parent c899175b
...@@ -9,13 +9,12 @@ ...@@ -9,13 +9,12 @@
<video controls></video> <video controls></video>
<script> <script>
var video = document.querySelector("video"); var video = document.querySelector("video");
video.src = "../../../../media/content/test.ogv";
enableTestMode(video); enableTestMode(video);
init();
video.onloadeddata = function () { video.onloadeddata = function () {
var overflowMenu = getOverflowMenuButton(video); var overflowMenu = getOverflowMenuButton(video);
var coords = elementCoordinates(overflowMenu); var coords = elementCoordinates(overflowMenu);
clickAtCoordinates(coords[0], coords[1]); clickAtCoordinates(coords[0], coords[1]);
}; };
setVideoSrcAndWaitForFirstFrame("../../../../media/content/test.ogv");
</script> </script>
</body> </body>
\ No newline at end of file
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