Update web-platform-tests to revision 592e2ed83ecd717392d37047536250ba74f1bafa

This commit is contained in:
WPT Sync Bot 2018-03-28 21:12:37 -04:00
parent c8b0dc965d
commit 0a3e19aac8
65 changed files with 1906 additions and 106 deletions

View file

@ -0,0 +1,34 @@
<!DOCTYPE html>
<title>HTMLBodyElement event handlers</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<body>
<script>
function f() {
return 0;
}
var handlers = ['blur','error','focus','load','resize','scroll',
'afterprint','beforeprint','beforeunload','hashchange',
'languagechange','message','offline','online','pagehide',
'pageshow','popstate','storage','unload'];
handlers.forEach(function(handler) {
test(function() {
window['on' + handler] = f;
assert_equals(document.body['on' + handler], f);
}, handler);
});
handlers.forEach(function(handler) {
window['on' + handler] = null;
});
handlers.forEach(function(handler) {
test(function() {
assert_equals(window['on' + handler], null);
assert_equals(document.body['on' + handler], null);
}, handler + " removal");
});
</script>