dom/tests/mochitest/bugs/test_bug414291.html

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 <!DOCTYPE HTML>
     2 <html>
     3 <!--
     4 https://bugzilla.mozilla.org/show_bug.cgi?id=414291
     5 -->
     6 <head>
     7   <title>Test for Bug 414291</title>
     8   <script type="text/javascript" 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=414291">Mozilla Bug 414291</a>
    13 <script class="testbody" type="text/javascript">
    15 /** Test for Bug 414291 **/
    17 var result1 = 0;
    18 var result2 = 0;
    19 var result3 = 0;
    21 window.open("data:text/html,<html><body onload='close(); opener.result1 = 1;'>", "w1");
    22 is(result1, 0, "window either opened as modal or loaded synchronously.");
    24 window.open("data:text/html,<html><body onload='close(); opener.result2 = 2;'>", "w2", "modal=yes");
    25 is(result2, 0, "window either opened as modal or data loaded synchronously.");
    27 result3 = window.showModalDialog("data:text/html,<html><body onload='close(); returnValue = 3;'>");
    28 is(result3, 3, "window didn't open as modal.");
    30 </script>
    31 </pre>
    32 </body>
    33 </html>

mercurial