From: C. Scott Ananian
Date: Wed, 8 Jul 2015 21:56:54 +0000 (-0400)
Subject: Sync up with Parsoid parserTests.
X-Git-Tag: 1.31.0-rc.0~10845^2
X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/categories/modifier.php?a=commitdiff_plain;h=1c4a8ff314ae894a5dae23cd1c6b76b4e82bac49;p=lhc%2Fweb%2Fwiklou.git
Sync up with Parsoid parserTests.
This now aligns with Parsoid commit 34bd76a1747816ed96952ce81ce2fafa751dbb21
Change-Id: Iabf427db488251e26d55a0eb68b282eccd9eb8df
---
diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt
index 1670fe4cc5..b3944fb99f 100644
--- a/tests/parser/parserTests.txt
+++ b/tests/parser/parserTests.txt
@@ -118,6 +118,13 @@ Template:echo_with_div
{{{1}}}
!! endarticle
+!! article
+Template:blank_param
+!! text
+{{{1}}}
+{{{}}}
+!! endarticle
+
!! article
Template:table_attribs
!! text
@@ -165,6 +172,13 @@ Template:table_cells
{{table_attribs}}||style='color:red;'|''Bar''||style='color:brown;'|''Foo'' and Baz
!! endarticle
+!! article
+Template:PartialTable
+!! text
+{|
+|-
+!! endarticle
+
!! article
Template:image_attribs
!! text
@@ -1425,6 +1439,16 @@ parsoid=html2wt
* </nowiki> tag
!! end
+!! test
+T93824: Put escaped HTML tags inside nowiki
+!! options
+parsoid=html2wt
+!! html
+
<h2>foo</h2>
+!! wikitext
+
foo
+!! end
+
!! test
T71950: 1. Put nowiki as close to cause as possible, even with non-quote escapable chars
!! options
@@ -1483,6 +1507,30 @@ parsoid=html2wt
{{echo|a }}}
!! end
+!! test
+Cases where "!!" needs nowiki protection
+!! options
+parsoid=html2wt
+!! html
+
+
this needs protection !! here
+
+
+
+
this does not need
+protection !! here
+
+!! wikitext
+{|
+!this needs protection !! here
+|}
+
+{|
+!this does not need
+protection !! here
+|}
+!! end
+
###
### Comments
###
@@ -1587,8 +1635,10 @@ Comment whitespace
Comment semantics and delimiters
!! wikitext
-!! html
+!! html/php
+!! html/parsoid
+
!! end
!! test
@@ -1596,8 +1646,11 @@ Comment semantics and delimiters, redux
!! wikitext
-!! html
+!! html/php
+!! html/parsoid
+
!! end
!! test
@@ -1607,39 +1660,68 @@ Comment semantics and delimiters: directors cut
everything starting with < followed by !-- until the first -- and > we see,
that wouldn't be valid XML however, since in XML -- has to terminate a comment
-->-->
-!! html
+!! html/php
-->
+!! html/parsoid
+
-->
!! end
!! test
Comment semantics: nesting
!! wikitext
-->
-!! html
+!! html/php
-->
+!! html/parsoid
+
-->
!! end
+# Parsoid closes the unclosed comment, even if it means a slight
+# round-trip diff.
!! test
Comment semantics: unclosed comment at end
+!! options
+parsoid=wt2html,html2html
!! wikitext
!! end
-# Bug 58184: document parsoid's behaviour
!! test
-Suppress comment closing tag in lenient browsers
-!! options
-parsoid=wt2html,html2html
+Comment semantics: normalize comments to play nice with XML and browsers
!! wikitext
- think this is closed -->
+ think this is closed -->
+ This would normally be text -->
+ As would this -->
+
+
+But this is not a comment.
!! html/php
+
But this is not a comment.
+
+!! html/parsoid
+
+
+
+
+
+
But this is not a comment.
+!! end
+!! test
+Comment semantics: round-trip even text which contains encoded -->
+!! wikitext
+
!! html/parsoid
-
+
!! end
!! test
@@ -1683,9 +1765,10 @@ parsoid=wt2html,wt2wt
*a
*b
!! html
-
+
a
+
b
@@ -1894,7 +1977,7 @@ a [[Category:A1]] [[Category:A2]]
[[Category:A4]]
!! html/parsoid
a
-
+
!! end
!! test
@@ -1904,7 +1987,7 @@ parsoid=wt2html
!! wikitext
[[Category:A1]]a
!! html/parsoid
-
a
+
a
!! end
###
@@ -2671,7 +2754,7 @@ parsoid
!! wikitext
{{echo|a : b}}
!! html
-
!! end
+!! test
+Templates: Preserve blank parameter names in other positions
+!! wikitext
+{{blank_param|bar|=foo}}
+!! html/php
+
bar
+foo
+
+!! html/parsoid
+
bar
+foo
+!! end
+
###
### Parsoid-centric tests for testing RT edge cases for pre
###
@@ -3136,9 +3232,9 @@ parsoid=wt2html,wt2wt
!! wikitext
[[Category:foo]]
{{echo| [[Category:foo]]}}
-!! html
-
-
+!! html/parsoid
+
+
!! end
!! test
@@ -3149,9 +3245,20 @@ parsoid=wt2html,wt2wt
[[Category:foo]] a
[[Category:foo]] {{echo|b}}
!! html
-
- a
- b
+
a
+ b
+!! end
+
+!! test
+Indent-Pre: Newlines in comments shouldn't affect sol state
+!! wikitext
+a b
+!! html/parsoid
+
a b
!! end
###
@@ -4006,6 +4113,9 @@ Definition Lists: Mixed Lists: Test 11
# Another case where tidy converts a
to a
(but Parsoid doesn't).
+# From whitelist:
+# * The test is wrong, there are two colons where there should be :;
+# * The PHP parser is wrong to close the
after the
containing the
.
!! test
Definition Lists: Weird Ones: Test 1
!! wikitext
@@ -4063,7 +4173,7 @@ Definition Lists: Weird Ones: Test 1
+!! wikitext
+[[Foo|Bar]]
+[[Foo|Bar]]
+[[wikipedia:Foo|Bar]]
+[[wikipedia:Foo|Bar]]
+
+[[wikipedia:European_Robin|European Robin]]
+[[wikipedia:European_Robin|European Robin]]
+!! end
+
+!! test
+mw:ExtLink linking to a interwiki URL can be round-tripped losslessly (T94723)
+!! options
+parsoid=wt2wt
!! wikitext
-[[MediaWiki:Badtitletext|Manual]]
+[http://en.wikipedia.org/wiki/European_Robin European Robin]
+!! html/parsoid
+THIS SECTION IS NOT USED (but Parsoid won't run the test without it)
!! end
+
###
### Quotes
###
@@ -5280,7 +5430,9 @@ Plain ''italic'''s plain
Bold tag left open
Italic tag left open
Normal text.
-
This year's election should beat last year's.
+
+
+
This year's election should beat last year's.
Toms car is bigger than Susans.
Plain italic's plain
@@ -5480,6 +5632,7 @@ Simple table but with multiple dashes for row wikitext
!! end
+
!! test
Multiplication table
!! wikitext
@@ -5600,6 +5753,69 @@ Accept "||" in indented table headings
!! end
+!! test
+Accept "!!" in templates
+!! wikitext
+{|
+!a {{echo|b!!c}}
+|}
+!! html/php
+
+
+
a b
+
c
+
+
+!! html/parsoid
+
+
a b
c
+!! end
+
+!! test
+Accept "!!" in table headings after newline
+!! wikitext
+{|
+!a
+b!!c
+|}
+!! html/php
+
+
+
a
+
b!!c
+
+
+
+!! html/parsoid
+
+
a
+
b!!c
+
+!! end
+
+!! test
+Accept "!!" in table data of mixed wikitext / html syntax
+!! wikitext
+{|
+!a
+
b!!c
+|}
+!! html+tidy
+
+
+
a
+
+
+
b!!c
+
+
+!! html/parsoid
+
+
a
+
b!!c
+
+!! end
+
!! test
Accept empty attributes in td/th cells (td/th cells starting with leading ||)
!! wikitext
@@ -5746,6 +5962,26 @@ Invalid attributes in table cell (bug 1830)
!! end
+!! test
+Table cell attributes: Pipes protected by nowikis should be treated as a plain character
+!! wikitext
+{|
+| title="foo" |bar
+| title="foo|" |bar
+| title="foo|" bar
+|}
+!! html
+
+
+
bar
+
+
bar
+
+
title="foo|" bar
+
+
+!! end
+
# The "|}" to close the table is missing from the input, so parsoid's
# *2wt modes will fail.
!! test
@@ -5892,6 +6128,35 @@ Indented table markup mixed with indented pre content (proposed in bug 6200)
!! end
+!! test
+4. Template-generated table cell attributes and cell content inside a templated table
+!! wikitext
+{{tbl-start}}
+!align=center {{table_header_cells}}
+|-
+|align=center {{table_cells}}
+{{tbl-end}}
+!! html/php
+
+
+
Foo
+
Bar
+
Foo and Baz
+
+
+
Foo
+
Bar
+
Foo and Baz
+
+
+!! html/parsoid
+
+
Foo
Bar
Foo and Baz
+
+
Foo
Bar
Foo and Baz
+
+!! end
+
!! test
Table with row followed by newlines and table heading
!! wikitext
@@ -7125,7 +7390,7 @@ title=[[User:test/123]]
!! end
!! test
@@ -7515,7 +7780,6 @@ Blah blah blah
[[ es :Spanish]]
[[ ZH :Chinese]]
[[es:Foo_bar]]
-[[es:Foo bar]]
!! html/php
Blah blah blah
@@ -7524,7 +7788,21 @@ Blah blah blah
-
+!! end
+
+!! test
+Space and question mark encoding in interlanguage links (T95473)
+!! options
+parsoid=wt2html,wt2wt,html2html
+!! wikitext
+Blah blah blah
+[[es:Foo bar?]]
+!! html/php
+
Blah blah blah
+
+!! html/parsoid
+
Blah blah blah
+
!! end
!! test
@@ -7702,12 +7980,10 @@ Blah blah blah
!! test
1. Simple redirect to page
-!! options
-parsoid
!! wikitext
#REDIRECT [[Main Page]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
@@ -7718,12 +7994,22 @@ parsoid
!! end
+# Not a valid redirect in PHP (although perhaps it was, once upon a time)
+# This tests the Parsoid bail-out code.
!! test
3. Other redirect variants
!! wikitext
#REDIRECT [[[[Bar]]]]
!! html/parsoid
-
+
REDIRECT [[[[Bar]]]]
+!! end
+
+!! test
+4. Redirect to a templated destination
+!! wikitext
+#REDIRECT [[{{echo|Foo}}bar]]
+!! html/parsoid
+
!! end
!! test
@@ -7732,7 +8018,7 @@ Empty redirect
parsoid=wt2html,wt2wt
!! wikitext
#REDIRECT [[]]
-!! html
+!! html/parsoid
REDIRECT [[]]
!! end
@@ -7745,8 +8031,8 @@ Optional colon in #REDIRECT
parsoid=wt2html,html2html
!! wikitext
#REDIRECT:[[Main Page]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
@@ -7761,8 +8047,8 @@ parsoid=wt2html,html2html
#REDIRECT
:
[[Main Page]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
@@ -7773,89 +8059,90 @@ Piped link in #REDIRECT
parsoid=wt2html
!! wikitext
#REDIRECT [[Main Page|bar]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
-Redirect to category
+Redirect to category (T104502)
!! options
-parsoid=wt2wt,wt2html
+parsoid=wt2html,wt2wt
!! wikitext
#REDIRECT [[Category:Foo]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
-Redirect to category with URL encoding
+Redirect to category with URL encoding (T104502)
!! options
parsoid=wt2html
!! wikitext
#REDIRECT [[Category%3AFoo]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
Redirect to category page
-!! options
-parsoid
!! wikitext
#REDIRECT [[:Category:Foo]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
Redirect to image page (1)
-!! options
-parsoid
!! wikitext
#REDIRECT [[File:Wiki.png]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
Redirect to image page (2)
-!! options
-parsoid
!! wikitext
#REDIRECT [[Image:Wiki.png]]
-!! html
-
+!! html/parsoid
+
!! end
+# html2wt disabled because wts serializes as "#REDIRECT [[:en:File:Wiki.png]]"
+# Next test confirms this.
!! test
-Redirect to language
+Redirect to language (1) (T104918)
!! options
-parsoid
+parsoid=wt2html,wt2wt,html2html
!! wikitext
#REDIRECT [[en:File:Wiki.png]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
-Redirect to interwiki
-!! options
-parsoid
+Redirect to language (2) (T104918)
+!! wikitext
+#REDIRECT [[:en:File:Wiki.png]]
+!! html/parsoid
+
+!! end
+
+!! test
+Redirect to interwiki (T104918)
!! wikitext
#REDIRECT [[meatball:File:Wiki.png]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
Non-English #REDIRECT
!! options
-parsoid
language=is
!! wikitext
#TILVÃSUN [[Main Page]]
-!! html
-
+!! html/parsoid
+
!! end
!! test
@@ -7874,8 +8161,8 @@ some text
New redirect
!! options
parsoid=html2wt
-!! html
-
!! end
!! test
@@ -8258,11 +8545,15 @@ List items are not parsed correctly following a
block (bug 785)
*
foo
*
bar
* zar
-!! html
+!! html/php
foo
bar
zar
+!! html/parsoid
+
foo
+
bar
+
zar
!! end
!! test
@@ -9642,9 +9933,11 @@ Template with default value (value set)
Template redirect
!! wikitext
{{templateredirect}}
-!! html
+!! html/php
(test)
+!! html/parsoid
+
!! end
!! test
@@ -9882,6 +10175,24 @@ Template with targets containing wikilinks
!! end
+!! article
+Template:''
+!! text
+bar
+!! endarticle
+
+!! test
+Templates: Double quotes as template target
+!! wikitext
+foo {{''}} baz
+!! html/php
+
foo bar baz
+
+!! html/parsoid
+
foo bar baz
+
+!! end
+
!! article
Template:MSGNW test
!! text
@@ -10669,6 +10980,24 @@ Templates: Support for templates generating attributes and content
!! end
+!! test
+3. Entities and nowikis inside templated attributes should be handled correctly inside templated tables
+!! wikitext
+{{tbl-start}}
+|{{table_attribs_3}}
+{{tbl-end}}
+!! html/php
+
+
+
Foo
+
+
+!! html/parsoid
+
+
Foo
+
+!! end
+
!!test
Templates: HTML Tables: 1. Generating start of a HTML table
!! wikitext
@@ -10896,6 +11225,46 @@ Templates: Wiki Tables: 6. Templated tags, templated td-tags
!!end
+## This test case is very specific to Parsoid's internals
+## and is hence only tested for Parsoid's code. Parsoid uses
+## a marker tag for tags and they are expanded
+## much later. We are verifying that this tag usage
+## doesn't prevent foster parenting.
+!!test
+Templates: Wiki Tables: 7. Fosterable s should get fostered
+!!wikitext
+{{PartialTable}}foo
+|}
+
+
+!!html/parsoid
+[1]
+!!end
+
+!! test
+Templates: Wiki Tables: 8. Fosterable meta-tags should get fostered
+!! wikitext
+{{echo|
+{{{!}}
+{{!}}-}}
+
+|foo
+
+{{!}}}
+!! html/parsoid
+
+
+
+
+
foo
+
+
+!! end
+
!!test
Templates: Lists: Multi-line list-items via templates
!! wikitext
@@ -11921,7 +12290,7 @@ parsoid=wt2html,wt2wt,html2html
This is a caption
!! html/parsoid
-This is a caption
+This is a caption
!! end
!! test
@@ -11932,7 +12301,7 @@ parsoid=wt2html,wt2wt,html2html
This is a caption
!! html/parsoid
-This is a caption
+This is a caption
!! end
!! test
@@ -11989,7 +12358,7 @@ thumbsize=220
!! html/parsoid
123456
123
456
-
123
456
+
123
456
!! end
!! test
@@ -12011,7 +12380,7 @@ Image with multiple widths -- use last
!! html/parsoid
-
+
!! end
!! test
@@ -12027,7 +12396,7 @@ thumbsize=220
!! html/parsoid
-caption
+caption
!! end
@@ -12043,9 +12412,9 @@ Image with width attribute at different positions
!! html/parsoid
-Caption
-Caption
-Caption
+Caption
+Caption
+Caption
!! end
# a sad bit of backward-compatibility
@@ -12061,7 +12430,7 @@ parsoid=wt2html,wt2wt,html2html
!! html/parsoid
-
+
!! end
!! test
@@ -12187,7 +12556,7 @@ parsoid=wt2html,wt2wt,html2html
Title
!! html/parsoid
-Title
+Title
!! end
!! test
@@ -12334,9 +12703,9 @@ parsoid=wt2html,wt2wt,html2html
!! html/parsoid
-
-
-
+
+
+
!! end
!! test
@@ -12372,9 +12741,9 @@ parsoid=wt2html,wt2wt,html2html
!! html/parsoid
-This is a caption with another inside it!
+This is a caption with another inside it!
!! end
!! test
@@ -12750,7 +13119,7 @@ Image: caption containing leading space
bar
!! html/parsoid
- bar
+ bar
!!end
!! test
@@ -12769,7 +13138,7 @@ and some more text.]]
This is an example image thumbnail caption with a table
Foo
Bar
Foo1
Bar1
and some more text.
!! html/parsoid
-
This is an example image thumbnail caption with a table
+
This is an example image thumbnail caption with a table
Foo
Bar
@@ -12786,7 +13155,7 @@ Bug 3090: External links other than http: in image captions
!! html/parsoid
-This caption has irc and Secure ext links in it.
+This caption has irc and Secure ext links in it.
!! end
!! test
@@ -12828,7 +13197,7 @@ language=es
caption
!! html/parsoid
-caption
+caption
!! end
!! test
@@ -12842,7 +13211,7 @@ parsoid=wt2html,wt2wt,html2html
!! html/parsoid
-
+
!! end
# Note that 'right' is the default alignment, despite the misspelled 'righ' below
@@ -12863,9 +13232,9 @@ parsoid=wt2html,wt2wt,html2html
!! end
!! test
@@ -12921,7 +13290,7 @@ parsoid=wt2wt,wt2html,html2html
!! wikitext
[[Image:Foobar.jpg|middle|50px]]
!! html/parsoid
-
+
!! end
!! test
@@ -12930,7 +13299,7 @@ Parsoid-specific image handling - simple image with size and middle alignment
!! wikitext
[[File:Foobar.jpg|50px|middle]]
!! html/parsoid
-
+
!! end
!! test
@@ -12941,7 +13310,7 @@ parsoid=wt2html,wt2wt,html2html
!! wikitext
[[Image:Foobar.jpg|50px|middle]]
!! html/parsoid
-
+
!! end
!! test
@@ -12965,7 +13334,7 @@ Parsoid-specific image handling - thumbnail with halign, valign, and caption
!! wikitext
[[File:Foobar.jpg|left|baseline|thumb|caption content]]
!! html/parsoid
-caption content
+caption content
!! end
!! test
@@ -12974,7 +13343,7 @@ Parsoid-specific image handling - thumbnail with halign, valign, and caption
!! wikitext
[[File:Foobar.jpg|thumb|left|baseline|caption content]]
!! html/parsoid
-caption content
+caption content
!! end
!! test
@@ -12982,7 +13351,7 @@ Parsoid-specific image handling - thumbnail with specific size, halign, valign,
!! wikitext
[[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
!! html/parsoid
-caption
+caption
!! end
!! test
@@ -13050,7 +13419,7 @@ foo
bar
!! html/parsoid
foo
-This caption has a
unbalanced tag in it.
+This caption has a
unbalanced tag in it.
bar
!! end
@@ -13061,7 +13430,7 @@ parsoid=wt2html,wt2wt
!! wikitext
[[File:Foobar.jpg|thumb|]]
!! html/parsoid
-
+
!! end
# empty captions don't get serialized unless we're in the "round trip" case
@@ -13088,7 +13457,7 @@ Parsoid-specific image handling - whitespace caption
!! wikitext
[[File:Foobar.jpg|thumb| ]]
!! html/parsoid
-
+
!! end
!! test
@@ -13435,6 +13804,152 @@ Bar
!! end
+## The whitespace on the empty line is part of the test. Please do not delete
+!! test
+1. Categories and newlines: All preceding newlines should be suppressed (courtesy bug 87)
+!! options
+parsoid=wt2html,wt2wt
+!! wikitext
+This
+
+[[Category:Foo]] and this should be part of same paragraph (not an indent-pre)
+
+{{echo|[[Category:Foo]] and so should this!}}
+!! html
+
This and this should be part of same paragraph (not an indent-pre) and so should this!
+
+!! html/parsoid
+
This
+
+ and this should be part of same paragraph (not an indent-pre)
+
+ and so should this!
+!! end
+
+## Parsoid will not try to wt2wt this while preserving newlines because
+## it suppresses excess newlines within list items -- and we don't want to
+## introduce a special case just for categories, which is, in reality somewhat
+## odd behavior -- categories are unlikely to be used in list items like this
+## in top-level pages and are only likely to show up in template-generated
+## list items where this RT-ing is a non-issue.
+##
+## The whitespace on the empty line is part of the test. Please do not delete
+!! test
+2. Categories and newlines: All preceding newlines should be suppressed (courtesy bug 87)
+!! options
+parsoid=wt2html
+!! wikitext
+* This
+
+[[Category:Foo]] and this should be part of the same list item
+* So should this
+
+{{echo|[[Category:Foo]] and this should be part of the same list item}}
+!! html
+
This and this should be part of the same list item
+
So should this and this should be part of the same list item
+!! html/parsoid
+
+
This and this should be part of the same list item
+
So should this and this should be part of the same list item
+
+!! end
+
+## Newlines and categories that follow the last item of a list
+## are treated differently because this (list followed by categories)
+## is an extremely common pattern on wikis.
+!! test
+3. Categories and newlines: newline suppression for last list item should RT properly
+!! wikitext
+* a
+* b
+
+[[Category:Foo]]
+
+[[Category:Bar]]
+[[Category:Baz]]
+!! html/parsoid
+
a
+
b
+
+
+
+
+
+!! end
+
+!! test
+4. Categories and newlines: newline suppression for last list item should RT properly
+!! wikitext
+* a
+**** b
+
+[[Category:Foo]]
+!! html/parsoid
+
a
+
b
+
+
+!! end
+
+## only wt2html for this to make sure the algo only applies to the rightmost path
+!! test
+5. Categories and newlines: migrateTrailingCategories dom pass should only run on the rightmost path of nested lists
+!! options
+parsoid=wt2html
+!! wikitext
+* a
+** b
+[[Category:Foo]]
+* c
+** d
+[[Category:Foo]]
+!! html/parsoid
+
a
+
b
+
+
c
+
d
+
+!! end
+
+!! test
+6. Categories and newlines: migrateTrailingCategories dom pass should not migrate categories not preceded by newlines
+!! wikitext
+* a [[Category:Foo]]
+!! html/parsoid
+
a
+!! end
+
+# This test also demonstrates because of newline+category tunneling
+# through the list hander, template wrapping doesn't expand to the
+# containing list when the list item swallows the category.
+!! test
+7. Categories and newlines: migrateTrailingCategories dom pass should leave template content alone
+!! wikitext
+* {{echo|a
+[[Category:Foo]]}}
+!! html/parsoid
+
a
+
+!! end
+
+!! test
+8. Categories and newlines: migrateTrailingCategories dom pass should not get tripped by intervening templates
+!! wikitext
+* a
+
+{{echo|[[Category:Foo]]
+[[Category:Bar]]}}
+[[Category:Baz]]
+!! html/parsoid
+
a
+
+
+
+
+!! end
+
!! test
Parsoid: Serialize link to category page with colon escape
!! options
@@ -13450,15 +13965,21 @@ parsoid
!! end
+# html2wt localizes the "Category" namespace.
+# XXX the element needs an empty data-parsoid attribute, or
+# else the html2html test fails because spaces are inserted.
!! test
-Parsoid: Link prefix/suffixes aren't applied to category links
+Link prefix/suffixes aren't applied to category links
!! options
parsoid=wt2html,wt2wt,html2html
language=is
!! wikitext
x[[Category:Foo]]y
-!! html
-
xy
+!! html/php
+
xy
+
+!! html/parsoid
+
xy
!! end
!! test
@@ -17564,7 +18085,7 @@ Images with the "|" character in the comment
!!end
!!test
References: 1. references tag without any refs should be handled properly
-!!options
-parsoid
!! wikitext
-!! html
-
+!! html/parsoid
+
!!end
!!test
References: 2. references tag with group only outputs references from that group
-!!options
-parsoid
!! wikitext
A foo
B bar
@@ -20614,26 +21133,24 @@ C baz
-!! html
-
!!end
!!test
References: 3. ref list should be cleared after processing references
-!!options
-parsoid
!! wikitext
A foo
@@ -20642,23 +21159,21 @@ A foo
B bar
-!! html
-
!!end
!!test
References: 4. only referenced group should be cleared after processing references
-!!options
-parsoid
!! wikitext
A afoo
B bfoo
@@ -20668,23 +21183,21 @@ B bfoo
C cfoo
-!! html
-
!!end
!!test
References: 5. ref tags in references should be processed while ignoring all other content
-!!options
-parsoid
!! wikitext
A
B bar
@@ -20693,30 +21206,26 @@ B barfoo
This should just get lost.
-!! html
-
!!end
!! test
References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
-!! options
-parsoid
!! wikitext
A foo bar for a
B
@@ -20726,30 +21235,28 @@ B foo
-!! html
-
!! end
!! test
References: 8. T88019: Remove s from templates inside that's itself inside a template
-!! options
-parsoid
!! wikitext
X{{echo|foo {{echo|bar}} and {{echo|baz}} boo}}
-!! html
-
!!end
@@ -20759,18 +21266,16 @@ X{{echo|foo {{echo|bar}} and {{echo|baz}} boo}}
# wt2wt.
!! test
References: 9. Generate missing references list at the end
-!! options
-parsoid
!! wikitext
A foo
B bar
-!! html
-
!! end
+!! test
+T97430: Don't emit empty nowiki pairs around marker meta tags
+!! options
+parsoid=html2wt
+!! html
+
*This is a long sentence here that will make the nowiki algo split up the nowikis into multiple pairs
+|** Make this another long long long sentence forcing the nowiki algo to split up the nowikis.
+!! wikitext
+*This is a long sentence here that will make the nowiki algo split up the nowikis into multiple pairs
+|** Make this another long long long sentence forcing the nowiki algo to split up the nowikis.
+!! end
+
+!! test
+Unclosed xmlish element in table line shouldn't eat end delimiters
+!! wikitext
+{|
+|
+|}
+!! html/php
+
+
+
<foo
+
+
bar>
+
+
+!! html/parsoid
+
+
<foo
+
bar>
+
+!! end
+
#### --------------- Links ----------------
#### 1. Quote marks in link text
#### 2. Wikilinks: Escapes needed
@@ -22102,10 +22642,10 @@ parsoid=html2wt,wt2wt
a' foo bara' foo barfoo x'bar
-'foo[1]
+'foo[1]
'foo
!! end
@@ -22256,7 +22796,7 @@ parsoid
!! wikitext
[[File:Foobar.jpg|thumb|caption]]
!! html/parsoid
- caption
+ caption
!! end
!! test
@@ -22269,7 +22809,22 @@ parsoid=html2wt
==foo==
!! end
+!!test
+T95794: nowiki escaping should account for leading space at start-of-line in an indent-pre block
+!! options
+parsoid
+!! wikitext
+ * foo
+ * bar
+!! html
+
+* foo
+* bar
+
+!! end
+
#### --------------- Behavior Switches --------------------
+
!! test
1. Valid behavior switches should be escaped
!! options
@@ -22294,6 +22849,29 @@ __TOO__
__|__
!! end
+# We use indent-pre as an indirect way to test for sol-transparent behavior.
+!! test
+Behavior switches should be SOL-transparent
+!! wikitext
+ __TOC__
+
+
+ __TOO__
+
+ __TOC__ foo
+
+__TOC__ bar
+!! html/parsoid
+
+
+
+
__TOO__
+
+
foo
+
+
bar
+!! end
+
#### --------------- HTML tags ---------------
#### 1. a tags
#### 2. other tags
@@ -22615,6 +23193,8 @@ bar
!!end
+# Note that the "style" attribute is really a template parameter here.
+# The = would have to be {{=}} if you wanted the literal.
!!test
Empty TD followed by TD with tpl-generated attribute
!! wikitext
@@ -22775,7 +23355,7 @@ Multi-line image caption generated by templates with/without trailing newlines
New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
!! options
parsoid=html2wt
-!! html
+!! html/parsoid
new para
new heading
@@ -22792,12 +23372,10 @@ new para
## a Parsoid serializer test, marking this Parsoid only
!!test
Improperly nested inline or quotes tags with whitespace in between
-!!options
-parsoid
!! wikitext
x
''' ''x''' ''
-!! html
+!! html/parsoid
!!end
@@ -22823,7 +23399,7 @@ Ensure ParagraphWrapper can deal with stray closing pre tags
parsoid=wt2html
!! wikitext
plain text
-!! html
+!! html/parsoid
plain text
!!end
@@ -22833,7 +23409,7 @@ plain text
parsoid=wt2html
!! wikitext
hi
ho
-!! html
+!! html/parsoid
hi
ho
@@ -22849,7 +23425,7 @@ parsoid=wt2html,wt2wt
|| ||
a
-!! html
+!! html/parsoid
|| ||
a
@@ -22862,7 +23438,7 @@ Encapsulation properly handles null DSR information from foster box
parsoid=wt2html,wt2wt
!! wikitext
{{echo|
!!end
+# Note that the wt is broken on purpose: the = should be {{=}} if you
+# don't want it to be a template parameter key.
!!test
8. Encapsulate foster-parented transclusion content
!!options
@@ -23007,8 +23585,11 @@ parsoid=wt2wt,wt2html
|-
|b
|}
-!! html
-