|
1 <!DOCTYPE HTML> |
|
2 <html> |
|
3 <!-- |
|
4 https://bugzilla.mozilla.org/show_bug.cgi?id=445886 |
|
5 --> |
|
6 <head> |
|
7 <meta http-equiv="Content-type" content="text/html; charset=UTF-8"> |
|
8 <title>Test for Unicode non-characters</title> |
|
9 <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> |
|
10 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> |
|
11 <script type="text/javascript"> |
|
12 function Inject() |
|
13 { |
|
14 $("display").innerHTML = "Evil"; |
|
15 } |
|
16 </script> |
|
17 </head> |
|
18 <body Â>onload="Inject()"> |
|
19 <pre id="test"> |
|
20 <script class="testbody" type="text/javascript"> |
|
21 |
|
22 /** test that UTF-8 decoding resynchronizes after incomplete sequences */ |
|
23 function test() |
|
24 { |
|
25 is($("display").innerHTML, "All good.", "No overconsumption"); |
|
26 SimpleTest.finish(); |
|
27 } |
|
28 |
|
29 addLoadEvent(function() { |
|
30 setTimeout(test, 0); |
|
31 }); |
|
32 SimpleTest.waitForExplicitFinish(); |
|
33 </script> |
|
34 </pre> |
|
35 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=445886">Mozilla Bug 445886</a> |
|
36 <p id="display">All good.</p> |
|
37 <div id="content" style="display: none"></div> |
|
38 </body> |
|
39 </html> |