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 <head>
4 <title>Test for bug 544642</title>
5 <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
6 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
7 </head>
8 <body>
9 <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=544642"
10 target="_blank" >Mozilla Bug 544642</a>
11 <p id="display"></p>
12 <iframe id=iframe></iframe>
13 <pre id="test">
14 <script class="testbody" type="application/javascript;version=1.8">
15 SimpleTest.waitForExplicitFinish();
16 var gen = runTest();
18 addLoadEvent(function() { gen.next(); });
20 function runTest() {
21 var iframe = $('iframe');
22 iframe.onerror = function() { gen.send("error"); };
23 iframe.onload = function() { gen.send("load"); };
25 iframe.src = "data:text/plain,hello";
26 is((yield), "load", "plaintext data");
28 iframe.src = "file://foo/bar";
29 is((yield), "error", "file");
31 // We should do this test too, however it brings up a modal dialog which
32 // we can't dismiss.
33 //iframe.src = "http:////";
34 //is((yield), "error", "invalid http");
36 SimpleTest.finish();
38 yield undefined;
39 }
41 </script>
42 </pre>
43 </body>
44 </html>