content/base/test/test_bug692434.html

Thu, 15 Jan 2015 21:03:48 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 21:03:48 +0100
branch
TOR_BUG_9701
changeset 11
deefc01c0e14
permissions
-rw-r--r--

Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)

     1 <!DOCTYPE HTML>
     2 <html>
     3 <!--
     4 https://bugzilla.mozilla.org/show_bug.cgi?id=692434
     5 -->
     6 <head>
     7   <title>Test for Bug 692434</title>
     8   <script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
     9   <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
    10   <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
    11 </head>
    12 <body onload=runTest();>
    13 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=692434">Mozilla Bug 692434</a>
    14 <p id="display"></p>
    15 <div id="content" style="display: none">
    17 </div>
    18 <pre id="test">
    19 <script class="testbody" type="text/javascript">
    21 /** Test for Bug 692434 **/
    22 SimpleTest.waitForExplicitFinish();
    24 var xhr = new XMLHttpRequest();
    26 function runTest() {
    27   xhr.onreadystatechange = function() {
    28     if (this.readyState == 4) {
    29       ok(this.responseXML, "Should have gotten responseXML");
    30       is(this.responseXML.characterSet, "windows-1251", "Wrong character encoding");
    31       is(this.responseXML.documentElement.firstChild.data, "\u042E", "Decoded using the wrong encoding.");
    32       is(this.responseText.indexOf("\u042E"), 51, "Bad responseText");
    33       SimpleTest.finish();
    34     }
    35   }
    36   xhr.open("GET", "file_bug692434.xml");
    37   xhr.send();
    38 }
    40 </script>
    41 </pre>
    42 </body>
    43 </html>

mercurial