Update web-platform-tests to revision 993a932dca2b378a44dc55f4ee80812f65d8fb4e

This commit is contained in:
WPT Sync Bot 2020-02-20 08:20:07 +00:00
parent f5ff38b875
commit af74a5d2cf
331 changed files with 3327 additions and 3531 deletions

View file

@ -22,4 +22,28 @@ function RunTestsInNestedIFrame(sourceURL) {
nestedFrame.contentDocument.write(content);
nestedFrame.contentDocument.close();
fetch_tests_from_window(nestedFrame.contentWindow);
}
}
let g_clickID = 0;
function ClickButtonWithGesture(onClickMethod) {
// Append some formatting and information so non WebDriver instances can complete this test too.
let info = document.createElement('p');
info.innerText = "This test case requires user-interaction and TestDriver. If you're running it manually please click the 'Request Access' button below exactly once.";
document.body.appendChild(info);
let button = document.createElement('button');
button.innerText = "Request Access";
g_clickID += 1;
button.id = g_clickID;
button.style = "background-color:#FF0000;"
// Insert the button and use test driver to click the button with a gesture.
document.body.appendChild(button);
button.addEventListener('click', e => {
onClickMethod();
button.style = "background-color:#00FF00;"
}, {once: true});
return test_driver.click(button);
}