Update web-platform-tests to revision 322c4da99b1d62796d5f4105eb02a745bb35d3f9

This commit is contained in:
WPT Sync Bot 2020-11-04 08:20:32 +00:00
parent 8b9e607aac
commit b89d47297d
148 changed files with 2587 additions and 278 deletions

View file

@ -39,21 +39,21 @@
}, "stylesheet.css should be unloaded and styleSheets.length === 0");
// Verify that the styleSheets list length is back to 1 after loading a new sheet
test(function() {
async_test(function(t) {
// create a css file reference
var fileReference = document.createElement("link");
fileReference.setAttribute("rel", "stylesheet");
fileReference.setAttribute("type", "text/css");
fileReference.setAttribute("href", "stylesheet-1.css");
fileReference.onerror = t.step_func_done(function() {
// assert that there is 1 styleSheet in the styleSheets property
assert_equals(styleSheets.length, 1, "styleSheets.length is incorrect:");
});
// load the css file reference into the head section
var head = document.getElementsByTagName("HEAD")[0];
head.appendChild(fileReference);
// assert that there is 1 styleSheet in the styleSheets property
assert_equals(styleSheets.length, 1, "styleSheets.length is incorrect:");
}, "stylesheet-1.css should be loaded and styleSheets.length === 1");
</script>