layout/generic/test/test_bug344830.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=344830
     5 -->
     6 <head>
     7   <title>Test for Bug 344830</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=344830">Mozilla Bug 344830</a>
    13 <p id="display"></p>
    14 <div id="content" style="display: block">
    15   <embed name="svg1"
    16          width="200" height="200"
    17          type="image/svg+xml"
    18          src="bug344830_testembed.svg">
    19 </div>
    20 <pre id="test">
    21 <script class="testbody" type="text/javascript">
    23 /** Test for Bug 344830 **/
    24 function getSVG() {
    25  var embed = document.embeds["svg1"];
    26  var svgDocument = embed.getSVGDocument();
    27  var element = svgDocument.getElementById("g1");
    28  ok(embed, "document.embeds[] works with SVG");
    29  ok(svgDocument, "document.embeds[] works with SVG and embed.getSVGDocument()");
    30  ok(element, "document.embeds[] works with SVG and svgDocument.getElementById()");
    31  SimpleTest.finish();
    32 }
    33 addLoadEvent(getSVG);
    34 SimpleTest.waitForExplicitFinish()
    37 </script>
    38 </pre>
    39 </body>
    40 </html>

mercurial