mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
49 lines
1.3 KiB
HTML
49 lines
1.3 KiB
HTML
|
<!DOCTYPE HTML>
|
||
|
<html>
|
||
|
<!--
|
||
|
https://bugzilla.mozilla.org/show_bug.cgi?id=592366
|
||
|
-->
|
||
|
<head>
|
||
|
<title>Test for Bug 592366</title>
|
||
|
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
||
|
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
||
|
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
|
||
|
</head>
|
||
|
<body>
|
||
|
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=592366">Mozilla Bug 592366</a>
|
||
|
<p id="display"></p>
|
||
|
<div id="content" style="display: none">
|
||
|
<iframe onload='runTest();'></iframe>
|
||
|
<iframe onload='runTest();'></iframe>
|
||
|
</div>
|
||
|
<pre id="test">
|
||
|
<script class="testbody" type="text/javascript">
|
||
|
SimpleTest.waitForExplicitFinish();
|
||
|
/** Test for Bug 592366 **/
|
||
|
var iframesToLoad = 2;
|
||
|
function runTest() {
|
||
|
--iframesToLoad;
|
||
|
if (iframesToLoad) {
|
||
|
return;
|
||
|
}
|
||
|
|
||
|
ok(true, "Obligatory succeeding assertion.");
|
||
|
|
||
|
var s = document.createElement("script");
|
||
|
s.src = "data:text/javascript,parent.ok(false, 'This script should not be executed.');"
|
||
|
|
||
|
var iframes = document.getElementsByTagName("iframe");
|
||
|
|
||
|
iframes[0].contentDocument.body.appendChild(s);
|
||
|
iframes[1].contentDocument.body.appendChild(s);
|
||
|
|
||
|
setTimeout(function() {
|
||
|
SimpleTest.finish();
|
||
|
}, 500);
|
||
|
}
|
||
|
</script>
|
||
|
</pre>
|
||
|
</body>
|
||
|
</html>
|
||
|
|