Thu, 15 Jan 2015 21:03:48 +0100
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=484396
5 -->
6 <head>
7 <title>Test for Bug 484396</title>
8 <script type="application/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=484396">Mozilla Bug 484396</a>
13 <p id="display"></p>
14 <div id="content" style="display: none">
16 </div>
17 <pre id="test">
18 <script type="application/javascript">
19 SimpleTest.waitForExplicitFinish();
21 var msg = 'xhr.open() succeeds with empty url';
22 var xhr = new XMLHttpRequest();
24 try {
25 xhr.open('GET', '');
26 ok(true, msg);
27 } catch (e) {
28 ok(false, msg);
29 }
31 xhr.onerror = function () {
32 ok(false, 'xhr.send() succeeds with empty url');
33 }
35 xhr.onreadystatechange = function () {
36 if (4 == xhr.readyState) {
37 is(xhr.status, 200, 'xhr.status is 200 OK');
38 ok(-1 < xhr.responseText.indexOf('Bug 484396'), 'xhr.responseText contains the calling page');
40 SimpleTest.finish();
41 }
42 };
44 xhr.send('');
45 </script>
46 </pre>
47 </body>
48 </html>