Merge InlineBidiResolver end-of-line Blink test case
authorbfulgham@apple.com <bfulgham@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 15 Jul 2016 17:41:56 +0000 (17:41 +0000)
committerbfulgham@apple.com <bfulgham@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 15 Jul 2016 17:41:56 +0000 (17:41 +0000)
https://bugs.webkit.org/show_bug.cgi?id=126201
<rdar://problem/27331789>

Test case is from the Blink change (patch by <igor.o@chromium.org>):
<https://chromium.googlesource.com/chromium/blink/+/d34ca9bbbdf71905d61aa45def30063311508a64>

* fast/text/international/bidi-crash-reached-end-of-line-expected.txt: Added.
* fast/text/international/bidi-crash-reached-end-of-line.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@203283 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/fast/text/international/bidi-crash-reached-end-of-line-expected.txt [new file with mode: 0644]
LayoutTests/fast/text/international/bidi-crash-reached-end-of-line.html [new file with mode: 0644]

index b4d489a..60e6edb 100644 (file)
@@ -1,5 +1,17 @@
 2016-07-15  Brent Fulgham  <bfulgham@apple.com>
 
+        Merge InlineBidiResolver end-of-line Blink test case
+        https://bugs.webkit.org/show_bug.cgi?id=126201
+        <rdar://problem/27331789>
+
+        Test case is from the Blink change (patch by <igor.o@chromium.org>):
+        <https://chromium.googlesource.com/chromium/blink/+/d34ca9bbbdf71905d61aa45def30063311508a64>
+
+        * fast/text/international/bidi-crash-reached-end-of-line-expected.txt: Added.
+        * fast/text/international/bidi-crash-reached-end-of-line.html: Added.
+
+2016-07-15  Brent Fulgham  <bfulgham@apple.com>
+
         Merge Blink test case
         https://bugs.webkit.org/show_bug.cgi?id=123870
 
diff --git a/LayoutTests/fast/text/international/bidi-crash-reached-end-of-line-expected.txt b/LayoutTests/fast/text/international/bidi-crash-reached-end-of-line-expected.txt
new file mode 100644 (file)
index 0000000..3e69545
--- /dev/null
@@ -0,0 +1 @@
+This test has passed if it doesn't crash under ASAN
diff --git a/LayoutTests/fast/text/international/bidi-crash-reached-end-of-line.html b/LayoutTests/fast/text/international/bidi-crash-reached-end-of-line.html
new file mode 100644 (file)
index 0000000..ee59934
--- /dev/null
@@ -0,0 +1,40 @@
+<body onload="runTest();">
+        <script>
+        if (window.testRunner)
+           testRunner.dumpAsText();
+        function reference(domNode)
+        {
+            this.domNode = domNode;
+        }
+        function walk(a, currentPrefix, index, domNode)
+        {
+            if (domNode == null)
+                return;
+            newPrefix = currentPrefix + "_" + index;
+            walk(a, currentPrefix, index + 1, domNode.nextSibling);
+            walk(a, newPrefix, 0, domNode.firstChild);
+            a[newPrefix] = new reference(domNode);
+        }
+        function clearAllNodes()
+        {
+            var a = new Array();
+            walk(a, "", 0, document.body);
+            for (key in a)
+            {
+                document.body.offsetTop;
+                child = a[key].domNode.parentNode.removeChild(a[key].domNode);
+            }
+        }
+        function runTest() {
+          clearAllNodes();
+          document.body = document.createElement("body");
+          document.body.innerHTML = "This test has passed if it doesn't crash under ASAN";
+        }
+        </script>>>>>>><legend style="widows:994907373; padding-right:493197256%; ">><h1 accesskey="5N'" class="Y990" dir="rtl" style="direction:rtl; line-height:20034836;" id="8" lang="tr" >>>>><abbr title="@u\>qr$^" accesskey="" tabindex="2147483648" title="\ 5\" title="QA'>9JQT" style="border-top-width:medium; white-space:pre-line; " id="b71pkZOs" >>><center>,</center>
+<dl>></dl>
+<output>nnlN8rc<b></b>
+</output>
+> lang="xh" ></i>
+<output></output>
+</abbr>
+<sup>>
\ No newline at end of file