test_bug431082.html (2024B)
1 <!DOCTYPE HTML> 2 <html> 3 <!-- 4 https://bugzilla.mozilla.org/show_bug.cgi?id=431082 5 --> 6 <head> 7 <title>Test for Bug 431082</title> 8 <script src="/tests/SimpleTest/SimpleTest.js"></script> 9 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> 10 </head> 11 <body> 12 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=431082">Mozilla Bug 431082</a> 13 <p id="display"></p> 14 <div id="content" style="display: none"> 15 16 </div> 17 <pre id="test"> 18 <script class="testbody" type="text/javascript"> 19 20 /** Test for Bug 431082 */ 21 22 SimpleTest.waitForExplicitFinish(); 23 addLoadEvent(function() { ok(true, "browser should not crash."); }); 24 addLoadEvent(SimpleTest.finish); 25 26 </script> 27 </pre> 28 <!-- 29 <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> 30 <box id="a" observes="b"> 31 <box id="b"/> 32 </box> 33 34 <box id="a" src="javascript:"/> 35 <box id="b" src="javascript://"/> 36 <editor observes="a"/> 37 38 <script> 39 function doe() { 40 window.addEventListener('DOMAttrModified', function() 41 {window.frameElement.remove();}, true); 42 document.documentElement.appendChild(document.getElementsByTagName('box')[0]); 43 } 44 setTimeout(doe,0); 45 </script> 46 </window> 47 --> 48 <iframe src="data:application/xhtml+xml;charset=utf-8,%3Cwindow%20xmlns%3D%22http%3A//www.mozilla.org/keymaster/gatekeeper/there.is.only.xul%22%3E%0A%3Cbox%20%20id%3D%22a%22%20observes%3D%22b%22%3E%0A%20%20%3Cbox%20id%3D%22b%22/%3E%0A%3C/box%3E%0A%0A%3Cbox%20%20id%3D%22a%22%20%20src%3D%22javascript%3A%22/%3E%0A%3Cbox%20id%3D%22b%22%20src%3D%22javascript%3A//%22/%3E%0A%3Ceditor%20observes%3D%22a%22/%3E%0A%0A%3Cscript%3E%20%0Afunction%20doe%28%29%20%7B%0Awindow.addEventListener%28%27DOMAttrModified%27%2C%20function%28%29%20%7Bwindow.frameElement.parentNode.removeChild%28window.frameElement%29%3B%7D%2C%20true%29%3B%0Adocument.documentElement.appendChild%28document.getElementsByTagName%28%27box%27%29%5B0%5D%29%3B%0A%7D%0AsetTimeout%28doe%2C0%29%3B%0A%3C/script%3E%0A%3C/window%3E" style="width:1000px;height: 300px;"></iframe> 49 </body> 50 </html>