mirror of
https://github.com/servo/servo.git
synced 2025-08-29 00:58:20 +01:00
Update web-platform-tests to revision 322c4da99b1d62796d5f4105eb02a745bb35d3f9
This commit is contained in:
parent
8b9e607aac
commit
b89d47297d
148 changed files with 2587 additions and 278 deletions
|
@ -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>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue