Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / text / line-breaks-after-hyphen-before-number.html
blobffd66099f29231b238d207604d79054cf864c7d5
1 <html>
2 <head>
3 <title>Line breaks after hyphen before number</title>
4 <style>
5 .test { width: 1px; }
6 </style>
7 </head>
8 <body>
9 <script>
10 if (window.testRunner)
11 testRunner.dumpAsText();
13 var tests = [
14 "$-1111111",
15 "-2222.2222",
16 "-.33333333",
17 "4444444-4444444",
18 "5555555-abcdefg",
19 "abcdefg-6666666"
22 // Each of the above tests should look like corresponding expectation below.
23 var expected = [
24 "$-1111111",
25 "-2222.2222",
26 "-.33333333",
27 "4444444-<br>4444444",
28 "5555555-<br>abcdefg",
29 "abcdefg-<br>6666666"
32 var allSuccess = true;
33 for (var i = 1; i <= tests.length; ++i) {
34 document.write("Test " + i + ":");
35 document.write("<div class='test' id='test" + i + "'>" + tests[i - 1] + "</div>");
36 document.write("Expected:<div id='expected" + i + "'>" + expected[i - 1] + "</div>");
37 var success = getComputedStyle(document.getElementById("test" + i, "")).height
38 == getComputedStyle(document.getElementById("expected" + i, "")).height;
39 document.write(success ? "PASS" : "FAIL");
40 document.write("<br><br>");
41 allSuccess = allSuccess && success;
44 document.write("Summary: " + (allSuccess ? "PASS" : "FAIL"));
45 </script>
46 </body>
47 </html>