From d3d9b4f09c820e97b57011569f40f474360dac5d Mon Sep 17 00:00:00 2001 From: Subramanya Sastry Date: Fri, 28 Dec 2018 10:27:08 -0600 Subject: [PATCH] Sync up with Parsoid parserTests.txt This now aligns with Parsoid commit 391acbfe0c93d632727ea08cd2a10b4dba8c257f Change-Id: I0e8c154eaf118f9cd5b58d657f64d0829a65c8f0 --- tests/parser/parserTests.txt | 89 +++++++++++++++++++++++++++++------- 1 file changed, 73 insertions(+), 16 deletions(-) diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt index a7ae000ae4..a73d036b48 100644 --- a/tests/parser/parserTests.txt +++ b/tests/parser/parserTests.txt @@ -1249,6 +1249,17 @@ parsoid=wt2html,wt2wt !! end +!! test +Bold conversion test +!! wikitext +a b'''c ''d e'''f'' g h'''i ''j +!! options +parsoid=wt2html +!! html+tidy +

a b'c d ef g hi j +

+!! end + ### ### Non-html5 tags ### @@ -3605,7 +3616,7 @@ parsoid=wt2html,html2html b

foo
!! end -!!test +!! test 3c. Indent-Pre and block tags (pre-content on separate line) !! wikitext

@@ -3638,7 +3649,7 @@ foo foo -!! html +!! html/php

foo

@@ -3667,7 +3678,36 @@ foo foo -!!end +!! html/parsoid +

+ foo +

+ +
+
foo
+
+ +
+
foo
+
+ +
+

foo

+
+ +
+
foo
+
+
+ +
+
foo
+
+ + +!! end !! test 4. Indent-Pre and extension tags @@ -6818,8 +6858,8 @@ Table cell attributes: Pipes protected by nowikis should be treated as a plain c !! html/parsoid - - + +
barbar title="foo|" bar
bartitle="foo|" bar
!! end @@ -8414,9 +8454,24 @@ title=[[0]] inside a link !! wikitext [[Main Page]] [[Main Page|the main page [it's not very good]]] -!! html +!! html/php+tidy

[[Main Page]] the main page [it's not very good]

+!! html/parsoid +

[[Main Page]] the main page [it's not very good]

+!! end + +## Parsoid doesn't get this right and even fails wt2html because, when doing the +## normalization for comparison, the html serialization / re-parse doesn't +## roundtrip. This is T49963 +!! test +
 inside a link
+!! wikitext
+[[Main
 Page
]] [[Main Page|the main page
[it's not very good]
]] +!! html/php+tidy +

[[Main

 Page

]] the main page

[it's not very good]
+!! html/parsoid +

[[Main

 Page

]] the main page

[it's not very good]

!! end !! test @@ -8831,6 +8886,8 @@ Interwiki link with fragment (T4130)

!! end +## The interwiki case here continued to be legacy escaped because of the +## default setting of $wgExternalInterwikiFragmentMode !! test Link scenarios with escaped fragments !! options @@ -8849,7 +8906,7 @@ wgFragmentMode=[ 'html5', 'legacy' ] !! html/parsoid

#Is this great? Foo#Is this great? -meatball:Foo#Is this great?

+meatball:Foo#Is this great?

!! end !! test @@ -12745,7 +12802,7 @@ array (

But if the broken language converter markup is inside an extension tag, nothing bad happens:

  • foo-{bar}bat
  • -
  • foo-{bar}bat
  • +
  • foo-{bar}bat
  • foo-{bar}bat
  • foo-{bar}bat
@@ -18066,17 +18123,17 @@ parsoid=wt2html,html2html !! end # FIXME Parsoid doesn't actually match PHP here. -# Probably we should use the synthetic or -# extensions for this test, which are enabled when running parser tests. !! test Extension tag in attribute value +!! options +wgRawHtml=1 !! wikitext -ok -!! html/php+disabled -

<span title="<translate>123</translate>">ok</span> +ok +!! html/php+tidy +

ok

!! html/parsoid -

ok

+

ok

!! end !! test @@ -18791,7 +18848,7 @@ T5244: HTML attribute safety (extension; safe)
!! html/parsoid -
+
!! end !! test @@ -18802,7 +18859,7 @@ T5244: HTML attribute safety (extension; unsafe)
!! html/parsoid -
+
!! end # More MSIE fun discovered by Tom Gilder -- 2.20.1