Bug 1478107 [wpt PR 12164] - Don't wait for Picture-in-Picture when expecting reject on second request, a=testonly

Automatic update from web-platform-testsDon't wait for Picture-in-Picture when expecting reject on second request (#12164)

--

wpt-commits: 2a8d821bd0a29656ff27eac35d9dd071d27be779
wpt-pr: 12164
This commit is contained in:
Luke Bjerring 2018-07-30 14:12:57 +00:00 коммит произвёл moz-wptsync-bot
Родитель 4512090516
Коммит 02181c6dd9
4 изменённых файлов: 7 добавлений и 7 удалений

Просмотреть файл

@ -603737,7 +603737,7 @@
"support"
],
"picture-in-picture/disable-picture-in-picture.html": [
"f80cdccd1c6edcf6a859a1ae2315a9f65188d812",
"3da36cdc69fef19a84da9d27b688b12d43179688",
"testharness"
],
"picture-in-picture/enter-picture-in-picture.html": [
@ -603765,7 +603765,7 @@
"testharness"
],
"picture-in-picture/request-picture-in-picture-twice.html": [
"c45cc223ec4336916d46c3d4db8bc4decbbd3332",
"b678b793cd36252dd3b76709e9ff4ab0535e8931",
"testharness"
],
"picture-in-picture/request-picture-in-picture.html": [
@ -603773,7 +603773,7 @@
"testharness"
],
"picture-in-picture/resources/picture-in-picture-helpers.js": [
"b41a3c97a777a69ab28eea3b33f464379303da3d",
"ccc8105dfe2ace32ed87e05b69c2a09bbc839724",
"support"
],
"picture-in-picture/shadow-dom.html": [

Просмотреть файл

@ -33,7 +33,7 @@ promise_test(async t => {
promise_test(async t => {
const video = await loadVideo();
return test_driver.bless('request picture in picture', async () => {
return test_driver.bless('request Picture-in-Picture', async () => {
const promise = video.requestPictureInPicture();
video.disablePictureInPicture = true;
await promise_rejects(t, 'InvalidStateError', promise);

Просмотреть файл

@ -11,9 +11,9 @@ promise_test(async t => {
const video1 = await loadVideo();
const video2 = await loadVideo();
return test_driver.bless(
'request picture in picture',
'request Picture-in-Picture',
async () => {
await video1.requestPictureInPicture();
video1.requestPictureInPicture();
promise_rejects(t, 'NotAllowedError', video2.requestPictureInPicture());
}
);

Просмотреть файл

@ -17,6 +17,6 @@ function loadVideo(activeDocument, sourceUrl) {
// Calls requestPictureInPicture() in a context that's 'allowed to request PiP'.
function requestPictureInPictureWithTrustedClick(videoElement) {
return test_driver.bless(
'request picture in picture',
'request Picture-in-Picture',
() => videoElement.requestPictureInPicture());
}