blob: 8592d0d17f215f7f5adf8d0dc965f7693da11d82 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
<!DOCTYPE html>
<meta charset="utf-8">
<script src="/tests/SimpleTest/SimpleTest.js"></script>
<div id="div">
<script>
/* globals div svgRanScript */
SimpleTest.waitForExplicitFinish();
window.svgRanScript = false;
const o = new MutationObserver(mutations => {
o.disconnect();
setTimeout(() => {
ok(!svgRanScript, "svg onload must not fire");
SimpleTest.finish();
});
});
o.observe(div, {childList: true});
const p = (new DOMParser()).parseFromString("<svg onload=\"window.svgRanScript=true\"></svg>", "text/html");
div.appendChild(p.body);
</script>
|