https://github.com/web-platform-tests/wpt
Raw File
Tip revision: 57efde67960dc7d060e017f27c1a780a6b591f4a authored by moz-wptsync-bot on 13 March 2018, 19:13:26 UTC
Don't use external server in CSS tables test,
Tip revision: 57efde6
enter-picture-in-picture.html
<!DOCTYPE html>
<title>Test enterpictureinpicture event</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<script src="resources/picture-in-picture-helpers.js"></script>
<body></body>
<script>
promise_test(t => {
  const video = document.createElement('video');

  video.addEventListener('enterpictureinpicture', t.step_func_done(event => {
    assert_equals(event.target, video);
    assert_equals(event.bubbles, true);
    assert_equals(event.cancelable, false);
    assert_equals(event.composed, false);
    assert_equals(document.pictureInPictureElement, video);
  }));

  return requestPictureInPictureWithTrustedClick(video);
});
</script>
back to top