Wed, 31 Dec 2014 06:09:35 +0100
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=499538
5 -->
6 <head>
7 <title>Test for Bug 499538</title>
8 <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
9 <script type="text/javascript" src="/tests/SimpleTest/WindowSnapshot.js"></script>
10 <script type="application/javascript" src="/tests/SimpleTest/EventUtils.js"></script>
11 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
12 </head>
13 <body onload="test()">
14 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=499538">Mozilla Bug 499538</a>
15 <p id="display"></p>
16 <div id="content">
17 <input type="text" id="testInput">
18 </div>
19 <pre id="test">
20 <script class="testbody" type="text/javascript">
22 /** Test for Bug 499538 **/
24 SimpleTest.waitForExplicitFinish();
26 function test() {
27 var textInput = $("testInput");
28 var s1, s2, s3, equal, str1, str2;
30 textInput.focus();
31 synthesizeKey("a", { });
32 synthesizeKey(" ", { });
33 synthesizeKey("\u0639", { });
34 synthesizeKey("\u063A", { });
35 synthesizeKey(" ", { });
36 synthesizeKey("b", { });
37 s1 = snapshotWindow(window);
39 textInput.select();
40 synthesizeKey("a", { });
41 synthesizeKey(" ", { });
42 synthesizeKey(" ", { });
43 synthesizeKey("b", { });
44 synthesizeKey("VK_LEFT", { });
45 synthesizeKey("VK_LEFT", { });
46 synthesizeKey("\u0639", { });
47 synthesizeKey("\u063A", { });
48 s2 = snapshotWindow(window);
50 [equal, str1, str2] = compareSnapshots(s1, s2, true);
51 ok(equal, "Arabic text between English words not connected: expected " +
52 str1 + " but got " + str2);
54 SimpleTest.finish();
55 }
57 </script>
58 </pre>
59 </body>
60 </html>