1 # MediaWiki Parser test cases
2 # Some taken from http://meta.wikimedia.org/wiki/Parser_testing
3 # All (C) their respective authors and released under the GPL
5 # The syntax should be fairly self-explanatory.
7 # Currently supported test options:
8 # One of the following three:
10 # (default) generate HTML output
11 # pst apply pre-save transform
12 # msg apply message transform
14 # Plus any combination of these:
16 # cat add category links
17 # ill add inter-language links
18 # subpage enable subpages (disabled by default)
19 # noxml don't check for XML well formdness
20 # title=[[XXX]] run test using article title XXX
21 # language=XXX set content language to XXX for this test
22 # variant=XXX set the variant of language for this test (eg zh-tw)
23 # disabled do not run test
24 # parsoid parsoid-specific options (not run by PHP parser unless
25 # the test includes an html/php section)
26 # php php-only test (not run by the parsoid parser unless
27 # the test includes an html/parsoid section)
28 # showtitle make the first line the title
29 # comment run through Linker::formatComment() instead of main parser
30 # local format section links in edit comment text as local links
31 # notoc disable table of contents
32 # thumbsize=NNN set the default thumb size to NNNpx for this test
34 # You can also set the following parser properties via test options:
35 # wgEnableUploads, wgAllowExternalImages, wgMaxTocLevel,
36 # wgLinkHolderBatchSize, wgRawHtml
38 # For testing purposes, temporary articles can created:
39 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
40 # where '/' denotes a newline.
42 # This is the standard article assumed to exist.
67 MediaWiki:bad image list
69 * [[File:Bad.jpg]] except [[Nasty page]]
103 Template:echo_with_span
109 Template:echo_with_div
121 Template:table_attribs
124 |</noinclude>style="color: red"| Foo
130 {{table_attribs}} || Bar || Baz
134 Template:image_attribs
137 [[File:foobar.jpg|</noinclude>right|Caption text<noinclude>]]</noinclude>
171 This is a simple paragraph.
173 <p>This is a simple paragraph.
178 Paragraphs with extra newline spacing
201 Paragraphs with newline spacing with comment lines in between
209 <!--foo--><!--More than 1 comment, still stripped-->
213 <!--foo--> <!----> <!-- bar -->
274 Paragraphs with newline spacing with non-empty white-space lines in between
301 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
309 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
348 Extra newlines: More paragraphs with indented comment
363 Extra newlines followed by heading
378 <h1><span class="mw-headline" id="b">b</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: b">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
379 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
382 <h1><span class="mw-headline" id="b_2">b</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: b">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
387 Extra newlines between heading and content are swallowed
395 <h1><span class="mw-headline" id="b">b</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: b">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
396 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
403 http://fr.wikipedia.org/wiki/🍺
404 <!-- EasterEgg we love beer, better be able be able to link to it -->
406 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
429 * plain''italic''plain
430 * plain''italic''plain''italic''plain
431 * plain'''bold'''plain
432 * plain'''bold'''plain'''bold'''plain
433 * plain''italic''plain'''bold'''plain
434 * plain'''bold'''plain''italic''plain
435 * plain''italic'''bold-italic'''italic''plain
436 * plain'''bold''bold-italic''bold'''plain
437 * plain'''''bold-italic'''italic''plain
438 * plain'''''bold-italic''bold'''plain
439 * plain''italic'''bold-italic'''''plain
440 * plain'''bold''bold-italic'''''plain
441 * plain l'''italic''plain
442 * plain l''''bold''' plain
447 <li> plain<i>italic</i>plain
449 <li> plain<i>italic</i>plain<i>italic</i>plain
451 <li> plain<b>bold</b>plain
453 <li> plain<b>bold</b>plain<b>bold</b>plain
455 <li> plain<i>italic</i>plain<b>bold</b>plain
457 <li> plain<b>bold</b>plain<i>italic</i>plain
459 <li> plain<i>italic<b>bold-italic</b>italic</i>plain
461 <li> plain<b>bold<i>bold-italic</i>bold</b>plain
463 <li> plain<i><b>bold-italic</b>italic</i>plain
465 <li> plain<b><i>bold-italic</i>bold</b>plain
467 <li> plain<i>italic<b>bold-italic</b></i>plain
469 <li> plain<b>bold<i>bold-italic</i></b>plain
471 <li> plain l'<i>italic</i>plain
473 <li> plain l'<b>bold</b> plain
479 # this example taken from the [[simple:Moon]] article (bug 47326)
481 Italics and possessives (1)
483 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
485 <p>obtained by <i><a href="/index.php?title=Lunar_Prospector&action=edit&redlink=1" class="new" title="Lunar Prospector (page does not exist)">Lunar Prospector</a>'</i>s gamma-ray spectrometer
489 # this example taken from [[en:Flaming Pie]] (bug 49926)
491 Italics and possessives (2)
493 '''''Flaming Pie''''' is ... released in 1997. In ''Flaming Pie'''s liner notes
495 <p><i><b>Flaming Pie</b></i> is ... released in 1997. In <i>Flaming Pie'</i>s liner notes
499 # this example taken from [[en:Dictionary]] (bug 49926)
501 Italics and possessives (3)
503 The first monolingual dictionary written in a Romance language was ''Sebastián Covarrubias''' ''Tesoro de la lengua castellana o española'', published in 1611 in Madrid. In 1612 the first edition of the ''Vocabolario dell'[[Accademia della Crusca]]'', for Italian, was published. In 1690 in Rotterdam was published, posthumously, the ''Dictionnaire Universel''.
505 <p>The first monolingual dictionary written in a Romance language was <i>Sebastián Covarrubias'</i> <i>Tesoro de la lengua castellana o española</i>, published in 1611 in Madrid. In 1612 the first edition of the <i>Vocabolario dell'<a href="/index.php?title=Accademia_della_Crusca&action=edit&redlink=1" class="new" title="Accademia della Crusca (page does not exist)">Accademia della Crusca</a></i>, for Italian, was published. In 1690 in Rotterdam was published, posthumously, the <i>Dictionnaire Universel</i>.
511 ### 2-quote opening sequence tests
514 Italics and bold: 2-quote opening sequence: (2,2)
524 Italics and bold: 2-quote opening sequence: (2,3)
535 # same html as previous, but wikitext adjusted to match parsoid html2wt
537 Italics and bold: 2-quote opening sequence: (2,3) w/ nowiki
539 ''<nowiki>foo'</nowiki>''
547 Italics and bold: 2-quote opening sequence: (2,4)
558 # same html as previous, but wikitext adjusted to match parsoid html2wt
560 Italics and bold: 2-quote opening sequence: (2,4) w/ nowiki
562 ''<nowiki>foo''</nowiki>''
569 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
571 Italics and bold: 2-quote opening sequence: (2,5)
584 # same html as previous, but wikitext adjusted to match parsoid html2wt
586 Italics and bold: 2-quote opening sequence: (2,5+3) w/ nowiki
588 ''foo'''''<nowiki/>'''
599 ### 3-quote opening sequence tests
603 Italics and bold: 3-quote opening sequence: (3,2)
613 Italics and bold: 3-quote opening sequence: (3,3)
623 Italics and bold: 3-quote opening sequence: (3,4)
634 # same html as previous, but wikitext adjusted to match parsoid html2wt
636 Italics and bold: 3-quote opening sequence: (3,4) w/ nowiki
638 '''<nowiki>foo'</nowiki>'''
645 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
647 Italics and bold: 3-quote opening sequence: (3,5)
660 # same html as previous, but wikitext adjusted to match parsoid html2wt
662 Italics and bold: 3-quote opening sequence: (3,5+2) w/ nowiki
664 '''foo'''''<nowiki/>''
675 ### 4-quote opening sequence tests
679 Italics and bold: 4-quote opening sequence: (4,2)
690 # same html as previous, but wikitext adjusted to match parsoid html2wt
692 Italics and bold: 4-quote opening sequence: (4,2) w/ nowiki
694 <nowiki>''</nowiki>''foo''
702 Italics and bold: 4-quote opening sequence: (4,3)
712 Italics and bold: 4-quote opening sequence: (4,4)
723 # same html as previous, but wikitext adjusted to match parsoid html2wt
725 Italics and bold: 4-quote opening sequence: (4,4) w/ nowiki
727 ''''<nowiki>foo'</nowiki>'''
734 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
736 Italics and bold: 4-quote opening sequence: (4,5)
745 <p>'<b>foo</b><i></i>
749 # same html as previous, but wikitext adjusted to match parsoid html2wt
751 Italics and bold: 4-quote opening sequence: (4,5+2) w/ nowiki
753 ''''foo'''''<nowiki/>''
758 <p>'<b>foo</b><i></i>
764 ### 5-quote opening sequence tests
768 Italics and bold: 5-quote opening sequence: (5,2)
779 # same html as previous, but wikitext adjusted to match parsoid html2wt
780 # skipping wt2html and html2html because it wants to put <i> before <b>
782 Italics and bold: 5-quote opening sequence: (5,2+3)
784 parsoid=wt2wt,html2wt
793 Italics and bold: 5-quote opening sequence: (5,3)
804 # same html as previous, but wikitext adjusted to match parsoid html2wt
806 Italics and bold: 5-quote opening sequence: (5,3+2)
816 Italics and bold: 5-quote opening sequence: (5,4)
822 <p><i><b>foo'</b></i>
827 # same html as previous, but wikitext adjusted to match parsoid html2wt
829 Italics and bold: 5-quote opening sequence: (5,4+2) w/ nowiki
831 '''''<nowiki>foo'</nowiki>'''''
833 <p><i><b>foo'</b></i>
839 Italics and bold: 5-quote opening sequence: (5,5)
848 ### multiple quote sequences in a line
851 Italics and bold: multiple quote sequences: (2,4,2)
857 <p><i>foo'<b>bar</b></i>
862 # same html as previous, but wikitext adjusted to match parsoid html2wt
864 Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
866 ''<nowiki>foo'</nowiki>'''bar'''''
868 <p><i>foo'<b>bar</b></i>
874 Italics and bold: multiple quote sequences: (2,4,3)
880 <p><i>foo'<b>bar</b></i>
885 # same html as previous, but wikitext adjusted to match parsoid html2wt
887 Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
889 ''<nowiki>foo'</nowiki>'''bar'''''
891 <p><i>foo'<b>bar</b></i>
897 Italics and bold: multiple quote sequences: (2,4,4)
903 <p><i>foo'<b>bar'</b></i>
908 # same html as previous, but wikitext adjusted to match parsoid html2wt
910 Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
912 ''<nowiki>foo'</nowiki>'''<nowiki>bar'</nowiki>'''''
914 <p><i>foo'<b>bar'</b></i>
919 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
921 Italics and bold: multiple quote sequences: (3,4,2)
930 <p><b>foo'</b>bar<i></i>
934 # same html as previous, but wikitext adjusted to match parsoid html2wt
936 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
940 '''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
945 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
950 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
952 Italics and bold: multiple quote sequences: (3,4,3)
961 <p><b>foo'</b>bar<b></b>
965 # same html as previous, but wikitext adjusted to match parsoid html2wt
967 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
969 '''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
974 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
979 ### other quote tests
982 Italics and bold: other quote tests: (2,3,5)
984 ''this is about '''foo's family'''''
986 <p><i>this is about <b>foo's family</b></i>
992 Italics and bold: other quote tests: (2,(3,3),2)
994 ''this is about '''foo's''' family''
996 <p><i>this is about <b>foo's</b> family</i>
1002 Italics and bold: other quote tests: (3,2,3,2)
1006 '''this is about ''foo'''s family''
1008 <p><b>this is about <i>foo</i></b><i>s family</i>
1013 # same html as previous, but wikitext adjusted to match parsoid html2wt
1014 # add 'parsoid' option to use 'parsoid' normalization of the placeholder
1016 Italics and bold: other quote tests: (3,2,3+2+2,2)
1020 '''this is about ''foo'''''<nowiki/>''s family''
1022 <p><b>this is about <i>foo</i></b><i>s family</i>
1028 Italics and bold: other quote tests: (3,2,3,3)
1031 '''this is about ''foo'''s family'''
1033 <p>'<i>this is about </i>foo<b>s family</b>
1039 Italics and bold: other quote tests: (3,(2,2),3)
1041 '''this is about ''foo's'' family'''
1043 <p><b>this is about <i>foo's</i> family</b>
1049 Italicized possessive
1051 The ''[[Main Page]]'''s talk page.
1053 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
1058 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
1059 (Requires tidy for PHP parser output to be fixed up)
1061 parsoid=wt2html,wt2wt
1069 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
1070 <td><i>a</i></td><td><i>b</i></td></tr>
1079 Non-html5 tags should be accepted
1081 <center>''foo''</center>
1083 <font>''foo''</font>
1084 <strike>''foo''</strike>
1087 <center><i>foo</i></center>
1088 <p><big><i>foo</i></big>
1089 <font><i>foo</i></font>
1090 <strike><i>foo</i></strike>
1096 <wbr> is valid wikitext (bug 52468)
1104 # <strike> is HTML4, <s> is HTML4/5.
1106 <s> or <strike> for strikethrough
1108 <strike>strike</strike>
1112 <p><strike>strike</strike>
1118 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
1120 <b→> doesn't work! </b→>
1122 <bä> doesn't work! </bä>
1124 <boo> works fine </boo>
1126 <s.foo>s.foo</s.foo>
1130 <p><b→> doesn't work! </b→>
1131 </p><p><bä> doesn't work! </bä>
1132 </p><p><boo> works fine </boo>
1133 </p><p><s.foo>s.foo</s.foo>
1134 </p><p><sub-ID#1>
1139 Isolated close tags should be treated as literal text (bug 52760)
1146 </p><p><s.foo>s</s>
1151 ### Special characters
1155 Bare pipe character (bug 52363)
1164 Bare pipe character from a template (bug 52363)
1173 ### <nowiki> test cases
1177 <nowiki> unordered list
1179 <nowiki>* This is not an unordered list item.</nowiki>
1181 <p>* This is not an unordered list item.
1188 <nowiki>Lorem ipsum dolor
1196 <p>Lorem ipsum dolor
1209 :There is not nowiki.
1210 :There is <nowiki>nowiki</nowiki>.
1212 #There is not nowiki.
1213 #There is <nowiki>nowiki</nowiki>.
1215 *There is not nowiki.
1216 *There is <nowiki>nowiki</nowiki>.
1219 <dd>There is not nowiki.
1221 <dd>There is nowiki.
1225 <li>There is not nowiki.
1227 <li>There is nowiki.
1231 <li>There is not nowiki.
1233 <li>There is nowiki.
1240 Entities inside <nowiki>
1242 <nowiki><</nowiki>
1249 Entities inside template parameters
1255 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}}]}'>–</span>
1263 Comments and Indent-Pre
1265 <!-- comment 1 --> asdf
1267 <!-- comment 1 --> asdf
1270 <!-- comment 1 --> asdf
1271 <!-- comment 2 -->xyz
1273 <!-- comment 1 --> asdf
1274 <!-- comment 2 --> xyz
1330 asdf<!-- comment 1 -->jkl
1340 <!-- foo --> b <!-- bar -->
1354 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1360 Comment semantics and delimiters
1362 <!-- --><!----><!-----><!------>
1368 Comment semantics and delimiters, redux
1370 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1371 -- foo -- funky huh? ... -->
1377 Comment semantics and delimiters: directors cut
1379 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1380 everything starting with < followed by !-- until the first -- and > we see,
1381 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1389 Comment semantics: nesting
1391 <!--<!-- no, we're not going to do anything fancy here -->-->
1398 Comment semantics: unclosed comment at end
1400 <!--This comment will run out to the end of the document
1406 Comment in template title
1415 Comment on its own line post-expand
1427 Comment on its own line post-expand with non-significant whitespace
1439 Multiple comments should still parse as SOL-transparent
1441 parsoid=wt2html,wt2wt
1444 <!--c2--><!--c3--><!--c4-->*b
1455 ### paragraph wrapping tests
1470 Block tag on one line (<div>)
1482 Block tag on one line (<blockquote>)
1484 a <blockquote>foo</blockquote>
1488 a <blockquote>foo</blockquote>
1494 Block tag on both lines (<div>)
1506 Block tag on both lines (<blockquote>)
1508 a <blockquote>foo</blockquote>
1510 b <blockquote>foo</blockquote>
1512 a <blockquote>foo</blockquote>
1513 b <blockquote>foo</blockquote>
1518 Multiple lines without block tags
1536 Empty lines between lines with block tags
1565 ## PHP parser emits output which is broken
1567 Unclosed HTML p-tags should be handled properly
1574 <div data-parsoid='{"stx":"html"}'><p data-parsoid='{"stx":"html", "autoInsertedEnd":true}'>foo</p></div>
1580 ### Preformatted text
1589 And a [[Main Page|link]]
1595 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1600 Tabs don't trigger preformatted text
1604 This is preformatted text.
1610 <pre>This is preformatted text.
1616 Ident preformatting with inline content
1627 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1644 Regression with preformatted in <center>
1658 Bug 52763: Preformatted in <blockquote>
1664 indented cell (no pre-wrapping!)
1674 <p> indented cell (no pre-wrapping!)
1682 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
1699 Bug 15491: <ins>/<del> in blockquote
1702 Foo <del>bar</del> <ins>baz</ins> quux
1706 <p>Foo <del>bar</del> <ins>baz</ins> quux
1712 # Note that the p-wrapping is newline sensitive, which could be
1713 # considered a bug: tidy will wrap only the 'Foo' in the example
1714 # below in a <p> tag. (see comment 23-25 of bug #6200)
1716 Bug 15491: <ins>/<del> in blockquote (2)
1718 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1721 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1727 <pre> with attributes (bug 3202)
1729 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1731 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1736 <pre> with width attribute (bug 3202)
1738 <pre width="8">Narrow screen goodies</pre>
1740 <pre width="8">Narrow screen goodies</pre>
1745 <pre> with forbidden attribute (bug 3202)
1747 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1749 <pre width="8">Narrow screen goodies</pre>
1754 Entities inside <pre>
1763 <pre> with forbidden attribute values (bug 3202)
1765 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1767 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1772 <nowiki> inside <pre> (bug 13238)
1780 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1788 <pre><nowiki>Foo</nowiki></pre>
1793 <nowiki> and <pre> preference (first one wins)
1824 </pre> inside nowiki
1826 <nowiki></pre></nowiki>
1833 Empty pre; pre inside other HTML tags (bug 54946)
1852 HTML pre followed by indent-pre
1867 <p><pre>foo</pre></p>
1869 <p data-parsoid='{"stx":"html","autoInsertedEnd":true}'></p><pre data-parsoid='{"stx":"html"}'>foo</pre><p data-parsoid='{"autoInsertedStart":true,"stx":"html"}'></p>
1873 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1881 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1891 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1903 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1924 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1928 {{echo| foo}}{{echo| bar}}
1933 {{echo|<!--cmt--> foo}}
1935 <!--cmt-->{{echo| foo}}
1937 {{echo|{{echo| }}bar}}
1955 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1992 Things that look like <pre> tags aren't treated as such
1994 Barack Obama <President> of the United States
1996 <p>Barack Obama <President> of the United States
2001 Parsoid: handle pre with space after attribute
2005 <pre style="width:50%;" >{{echo|foo}}</pre>
2007 <pre style="width:50%;">{{echo|foo}}</pre>
2010 # TODO / maybe: fix wt2wt for this
2012 Parsoid: Don't paragraph-wrap fosterable content
2038 Parsoid: Don't paragraph-wrap fosterable content even if table syntax is unbalanced
2066 #--------------------------------------------------------------------
2067 # Transclusion parameter whitespace stripping tests
2068 # Behavior is different for positional and named parameters
2069 #--------------------------------------------------------------------
2071 Templates: Strip leading and trailing whitespace from named-param values
2075 {{echo|1= {{echo|b}} }}
2096 Templates: Don't strip whitespace from positional-param values
2100 {{echo|{{echo|b}} }}
2143 Templates: Handle empty comment-and-ws-only lines correctly
2146 <!--should be ignored-->
2147 <!--should be ignored as well-->
2156 Templates: Handle comments in the target
2159 <!-- should be ignored -->
2162 {{echo<!-- should be ignored -->
2165 {{echo<!-- should be ignored -->|foo}}
2167 {{<!-- should be ignored -->echo|foo}}
2169 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo\n<!-- should be ignored -->\n","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2171 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo<!-- should be ignored -->\n","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2173 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo<!-- should be ignored -->","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2175 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2178 #--------------------------------------------------------------------
2179 # Transclusion parameter escaping tests
2180 #--------------------------------------------------------------------
2182 Templates: Parsoid parameter escaping test 1
2186 {{echo|[foo]|{{echo|[bar]}}}}
2188 <p about="#mwt1" typeof="mw:Transclusion"
2189 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}}]}'>[foo]</p>
2193 Parsoid: Pipes in external links in template parameter
2197 {{echo|[{{echo|http://example.com}} link]}}
2199 <p><a rel="mw:ExtLink" href="http://example.com" about="#mwt31" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[{{echo|http://example.com}} link]"}},"i":0}}]}'>link</a></p>
2203 Parsoid: pipe in transclusion parameter
2207 {{echo|http://foo.com/a|b}}
2209 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2210 typeof="mw:Transclusion"
2211 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://foo.com/a&#124;b"}},"i":0}}]}'>http://foo.com/a|b</a></p>
2215 Parsoid: Pipe in external link target and content in template parameter
2217 parsoid=html2wt,wt2wt
2219 {{echo|[http://foo.com/a|b a|b]}}
2221 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2222 typeof="mw:Transclusion"
2223 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},
2224 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}}]}'>a|b</a></p>
2228 Templates: Don't escape already nowiki-escaped text in template parameters
2230 parsoid=html2wt,wt2wt
2232 {{echo|foo<nowiki>|</nowiki>bar}}
2233 {{echo|<nowiki><div></nowiki>}}
2234 {{echo|<nowiki></nowiki>}}
2236 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<nowiki>|</nowiki>bar"}},"i":0}}]}'}'>foo</span><span typeof="mw:Nowiki" about="#mwt1">|</span><span about="#mwt1">bar</span>
2237 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt2" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki>&lt;div&gt;</nowiki>"}},"i":0}}]}'><span typeof="mw:Entity"><</span>div<span typeof="mw:Entity">></span></span>
2238 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt3" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki></nowiki>"}},"i":0}}]}'></span>
2244 Templates: '=' char in nested transclusions should not trigger nowiki escapes or conversion to named param
2246 parsoid=html2wt,wt2wt
2248 {{echo|{{echo|1=bar}}}}
2250 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{echo|1=bar}}"}},"i":0}}]}'>bar</p>
2255 Templates parameters with special tokenizing behavior dont get modified because of arg escaping
2261 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a : b"}},"i":0}}]}'>a<span typeof="mw:Placeholder" data-parsoid='{"isDisplayHack":true}'> </span>: b</p>
2265 ### Parsoid-centric tests for testing RT edge cases for pre
2269 1a. Indent-Pre and Comments
2282 1b. Indent-Pre and Comments
2295 1c. Indent-Pre and Comments
2308 1d. Indent-Pre and Comments
2309 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
2322 2a. Indent-Pre and tables
2343 2b. Indent-Pre and tables
2359 2c. Indent-Pre and tables (bug 42252)
2376 3a. Indent-Pre and block tags (single-line html)
2380 c <blockquote> foo </blockquote>
2385 c <blockquote> foo </blockquote>
2386 <pre><span> foo </span>
2391 3b. Indent-Pre and block tags (multi-line html)
2396 <pre>a <span>foo</span>
2403 3c. Indent-Pre and block tags (pre-content on separate line)
2467 4. Indent-Pre and extension tags
2473 a <ul class="gallery mw-gallery-traditional">
2474 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
2475 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
2476 <div class="gallerytext">
2484 Leading pipes outside of tables
2494 Leading pipes outside of tables 2
2508 Leading pipes outside of tables 3
2513 | class="foo bar" | baz
2517 | class="foo bar" | baz
2522 Render paragraphs when indent-pre is suppressed in blocklevels
2539 4. Multiple spaces at start-of-line
2557 ## NOTE: the leading white-space chars on empty line are significant
2559 5a. White-space in indent-pre
2571 ## NOTE: the leading white-space chars on empty line are significant
2573 5b. White-space in indent-pre
2592 5c. White-space in indent-pre
2605 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
2628 7a. Indent-pre and category links
2630 parsoid=wt2html,wt2wt
2632 [[Category:foo]] <!-- No pre-wrapping -->
2633 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
2635 <link rel="mw:PageProp/Category" href="./Category:Foo"> <!-- No pre-wrapping -->
2636 <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":" [[Category:foo]]"}},"i":0}}]}'> </span>
2637 <link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1"> <!-- No pre-wrapping -->
2641 7b. Indent-pre and category links
2643 parsoid=wt2html,wt2wt
2646 [[Category:foo]] {{echo|b}}
2649 <link rel="mw:PageProp/Category" href="./Category:Foo"> a
2651 <link rel="mw:PageProp/Category" href="./Category:Foo"> <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b"}},"i":0}}]}'>b</span></pre>
2655 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
2659 HTML-pre: 1. embedded newlines
2695 HTML-pre: 2: indented text
2708 HTML-pre: 3: other wikitext
2729 ### Definition lists
2737 <dt> name </dt>
2745 Definition list for indentation only
2757 Definition list with no space
2770 Definition list with URL link
2772 ; http://example.com/ : definition
2775 <dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt>
2783 Definition list with bracketed URL link
2785 ;[http://www.example.com/ Example]:Something about it
2788 <dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt>
2789 <dd>Something about it
2796 Definition list with wikilink containing colon
2798 ; [[Help:FAQ]]: The least-read page on Wikipedia
2801 <dt> <a href="/index.php?title=Help:FAQ&action=edit&redlink=1" class="new" title="Help:FAQ (page does not exist)">Help:FAQ</a></dt>
2802 <dd> The least-read page on Wikipedia
2808 # At Brion's and JeLuF's insistence... :)
2810 Definition list with news link containing colon
2812 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
2815 <dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt>
2816 <dd> This isn't even a real newsgroup!
2823 Malformed definition list with colon
2825 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
2828 <dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a> -- don't crash or enter an infinite loop
2835 Definition lists: colon in external link text
2837 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
2840 <dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt>
2841 <dd> OK, I made that up
2848 Definition lists: colon in HTML attribute
2850 ;<b style="display: inline">bold</b>
2853 <dt><b style="display: inline">bold</b>
2860 Definition lists: self-closed tag
2862 ;one<br/>two : two-line fun
2865 <dt>one<br />two </dt>
2873 Bug 11748: Literal closing tags
2877 <dd>test test test test test</dd>
2879 <dd>test test test test test</dd>
2884 <dd>test test test test test</dd>
2886 <dd>test test test test test</dd>
2892 Definition and unordered list using wiki syntax nested in unordered list using html tags.
2895 ; term : description
2901 <dt> term </dt>
2915 Definition list with empty definition and following paragraph
2930 Nested definition lists using html syntax
2947 Definition Lists: No nesting: Multiple dd's
2965 Definition Lists: Indentation: Regular
2987 Definition Lists: Indentation: Missing 1st level
3007 Definition Lists: Indentation: Multi-level indent
3025 Definition Lists: Hacky use to indent tables
3032 should be left alone
3034 <dl><dd><dl><dd><table>
3039 </td></tr></table></dd></dl></dd></dl>
3041 should be left alone
3047 Definition Lists: Hacky use to indent tables (WS-insensitive)
3056 <dd> <table><tr><td>a</td></tr></table> </dd>
3059 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
3060 ## as an empty dt item. It also ignores all but the last ";" when followed
3061 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
3062 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
3065 ## Ex: ";;t2 ::d2" is transformed into:
3077 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
3078 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
3089 ## All Parsoid only definition list tests have this difference.
3091 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
3092 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
3095 Table / list interaction: indented table with lists in table contents
3121 </td></tr></table></dd></dl>
3126 Table / list interaction: lists nested in tables nested in indented lists
3157 </td></tr></table></dd></dl>
3168 Definition Lists: Nesting: Multi-level (Parsoid only)
3198 Definition Lists: Nesting: Test 2 (Parsoid only)
3218 Definition Lists: Nesting: Test 3 (Parsoid only)
3246 Definition Lists: Nesting: Test 4
3267 ## The Parsoid team believes the following three test exposes a
3268 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
3269 ## wrong to close the <dl> after the <dt> containing the <ul>.)
3271 Definition Lists: Mixed Lists: Test 1
3311 Definition Lists: Mixed Lists: Test 2
3330 Definition Lists: Mixed Lists: Test 3
3355 Definition Lists: Mixed Lists: Test 4
3376 Definition Lists: Mixed Lists: Test 5
3397 Definition Lists: Mixed Lists: Test 6
3424 Definition Lists: Mixed Lists: Test 7
3443 Definition Lists: Mixed Lists: Test 8
3467 Definition Lists: Mixed Lists: Test 9
3484 Definition Lists: Mixed Lists: Test 10
3502 # The Parsoid team disagrees with the PHP parser's seemingly-random
3503 # rules regarding dd/dt on the next two tests. Parsoid is more
3504 # consistent, and recognizes the shared nesting and keeps the
3505 # still-open tags around until the nesting is complete.
3508 Definition Lists: Mixed Lists: Test 11
3561 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3562 <dd data-parsoid='{"stx":"row"}'>bar</dd>
3566 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3567 <dd data-parsoid='{"stx":"row"}'>baz</dd>
3577 Definition Lists: Weird Ones: Test 1
3579 *#;*::;; foo : bar (who uses this?)
3590 <dt> bar (who uses this?)
3624 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3625 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd>
3640 External links: non-bracketed
3642 Non-bracketed: http://example.com
3644 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3649 External links: numbered
3651 Numbered: [http://example.com]
3652 Numbered: [http://example.net]
3653 Numbered: [http://example.com]
3655 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
3656 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
3657 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
3662 External links: specified text
3664 Specified text: [http://example.com link]
3666 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
3671 External links: trail
3673 Linktrails should not work for external links: [http://example.com link]s
3675 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
3680 External links: dollar sign in URL
3682 http://example.com/1$2345
3684 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
3689 External links: dollar sign in URL (named)
3691 [http://example.com/1$2345]
3693 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
3698 External links: open square bracket forbidden in URL (bug 4377)
3700 http://example.com/1[2345
3702 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
3707 External links: open square bracket forbidden in URL (named) (bug 4377)
3709 [http://example.com/1[2345]
3711 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
3716 External links: nowiki in URL link text (bug 6230)
3718 [http://example.com/ <nowiki>''example site''</nowiki>]
3720 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
3725 External links: newline forbidden in text (bug 6230 regression check)
3727 [http://example.com/ first
3730 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
3736 External links: Pipe char between url and text
3738 [http://example.com | link]
3740 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
3745 External links: protocol-relative URL in brackets
3747 [//example.com/ Test]
3749 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
3754 External links: protocol-relative URL in brackets without text
3758 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
3763 External links: protocol-relative URL in free text is left alone
3767 <p>//example.com/Foo
3772 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
3774 foo//example.com/Foo
3776 <p>foo//example.com/Foo
3783 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3785 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
3790 External image from https
3792 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3794 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
3799 External image (when not allowed)
3801 wgAllowExternalImages=0
3803 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3805 <p>External image: <a rel="nofollow" class="external free" href="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png">http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png</a>
3810 Link to non-http image, no img tag
3812 Link to non-http image, no img tag: ftp://example.com/test.jpg
3814 <p>Link to non-http image, no img tag: <a rel="nofollow" class="external free" href="ftp://example.com/test.jpg">ftp://example.com/test.jpg</a>
3819 External links: terminating separator
3821 Terminating separator: http://example.com/thing,
3823 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
3828 External links: intervening separator
3830 Intervening separator: http://example.com/1,2,3
3832 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
3837 External links: old bug with URL in query
3839 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
3841 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
3846 External links: old URL-in-URL bug, mixed protocols
3848 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
3850 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
3855 External links: URL in text
3857 URL in text: [http://example.com http://example.com]
3859 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3864 External links: Clickable images
3866 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
3868 <p>ja-style clickable images: <a rel="nofollow" class="external text" href="http://example.com"><img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" /></a>
3873 External links: raw ampersand
3875 Old & use: http://x&y
3877 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3882 External links: encoded ampersand
3884 Old & use: http://x&y
3886 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3891 External links: encoded equals (bug 6102)
3893 http://example.com/?foo=bar
3895 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
3900 External links: [raw ampersand]
3902 Old & use: [http://x&y]
3904 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3909 External links: [encoded ampersand]
3911 Old & use: [http://x&y]
3913 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3918 External links: [encoded equals] (bug 6102)
3920 [http://example.com/?foo=bar]
3922 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3927 External links: [IDN ignored character reference in hostname; strip it right off]
3929 [http://e‌xample.com/]
3931 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
3935 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
3936 # Where an external link could easily circumvent the sanitization of the text of
3937 # a link like this (where an IDN-ignore character is in the URL somewhere), this
3938 # test demands a higher standard. That's a bit strange.
3942 # http://example.com -> [http://example.com|http://example.com]
3943 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
3945 # The first example is sanitized, but the second is not. Any security benefits
3946 # from this production are trivial to circumvent. Either remove this test and
3947 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
3948 # the test accordingly.
3953 External links: IDN ignored character reference in hostname; strip it right off
3955 http://e‌xample.com/
3957 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
3962 External links: www.jpeg.org (bug 554)
3966 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
3971 External links: URL within URL (original bug 2)
3973 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
3975 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
3980 BUG 361: URL inside bracketed URL
3982 [http://www.example.com/foo http://www.example.com/bar]
3984 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
3989 BUG 361: URL within URL, not bracketed
3991 http://www.example.com/foo?=http://www.example.com/bar
3993 <p><a rel="nofollow" class="external free" href="http://www.example.com/foo?=http://www.example.com/bar">http://www.example.com/foo?=http://www.example.com/bar</a>
3998 BUG 289: ">"-token in URL-tail
4000 http://www.example.com/<hello>
4002 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
4007 BUG 289: literal ">"-token in URL-tail
4009 http://www.example.com/<b>html</b>
4011 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
4016 BUG 289: ">"-token in bracketed URL
4018 [http://www.example.com/<hello> stuff]
4020 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
4025 BUG 289: literal ">"-token in bracketed URL
4027 [http://www.example.com/<b>html</b> stuff]
4029 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
4034 BUG 289: literal double quote at end of URL
4036 http://www.example.com/"hello"
4038 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
4043 BUG 289: literal double quote in bracketed URL
4045 [http://www.example.com/"hello" stuff]
4047 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
4052 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
4054 [http://www.example.com test]
4056 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
4061 External links: link text with spaces
4063 [http://www.example.com a b c]
4064 [http://www.example.com ''a'' ''b'']
4066 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
4067 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
4072 External links: wiki links within external link (Bug 3695)
4074 [http://example.com [[wikilink]] embedded in ext link]
4076 <p><a rel="nofollow" class="external text" href="http://example.com"></a><a href="/index.php?title=Wikilink&action=edit&redlink=1" class="new" title="Wikilink (page does not exist)">wikilink</a><a rel="nofollow" class="external text" href="http://example.com"> embedded in ext link</a>
4079 <p><a rel="mw:ExtLink" href="http://example.com"></a><a rel="mw:WikiLink" href="./Wikilink">wikilink</a><span> embedded in ext link</span></p>
4083 BUG 787: Links with one slash after the url protocol are invalid
4087 [http:/example.com title]
4089 <p>http:/example.com
4090 </p><p>[http:/example.com title]
4095 Bracketed external links with template-generated invalid target
4097 [{{echo|http:/example.com}} title]
4099 <p>[http:/example.com title]
4104 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
4106 ''[http://example.com text'']
4107 [http://example.com '''text]'''
4108 ''Something [http://example.com in italic'']
4109 ''Something [http://example.com mixed''''', even bold]'''
4110 '''''Now [http://example.com both''''']
4112 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
4113 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
4114 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
4115 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
4116 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
4122 Bug 4781: %26 in URL
4124 http://www.example.com/?title=AT%26T
4126 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
4130 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
4131 # % is actually legal in HTML5. Any change in output would need testing though.
4133 Bug 4781, 5267: %25 in URL
4135 http://www.example.com/?title=100%25_Bran
4137 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a>
4142 Bug 4781, 5267: %28, %29 in URL
4144 http://www.example.com/?title=Ben-Hur_%281959_film%29
4146 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">http://www.example.com/?title=Ben-Hur_%281959_film%29</a>
4152 Bug 4781: %26 in autonumber URL
4154 [http://www.example.com/?title=AT%26T]
4156 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
4161 Bug 4781, 5267: %26 in autonumber URL
4163 [http://www.example.com/?title=100%25_Bran]
4165 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
4170 Bug 4781, 5267: %28, %29 in autonumber URL
4172 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
4174 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
4180 Bug 4781: %26 in bracketed URL
4182 [http://www.example.com/?title=AT%26T link]
4184 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
4189 Bug 4781, 5267: %26 in bracketed URL
4191 [http://www.example.com/?title=100%25_Bran link]
4193 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
4198 Bug 4781, 5267: %28, %29 in bracketed URL
4200 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
4202 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
4207 External link containing double-single-quotes in text '' (bug 4598 sanity check)
4209 Some [http://example.com/ pretty ''italics'' and stuff]!
4211 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
4216 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
4218 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
4220 <p><i>Some </i><a rel="nofollow" class="external text" href="http://example.com/"><i>pretty </i>italics<i> and stuff</i></a><i>!</i>
4225 External link containing double-single-quotes with no space separating the url from text in italics
4227 [http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm''La muerte de Casagemas'' (1901) en el sitio de [[Museo Picasso (París)|Museo Picasso]].]
4229 <p><a rel="nofollow" class="external text" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de <a href="/index.php?title=Museo_Picasso_(Par%C3%ADs)&action=edit&redlink=1" class="new" title="Museo Picasso (París) (page does not exist)">Museo Picasso</a>.</a>
4232 <p><a rel="mw:ExtLink" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de </a><a rel="mw:WikiLink" href="./Museo_Picasso_(París)">Museo Picasso</a><span>.</span></p>
4236 External link with comments in link text
4238 [http://www.google.com Google <!-- comment -->]
4240 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
4245 URL-encoding in URL functions (single parameter)
4247 {{localurl:Some page|amp=&}}
4249 <p>/index.php?title=Some_page&amp=&
4254 URL-encoding in URL functions (multiple parameters)
4256 {{localurl:Some page|q=?&=&}}
4258 <p>/index.php?title=Some_page&q=?&amp=&
4265 http://example.com/index.php?foozoid%5B%5D=bar
4267 http://example.com/index.php?foozoid[]=bar
4269 <p><a rel="nofollow" class="external free" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a>
4270 </p><p><a rel="nofollow" class="external free" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a>
4275 IPv6 urls (bug 21261)
4279 http://[2404:130:0:1000::187:2]/index.php
4281 <p><a rel="nofollow" class="external free" href="http://[2404:130:0:1000::187:2]/index.php">http://[2404:130:0:1000::187:2]/index.php</a>
4286 Non-extlinks in brackets
4295 [{{echo|foo}} ''bar'']
4296 [{{echo|foo}}l's] errand
4297 [{{echo|foo}}l's errand]
4299 [url=http://example.com]
4312 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
4317 Percent encoding in external links
4319 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
4321 <p><a rel="nofollow" class="external text" href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a>
4324 <p><a rel="mw:ExtLink"
4325 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
4329 Use url link syntax for links where the content is equal the link target
4333 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4336 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
4340 Parenthesis in external links, especially URL links
4344 http://example.com/test)
4346 http://example.com/(test)
4348 http://example.com/((test)
4350 (http://example.com/(test))
4352 (http://example.com/(test)))))
4354 http://example.com/a)b
4356 [http://example.com) foo]
4358 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4359 </p><p><a rel="nofollow" class="external free" href="http://example.com/test">http://example.com/test</a>)
4360 </p><p><a rel="nofollow" class="external free" href="http://example.com/(test)">http://example.com/(test)</a>
4361 </p><p><a rel="nofollow" class="external free" href="http://example.com/((test)">http://example.com/((test)</a>
4362 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test))">http://example.com/(test))</a>
4363 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test)))))">http://example.com/(test)))))</a>
4364 </p><p><a rel="nofollow" class="external free" href="http://example.com/a)b">http://example.com/a)b</a>
4365 </p><p><a rel="nofollow" class="external text" href="http://example.com)">foo</a>
4368 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)</p>
4369 <p><a rel="mw:ExtLink" href="http://example.com/test">http://example.com/test</a>)</p>
4370 <p><a rel="mw:ExtLink" href="http://example.com/(test)">http://example.com/(test)</a></p>
4371 <p><a rel="mw:ExtLink" href="http://example.com/((test)">http://example.com/((test)</a></p>
4372 <p>(<a rel="mw:ExtLink" href="http://example.com/(test))">http://example.com/(test))</a></p>
4373 <p>(<a rel="mw:ExtLink" href="http://example.com/(test)))))">http://example.com/(test)))))</a></p>
4374 <p><a rel="mw:ExtLink" href="http://example.com/a)b">http://example.com/a)b</a></p>
4375 <p><a rel="mw:ExtLink" href="http://example.com)">foo</a></p>
4379 Parenthesis in external links, w/ transclusion or comment
4381 (http://example.com/{{echo|hi}})
4383 (http://example.com<!-- hi -->)
4385 <p>(<a rel="nofollow" class="external free" href="http://example.com/hi">http://example.com/hi</a>)
4386 </p><p>(<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4389 <p>(<a data-mw='{"attribs":[[{"txt":"href"},{"html":"http://example.com/<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;hi&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[20,31,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">hi</span>"}]]}' typeof="mw:ExpandedAttrs" about="#mwt2" rel="mw:ExtLink" href="http://example.com/hi" data-parsoid='{"stx":"url","a":{"href":"http://example.com/hi"},"sa":{"href":"http://example.com/{{echo|hi}}"}}'>http://example.com/hi</a>)</p>
4391 <p>(<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url","a":{"href":"http://example.com"},"sa":{"href":"http://example.com<!-- hi -->"}}'>http://example.com</a>)</p>
4401 Normal text. '''Bold text.''' Normal text. ''Italic text.''
4403 Normal text. '''''Bold italic text.''''' Normal text.
4405 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
4406 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
4411 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
4412 # parser strips. The wikitext contains just the first half of the bold
4415 Unclosed and unmatched quotes
4417 '''''Bold italic text '''with bold deactivated''' in between.'''''
4419 '''''Bold italic text ''with italic deactivated'' in between.'''''
4423 ..spanning two paragraphs (should not work).'''
4425 '''Bold tag left open
4427 ''Italic tag left open
4431 <!-- Unmatching number of opening, closing tags: -->
4432 '''This year''''s election ''should'' beat '''last year''''s.
4434 ''Tom'''s car is bigger than ''Susan'''s.
4436 Plain ''italic'''s plain
4438 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
4439 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
4440 </p><p><b>Bold text..</b>
4441 </p><p>..spanning two paragraphs (should not work).
4442 </p><p><b>Bold tag left open</b>
4443 </p><p><i>Italic tag left open</i>
4445 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
4446 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
4447 </p><p>Plain <i>italic'</i>s plain
4450 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
4451 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
4452 </p><p><b>Bold text..</b>
4453 </p><p>..spanning two paragraphs (should not work).<b></b>
4454 </p><p><b>Bold tag left open</b>
4455 </p><p><i>Italic tag left open</i>
4457 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
4458 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
4459 </p><p>Plain <i>italic'</i>s plain
4466 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
4469 # This should not produce <table></table> as <table><tr><td></td></tr></table>
4470 # is the bare minimum required by the spec, see:
4471 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
4472 # Parsoid team replies: empty table tags are legal in HTML5
4474 A table with no data.
4487 A table with stray table end tags on start tag line (wt2html)
4491 {|style="color: red;"|}
4493 {|style="color: red;" |}
4497 {|style="color: red;"|} id="foo"
4501 {|style="color: red;" |} id="foo"
4505 <table style="color: red;"></table>
4507 <table style="color: red;">
4513 <table style="color: red;" id="foo">
4519 <table style="color: red;" id="foo">
4528 A table with no data (take 2)
4536 # A table with nothing but a caption is invalid XHTML, we might want to render
4537 # this as <p>caption</p>
4538 # Parsoid team replies: table with only a caption is legal in HTML5
4540 A table with nothing but a caption
4548 </caption><tr><td></td></tr></table>
4551 <table><caption> caption</caption></table>
4555 A table with caption with default-spaced attributes and a table row
4558 |+ style="color: red;" | caption1
4564 <caption style="color: red;"> caption1
4573 A table with captions with non-default spaced attributes and a table row
4576 |+style="color: red;"|caption2
4577 |+ style="color: red;"| caption3
4583 <caption style="color: red;">caption2
4585 <caption style="color: red;"> caption3
4594 Table td-cell syntax variations
4598 | foo bar foo || baz
4599 | style='color:red;' | baz
4600 | style='color:red;' || baz
4607 <td> foo bar foo </td>
4610 <td style="color:red;"> baz
4612 <td> style='color:red;' </td>
4640 Simple table but with multiple dashes for row wikitext
4658 Multiplication table
4660 {| border="1" cellpadding="2"
4661 |+Multiplication table
4663 ! × !! 1 !! 2 !! 3
4681 <table border="1" cellpadding="2">
4682 <caption>Multiplication table
4729 Accept "||" in table headings
4744 Accept "||" in indented table headings
4754 </th></tr></table></dd></dl>
4759 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
4776 Accept "| !" at start of line in tables (ignore !-attribute)
4780 | !style="color:red" | bar
4792 Allow +/- in 2nd and later cells in a row, in 1st cell when td-attrs are present, or in 1st cell when there is a space between "|" and +/-
4796 |style='color:red;'|+1
4797 |style='color:blue;'|-1
4809 <td style="color:red;">+1
4811 <td style="color:blue;">-1
4835 |rowspan=2| Cell 2, row 1 (and 2)
4846 <td rowspan="2"> Cell 2, row 1 (and 2)
4864 {| bgcolor=#ABCDEF border=2
4869 |the original table again
4877 <table bgcolor="#ABCDEF" border="2">
4885 <td>the original table again
4891 Invalid attributes in table cell (bug 1830)
4906 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
4909 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
4913 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
4914 <td>]" onmouseover="alert(document.cookie)">test
4923 Indented table markup mixed with indented pre content (proposed in bug 6200)
4928 Text that should be rendered preformatted
4936 <pre>Text that should be rendered preformatted
4945 Template-generated table cell attributes and cell content
4954 <td style="color: red"> Foo
4956 <td style="color: red"> Foo
4962 Template-generated table cell attributes and cell content (2)
4965 |align=center {{table_attribs}}
4970 <td align="center" style="color: red"> Foo
4976 Template-generated table cell attributes and cell content (3)
4979 |align=center {{table_cells}}
4984 <td align="center" style="color: red"> Foo </td>
4992 Table with row followed by newlines and table heading
5010 Table with empty line following the start tag
5027 # FIXME: Preserve the attribute properly (with an empty string as value) in
5028 # the PHP parser. Parsoid implements the behavior below.
5030 Table attributes with empty value
5040 </td></tr></tbody></table>
5045 Wikitext table with a lot of comments
5068 Wikitext table with double-line table cell
5085 Table cell with a single comment
5101 # The expected HTML structure in this test is debatable. The PHP parser does
5102 # not parse this kind of table at all. The main focus for Parsoid is on
5103 # round-tripping, so this output is ok for now. TODO: revisit!
5105 Wikitext table with html-syntax row
5115 <td>foo</td></tr></tbody></table>
5119 Implicit <td> after a |-
5120 (PHP parser relies on Tidy to add the missing <td> tags)
5122 parsoid=wt2html,wt2wt
5135 Pres should be recognized in an explicit <td> context, but not in an implicit <td> context
5136 (PHP parser relies on Tidy to add the missing <td> tags)
5138 parsoid=wt2html,wt2wt
5150 <tr><td><pre>a</pre></td></tr>
5151 <tr><td> b</td></tr>
5157 Lists should be recognized in an implicit <td> context
5158 (PHP parser relies on Tidy to add the missing <td> tags)
5160 parsoid=wt2html,wt2wt
5177 Parsoid: Round-trip tables directly followed by content (bug 51219)
5179 parsoid=wt2html,wt2wt
5191 <td>foo</td></tr></tbody></table> bar
5195 <td>baz</td></tr></tbody></table><b>quux</b>
5199 Parsoid: Default to a newline after tables in new content (bug 51219)
5206 <nowiki> </nowiki>bar
5213 <tr><td>foo</td></tr></tbody></table> bar
5215 <tr><td>baz</td></tr></tbody></table><b>quux</b>
5219 Parsoid: newline inducing block nodes don't suppress <nowiki>
5234 Plain link, capitalized
5238 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5243 Plain link, uncapitalized
5247 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
5254 [[Main Page|The Main Page]]
5256 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
5261 Piped link with comment in link text
5263 [[Main Page|The Main<!--front--> Page]]
5265 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
5274 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
5279 Broken link with fragment
5281 [[Zigzagzogzagzig#zug]]
5283 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
5288 Special page link with fragment
5290 [[Special:Version#anchor]]
5292 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
5297 Nonexistent special page link with fragment
5299 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
5301 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
5308 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
5310 <p>xxx<a href="/wiki/Main_Page" title="Main Page">main Page</a>, xxx<a href="/wiki/Main_Page" title="Main Page">Main Page</a>, Xxx<a href="/wiki/Main_Page" title="Main Page">main Page</a> XXX<a href="/wiki/Main_Page" title="Main Page">main Page</a>, XXX<a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5317 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
5319 <p><a href="/wiki/Main_Page" title="Main Page">Main Pagexxx</a>, <a href="/wiki/Main_Page" title="Main Page">Main Page</a>XXX, <a href="/wiki/Main_Page" title="Main Page">Main Page</a>!!!
5330 Bug 43661: Piped links with identical prefixes
5332 [[prefixed article|prefixed articles with spaces]]
5334 [[prefixed article|prefixed articlesaoeu]]
5336 [[Main Page|Main Page test]]
5338 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
5339 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
5340 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
5346 Link with HTML entity in suffix / tail
5348 [[Main Page]]", [[Main Page]]a
5350 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
5355 Link with 3 brackets
5364 Link with 4 brackets
5368 <p>[[<a href="/wiki/Main_Page" title="Main Page">Main Page</a>]]
5373 Piped link with 3 brackets
5375 [[[main page|the main page]]]
5377 <p>[[[main page|the main page]]]
5382 Piped link with extlink-like text
5385 [[Main Page|This is a [bar]]]
5387 <p><a href="/wiki/Main_Page" title="Main Page">[bar]</a>
5388 <a href="/wiki/Main_Page" title="Main Page">This is a [bar]</a>
5393 Link with multiple pipes
5395 [[Main Page|The|Main|Page]]
5397 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
5404 [[Talk:Parser testing]], [[Meta:Disclaimers]]
5406 <p><a href="/index.php?title=Talk:Parser_testing&action=edit&redlink=1" class="new" title="Talk:Parser testing (page does not exist)">Talk:Parser testing</a>, <a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">Meta:Disclaimers</a>
5411 MemoryAlpha:AlphaTest
5413 This is an article in the MemoryAlpha namespace
5414 (which shadows the memoryalpha interwiki link).
5418 Namespace takes precedence over interwiki link (bug 51680)
5420 [[MemoryAlpha:AlphaTest]]
5422 <p><a href="/wiki/MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
5426 # The previous test doesn't work correctly in html2*, due to not recognizing the
5427 # link as an internal one. This one checks for the correct behavior.
5429 Link to namespace preferred over interwiki with correct rel attribute
5431 parsoid=html2wt,html2html
5433 [[MemoryAlpha:AlphaTest]]
5435 <p><a rel="mw:WikiLink" href="./MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
5440 Piped link to namespace
5442 [[Meta:Disclaimers|The disclaimers]]
5444 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
5451 [[Usually caused by a typo (oops}]]
5453 <p>[[Usually caused by a typo (oops}]]
5458 Link containing % (not as a hex sequence)
5462 <p><a href="/index.php?title=7%25_Solution&action=edit&redlink=1" class="new" title="7% Solution (page does not exist)">7% Solution</a>
5467 Link containing % as a single hex sequence interpreted to char
5471 <p><a href="/index.php?title=7%25_Solution&action=edit&redlink=1" class="new" title="7% Solution (page does not exist)">7% Solution</a>
5476 Link containing % as a double hex sequence interpreted to hex sequence
5480 <p>[[7%2525 Solution]]
5485 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
5486 Example for such a section: == < ==
5488 [[%23%3c]][[%23%3e]]
5490 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
5495 Link containing "<#" and ">#" as a hex sequences
5497 [[%3c%23]][[%3e%23]]
5499 <p>[[%3c%23]][[%3e%23]]
5504 Link containing an equals sign
5506 [[Special:BookSources/isbn=4-00-026157-6]]
5508 <p><a href="/wiki/Special:BookSources/isbn%3D4-00-026157-6" title="Special:BookSources/isbn=4-00-026157-6">Special:BookSources/isbn=4-00-026157-6</a>
5515 Just a test of an article title containing a tilde.
5518 # note that links containing signatures, like [[Foo~~~~]], are
5519 # massaged by the pre-save transform (PST) and so the tildes are never
5520 # seen by the parser.
5522 Link containing a tilde
5526 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
5531 Link containing double-single-quotes '' (bug 4598)
5533 [[Lista d''e paise d''o munno]]
5535 <p><a href="/index.php?title=Lista_d%27%27e_paise_d%27%27o_munno&action=edit&redlink=1" class="new" title="Lista d''e paise d''o munno (page does not exist)">Lista d''e paise d''o munno</a>
5540 Link containing double-single-quotes '' in text (bug 4598 sanity check)
5542 Some [[Link|pretty ''italics'' and stuff]]!
5544 <p>Some <a href="/index.php?title=Link&action=edit&redlink=1" class="new" title="Link (page does not exist)">pretty <i>italics</i> and stuff</a>!
5549 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
5551 ''Some [[Link|pretty ''italics'' and stuff]]!
5553 <p><i>Some <a href="/index.php?title=Link&action=edit&redlink=1" class="new" title="Link (page does not exist)">pretty <i>italics</i> and stuff</a>!</i>
5558 Link with double quotes in title part (literal) and alternate part (interpreted)
5560 [[File:Denys Savchenko ''Pentecoste''.jpg]]
5564 [[''Pentecoste''|Pentecoste]]
5566 [[''Pentecoste''|''Pentecoste'']]
5568 <p><a href="/index.php?title=Special:Upload&wpDestFile=Denys_Savchenko_%27%27Pentecoste%27%27.jpg" class="new" title="File:Denys Savchenko ''Pentecoste''.jpg">File:Denys Savchenko <i>Pentecoste</i>.jpg</a>
5569 </p><p><a href="/index.php?title=%27%27Pentecoste%27%27&action=edit&redlink=1" class="new" title="''Pentecoste'' (page does not exist)">''Pentecoste''</a>
5570 </p><p><a href="/index.php?title=%27%27Pentecoste%27%27&action=edit&redlink=1" class="new" title="''Pentecoste'' (page does not exist)">Pentecoste</a>
5571 </p><p><a href="/index.php?title=%27%27Pentecoste%27%27&action=edit&redlink=1" class="new" title="''Pentecoste'' (page does not exist)"><i>Pentecoste</i></a>
5576 Broken image links with HTML captions (bug 39700)
5578 [[File:Nonexistent|<script></script>]]
5579 [[File:Nonexistent|100px|<script></script>]]
5580 [[File:Nonexistent|<]]
5581 [[File:Nonexistent|a<i>b</i>c]]
5583 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
5584 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
5585 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
5586 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
5593 [[http://www.example.com]]
5595 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
5600 Plain link to URL with link text
5602 [[http://www.example.com Link text]]
5604 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
5609 Plain link to protocol-relative URL
5611 [[//www.example.com]]
5613 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
5618 Plain link to protocol-relative URL with link text
5620 [[//www.example.com Link text]]
5622 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
5627 Plain link to page with question mark in title
5633 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
5634 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
5639 # I'm fairly sure the expected result here is wrong.
5640 # We want these to be URL links, not pseudo-pages with URLs for titles....
5641 # However the current output is also pretty screwy.
5644 # I'm changing it to match the current output--it arguably makes more
5645 # sense in the light of the test above. Old expected result was:
5646 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
5648 # But I think this test is bordering on "garbage in, garbage out" anyway.
5653 Piped link to URL: [[http://www.example.com|an example URL]]
5655 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
5660 BUG 2: [[page|http://url/]] should link to page, not http://url/
5662 [[Main Page|http://url/]]
5664 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
5669 BUG 337: Escaped self-links should be bold
5673 [[Bug462]] [[Bug462]]
5675 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
5680 Self-link to section should not be bold
5684 [[Main Page#section]]
5686 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
5697 Self-link to numeric title
5703 <p><strong class="selflink">0</strong>
5708 Link to numeric-equivalent title
5714 <p><a href="/wiki/00" title="00">00</a>
5719 <nowiki> inside a link
5721 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
5723 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
5728 Non-breaking spaces in title
5730 [[ Main Page ]]
5732 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
5737 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
5743 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
5748 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
5754 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
5759 Internal link with en linktrail: no apostrophes (bug 27473)
5765 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
5770 Internal link with ca linktrail with apostrophes (bug 27473)
5776 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
5781 Internal link with kaa linktrail with apostrophes (bug 27473)
5787 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
5792 Link with multiple ":" in a subpage-supporting namespace (bug 63636)
5794 [[User:Foo/Test/63636:Bar|Test]]
5796 <p><a href="/index.php?title=User:Foo/Test/63636:Bar&action=edit&redlink=1" class="new" title="User:Foo/Test/63636:Bar (page does not exist)">Test</a>
5799 <p><a rel="mw:WikiLink" href="./User:Foo/Test/63636:Bar">Test</a></p>
5803 1. Interaction of linktrail and template encapsulation
5809 <p><a rel="mw:WikiLink" href="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
5813 2. Interaction of linktrail and template encapsulation
5817 {{echo|Some [[Fool]]}}s
5819 <p data-parsoid='{}'><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]"}},"i":0}},"s"]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>Some </span><a rel="mw:WikiLink" href="./Fool" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a></p>
5823 3. Interaction of linktrail and template encapsulation
5827 {{echo|Some [[Fool]]s are '''bold and foolish'''}}
5829 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]s are '''bold and foolish'''"}},"i":0}}]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>Some <a rel="mw:WikiLink" href="./Fool" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a> are <b data-parsoid="{}">bold and foolish</b></p>
5839 Internal link with is link prefix
5843 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
5845 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
5856 Internal link with is link trail and link prefix
5860 [[mótmælendatrú|xxx]]ar
5862 mótmælenda[[söfnuður]]
5863 mótmælenda[[söfnuður|söfnuðir]]
5864 mótmælenda[[söfnuður|söfnuðir]]xxx
5866 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
5867 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
5868 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
5869 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
5870 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
5875 Parsoid link trail escaping
5877 parsoid=html2wt,html2html
5881 <p><a rel="mw:WikiLink" href="Apple">apple</a>s</p>
5885 Parsoid link prefix escaping
5888 parsoid=html2wt,html2html
5890 Aðrir mótmælenda<nowiki/>[[söfnuður]]
5892 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður">söfnuður</a></p>
5896 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
5904 [http://wp.org ''foo'']
5906 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
5907 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
5908 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
5909 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
5914 Parsoid: Scoped parsing should handle mixed transclusions and plain text
5918 [[Foo|{{echo|a}} b {{echo|c}}]]
5920 <p><a rel="mw:WikiLink" href="Foo"><span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span> b <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c"}},"i":0}}]}'>c</span></a></p>
5924 ### Interwiki links (see maintenance/interwiki.sql)
5928 Inline interwiki link
5930 [[MeatBall:SoftSecurity]]
5932 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
5937 Inline interwiki link with empty title (bug 2372)
5941 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
5946 Interwiki link encoding conversion (bug 1636)
5948 *[[Wikipedia:ro:Olteniţa]]
5949 *[[Wikipedia:ro:Olteniţa]]
5952 <li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a>
5954 <li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a>
5961 Interwiki link with fragment (bug 2130)
5963 [[MeatBall:SoftSecurity#foo]]
5965 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
5969 # Ideally the wikipedia: prefix here should be proto-relative too
5971 Different interwiki prefixes mapping to the same URL
5979 [[:wikipedia:Foo|Foo]]
5981 [[wikipedia:en:Foo]]
5983 [[:wikipedia:en:Foo]]
5985 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}'>en:Foo</a></p>
5987 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}'>Foo</a></p>
5989 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true}'>wikipedia:Foo</a></p>
5991 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":":wikipedia:Foo"},"isIW":true}'>Foo</a></p>
5993 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":"wikipedia:en:Foo"},"isIW":true}'>wikipedia:en:Foo</a></p>
5995 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":":wikipedia:en:Foo"},"isIW":true}'>wikipedia:en:Foo</a></p>
5999 Interwiki links that cannot be represented in wiki syntax
6004 [[meatball:ok#foo|ok with fragment]]
6005 [[meatball:ok_as_well?|ok ending with ? mark]]
6006 [http://de.wikipedia.org/wiki/Foo?action=history has query]
6007 [http://de.wikipedia.org/wiki/#foo is just fragment]
6010 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok">meatball:ok</a>
6011 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo">ok with fragment</a>
6012 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well%3F">ok ending with ? mark</a>
6013 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
6014 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a></p>
6018 Interwiki links: trail
6022 [[wikipedia:Foo|Ba]]r
6024 <p data-parsoid='{}'><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true,"tail":"r"}'>Bar</a></p>
6028 ### Interlanguage links
6029 ### Language links (so that searching for '### language' matches..)
6043 Double interlanguage link
6054 Interlanguage link, with prefix links
6066 Double interlanguage link, with prefix links (bug 8897)
6079 Parsoid-specific test: Wikilinks with should RT properly
6085 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
6090 Parsoid bug 53221: Wikilinks should be properly entity-escaped
6094 He&nbsp;llo [[Foo|He&nbsp;llo]]
6096 He&nbsp;llo [[He&nbsp;llo]]
6098 <p>He&nbsp;llo <a href="Foo" rel="mw:WikiLink">He&nbsp;llo</a></p>
6099 <p>He&nbsp;llo <a href="He&nbsp;llo" rel="mw:WikiLink">He&nbsp;llo</a></p>
6103 Parsoid: handle constructor well
6111 <p><a rel="mw:WikiLink" href="./Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"}}">constructor</a></p>
6113 <p><a rel="mw:WikiLink" href="./Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"}}">constructor:foo</a></p>
6117 Parsoid: recognize interlanguage links without a target page
6124 <link rel="mw:PageProp/Language" href="http://ko.wikipedia.org/wiki/"></p>
6128 Parsoid: recognize interwiki links without a target page
6134 <p><a rel="mw:ExtLink" href="//ko.wikipedia.org/wiki/">ko:</a></p>
6138 Parsoid: Bug #45209, handle interwiki links pointing to the current wiki as plain wiki links
6144 <p><a rel="mw:WikiLink" href="./Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"en:Foo"}}'>Foo</a></p>
6148 ### Redirects, Parsoid-only
6151 1. Simple redirect to page
6155 #REDIRECT [[Main Page]]
6157 <link rel="mw:PageProp/redirect" href="./Main_Page">
6160 # Only wt2html and html2html since "Main_Page" will serialize to "Main Page"
6162 2. Other redirect variants
6164 parsoid=wt2html,wt2wt
6166 #REDIRECT [[Main_Page]]
6167 #REDIRECT [[<nowiki>[[Bar]]</nowiki>]]
6169 <link rel="mw:PageProp/redirect" href="./Main_Page">
6170 <link rel="mw:PageProp/redirect" href="./%5B%5BBar%5D%5D">
6174 Optional colon in #REDIRECT
6176 # the colon is archaic syntax. we support it for wt2html, but we
6177 # don't care that it roundtrips back to the modern syntax.
6178 parsoid=wt2html,html2html
6180 #REDIRECT:[[Main Page]]
6182 <link rel="mw:PageProp/redirect" href="./Main_Page">
6186 Whitespace in #REDIRECT with optional colon
6188 # the colon and gratuitous whitespace is archaic syntax. we support
6189 # it for wt2html, but we don't care that it roundtrips back to the
6190 # modern syntax (without extra whitespace)
6191 parsoid=wt2html,html2html
6198 <link rel="mw:PageProp/redirect" href="./Main_Page">
6202 Piped link in #REDIRECT
6204 # content after piped link is ignored. we support this syntax,
6205 # but don't care that the piped link is lost when we roundtrip this.
6208 #REDIRECT [[Main Page|bar]]
6210 <link rel="mw:PageProp/redirect" href="./Main_Page">
6214 Redirect to category
6218 #REDIRECT [[Category:Foo]]
6220 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
6224 Redirect to category with URL encoding
6228 #REDIRECT [[Category%3AFoo]]
6230 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
6234 Redirect to category page
6236 parsoid=wt2html,html2html
6238 #REDIRECT [[:Category:Foo]]
6240 <p><a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a></p>
6244 Redirect to image page (1)
6248 #REDIRECT [[File:Wiki.png]]
6250 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
6254 Redirect to image page (2)
6258 #REDIRECT [[Image:Wiki.png]]
6260 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
6264 Redirect to language
6268 #REDIRECT [[en:File:Wiki.png]]
6270 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
6274 Redirect to interwiki
6278 #REDIRECT [[meatball:File:Wiki.png]]
6280 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
6284 Non-English #REDIRECT
6289 #TILVÍSUN [[Main Page]]
6291 <link rel="mw:PageProp/redirect" href="./Main_Page">
6302 <p>Foo<link rel="mw:PageProp/redirect" href="./Foo"></p>
6319 Broken br tag sanitization
6327 # TODO: Fix html2html mode (bug 51055)!
6329 Parsoid: Broken br tag recognition
6339 Incorrecly removing closing slashes from correctly formed XHTML
6341 <br style="clear:both;" />
6343 <p><br style="clear:both;" />
6348 Failing to transform badly formed HTML into correct XHTML
6350 <br style="clear: left;">
6351 <br style="clear: right;">
6352 <br style="clear: both;">
6354 <p><br style="clear: left;" />
6355 <br style="clear: right;" />
6356 <br style="clear: both;" />
6361 Handling html with a div self-closing tag
6370 <p><div title />
6374 <p><div title=bar />
6375 <div title=bar/>
6377 <div title="bar/"></div>
6383 Handling html with a br self-closing tag
6392 <p><br title="title" />
6393 <br title="title" />
6402 Horizontal ruler (should it add that extra space?)
6416 Horizontal ruler -- 4+ dashes render hr
6425 Horizontal ruler -- eats additional dashes on the same line
6434 Horizontal ruler -- does not collapse dashes on consecutive lines
6445 Horizontal ruler -- <4 dashes render as plain text
6454 Horizontal ruler -- Supports content following dashes on same line
6463 ### Block-level elements
6511 ***#Number on level 4
6513 **#Number on level 3
6514 **#Number on level 3
6518 #** Level 3, but ordered
6541 <li>Number on level 4
6549 <li>Number on level 3
6551 <li>Number on level 3
6574 <li> Level 3, but ordered
6620 Nested lists 3 (first element empty)
6637 Nested lists 4 (first element empty)
6655 Nested lists 5 (both elements empty)
6673 Nested lists 6 (both elements empty)
6690 Nested lists 7 (skip initial nesting levels)
6708 Nested lists 8 (multiple nesting transitions)
6734 1. Lists with start-of-line-transparent tokens before bullets: Comments
6752 2. Lists with start-of-line-transparent tokens before bullets: Template close
6767 List items are not parsed correctly following a <pre> block (bug 785)
6785 List items from template
6796 * notSOL{{inner list}}
6827 List interrupted by empty line or heading
6846 <h2><span class="mw-headline" id="A_heading">A heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: A heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
6848 <li> Another list item
6855 Multiple list tags generated by templates
6870 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
6873 <!--This line will NOT split the list-->
6875 <!--This line will NOT split the list either-->
6877 <!--foo--> <!----> <!--This line NOT split the list either-->
6894 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
6897 <!--This line will NOT split the list-->
6899 <!--This line will NOT split the list either-->
6901 <!--foo--> <!----> <!--This line NOT split the list
6920 (Cannot test this with PHP parser since it relies on Tidy for the hack)
6922 parsoid=wt2html,wt2wt
6926 * {{echo|<li>templated li-hack}}
6927 * <!--foo--> <li> unsupported li-hack with preceding comments
6930 <li><li>not a li-hack
6937 <li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<li>templated li-hack"}}}}]}'>templated li-hack</li>
6938 <li> <!--foo--> </li>
6939 <li> li-hack with preceding comments</li>
6950 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
6977 Parsoid: Test of whitespace serialization with Templated bullets
6984 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}}]}'> Bar</li>
6988 # ------------------------------------------------------------------------
6989 # The next set of tests are about Parsoid's ability to handle badly nested
6990 # tags (parse, minimize scope of fixup, and roundtrip back)
6991 # ------------------------------------------------------------------------
6994 Unbalanced closing block tags break a list
6995 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
7013 Unbalanced closing non-block tags don't break a list
7014 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
7031 Unclosed formatting tags that straddle lists are closed and reopened
7032 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
7046 List embedded in a non-block tag
7047 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
7053 <p><small></small></p>
7059 <p><small></small></p>
7063 Table with missing opening <tr> tag
7065 parsoid=wt2html,wt2wt
7083 # Note that the current date is hard-coded as
7084 # 1970-01-01T00:02:03Z (a Thursday)
7085 # when running parser tests. The timezone is also fixed to GMT, so
7086 # local date will be identical to current date.
7089 Magic Word: {{CURRENTDAY}}
7098 Magic Word: {{CURRENTDAY2}}
7107 Magic Word: {{CURRENTDAYNAME}}
7116 Magic Word: {{CURRENTDOW}}
7125 Magic Word: {{CURRENTMONTH}}
7134 Magic Word: {{CURRENTMONTH1}}
7143 Magic Word: {{CURRENTMONTHABBREV}}
7145 {{CURRENTMONTHABBREV}}
7152 Magic Word: {{CURRENTMONTHNAME}}
7154 {{CURRENTMONTHNAME}}
7161 Magic Word: {{CURRENTMONTHNAMEGEN}}
7163 {{CURRENTMONTHNAMEGEN}}
7170 Magic Word: {{CURRENTTIME}}
7179 Magic Word: {{CURRENTHOUR}}
7188 Magic Word: {{CURRENTWEEK}} (@bug 4594)
7197 Magic Word: {{CURRENTYEAR}}
7206 Magic Word: {{CURRENTTIMESTAMP}}
7208 {{CURRENTTIMESTAMP}}
7215 Magic Words LOCAL (UTC)
7219 * {{LOCALMONTHNAME}}
7220 * {{LOCALMONTHNAMEGEN}}
7221 * {{LOCALMONTHABBREV}}
7230 * {{LOCALTIMESTAMP}}
7266 Magic Word: {{FULLPAGENAME}}
7268 title=[[User:Ævar Arnfjörð Bjarmason]]
7272 <p>User:Ævar Arnfjörð Bjarmason
7277 Magic Word: {{FULLPAGENAMEE}}
7279 title=[[User:Ævar Arnfjörð Bjarmason]]
7283 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7288 Magic Word: {{TALKSPACE}}
7290 title=[[User:Ævar Arnfjörð Bjarmason]]
7299 Magic Word: {{TALKSPACE}}, same namespace
7301 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7310 Magic Word: {{TALKSPACE}}, main namespace
7312 title=[[Parser Test]]
7321 Magic Word: {{TALKSPACEE}}
7323 title=[[User:Ævar Arnfjörð Bjarmason]]
7332 Magic Word: {{SUBJECTSPACE}}
7334 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7343 Magic Word: {{SUBJECTSPACE}}, same namespace
7345 title=[[User:Ævar Arnfjörð Bjarmason]]
7354 Magic Word: {{SUBJECTSPACE}}, main namespace
7356 title=[[Parser Test]]
7364 Magic Word: {{SUBJECTSPACEE}}
7366 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7375 Magic Word: {{NAMESPACE}}
7377 title=[[User:Ævar Arnfjörð Bjarmason]]
7386 Magic Word: {{NAMESPACEE}}
7388 title=[[User:Ævar Arnfjörð Bjarmason]]
7397 Magic Word: {{NAMESPACENUMBER}}
7399 title=[[User:Ævar Arnfjörð Bjarmason]]
7408 Magic Word: {{SUBPAGENAME}}
7410 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
7419 Magic Word: {{SUBPAGENAMEE}}
7421 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
7430 Magic Word: {{ROOTPAGENAME}}
7432 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
7436 <p>Ævar Arnfjörð Bjarmason
7441 Magic Word: {{ROOTPAGENAMEE}}
7443 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
7447 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7452 Magic Word: {{BASEPAGENAME}}
7454 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
7458 <p>Ævar Arnfjörð Bjarmason
7463 Magic Word: {{BASEPAGENAMEE}}
7465 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
7469 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7474 Magic Word: {{TALKPAGENAME}}
7476 title=[[User:Ævar Arnfjörð Bjarmason]]
7480 <p>User talk:Ævar Arnfjörð Bjarmason
7485 Magic Word: {{TALKPAGENAMEE}}
7487 title=[[User:Ævar Arnfjörð Bjarmason]]
7491 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7496 Magic Word: {{SUBJECTPAGENAME}}
7498 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7502 <p>User:Ævar Arnfjörð Bjarmason
7507 Magic Word: {{SUBJECTPAGENAMEE}}
7509 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7511 {{SUBJECTPAGENAMEE}}
7513 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7518 Magic Word: {{NUMBEROFFILES}}
7527 Magic Word: {{PAGENAME}}
7529 title=[[User:Ævar Arnfjörð Bjarmason]]
7533 <p>Ævar Arnfjörð Bjarmason
7538 Magic Word: {{PAGENAME}} with metacharacters
7540 title=[['foo & bar = baz']]
7544 <p><i>'foo & bar = baz'</i>
7549 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
7551 title=[[*RFC 1234 http://example.com/]]
7555 <p>*RFC 1234 http://example.com/
7560 Magic Word: {{PAGENAMEE}}
7562 title=[[User:Ævar Arnfjörð Bjarmason]]
7566 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7571 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
7573 title=[[*RFC 1234 http://example.com/]]
7577 <p>*RFC_1234_http://example.com/
7582 Magic Word: {{REVISIONID}}
7591 Magic Word: {{SCRIPTPATH}}
7600 Magic Word: {{STYLEPATH}}
7609 Magic Word: {{SERVER}}
7613 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
7618 Magic Word: {{SERVERNAME}}
7627 Magic Word: {{SITENAME}}
7636 Case-sensitive magic words, when cased differently, should just be template transclusions
7643 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
7644 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
7645 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
7646 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
7651 Case-insensitive magic words should still work with weird casing.
7661 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
7666 Namespace 1 {{ns:1}}
7675 Namespace 1 {{ns:01}}
7684 Namespace 0 {{ns:0}} (bug 4783)
7692 Namespace 0 {{ns:00}} (bug 4783)
7700 Namespace -1 {{ns:-1}}
7709 Namespace User {{ns:User}}
7718 Namespace User talk {{ns:User_talk}}
7727 Namespace User talk {{ns:uSeR tAlK}}
7736 Namespace File {{ns:File}}
7745 Namespace File {{ns:Image}}
7754 Namespace (lang=de) Benutzer {{ns:User}}
7765 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
7771 <p>Benutzer Diskussion
7779 {{urlencode:hi world?!}}
7780 {{urlencode:hi world?!|WIKI}}
7781 {{urlencode:hi world?!|PATH}}
7782 {{urlencode:hi world?!|QUERY}}
7792 Magic Word: prioritize type info over data-parsoid
7798 <meta property="mw:PageProp/forcetoc" data-parsoid='{"src":"__NOTOC__","magicSrc":"__NOTOC__"}'/>
7802 Magic Word: serialize on separate line (parsoid)
7804 parsoid=wt2wt,html2wt
7810 foo<meta property="mw:PageProp/notoc"/>bar
7814 Magic Word: rt non-english wikis
7821 <meta property="mw:PageProp/noeditsection" data-parsoid='{"src":"__NOEDITSECTION__","magicSrc":"__NOEDITSECTION__"}'/>
7828 Magic links: internal link to RFC (bug 479)
7832 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
7837 Magic links: RFC (bug 479)
7841 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
7846 Magic links: ISBN (bug 1937)
7850 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
7855 Magic links: PMID incorrectly converts space to underscore
7859 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
7868 Nonexistent template
7870 {{thistemplatedoesnotexist}}
7872 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
7877 Template with invalid target containing tags
7879 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
7881 <p>{{a<b>b</b>|foo|a=b|a = b}}
7886 Template with invalid target containing unclosed tag
7888 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
7890 <p>{{a<b>|foo|a=b|a = b}}</b>
7895 Template with invalid target containing wikilink
7899 <p>{{<a href="/wiki/Main_Page" title="Main Page">Main Page</a>}}
7902 <p><span typeof="mw:Transclusion" about="#mwt1" data-mw='{"parts":[{"template":{"target":{"wt":"[[Main Page]]"},"params":{},"i":0}}]}'>{{</span><a rel="mw:WikiLink" href="./Main_Page" about="#mwt1">Main Page</a><span about="#mwt1">}}</span></p>
7908 This is a test template
7916 <p>This is a test template
7921 Template with explicit namespace
7925 <p>This is a test template
7933 This is a test template with parameter {{{param}}}
7939 {{paramtest|param=foo}}
7941 <p>This is a test template with parameter foo
7946 Template:paramtestnum
7952 Template unnamed parameter
7954 {{paramtestnum|Main Page|the main page}}
7956 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
7961 Template:templatesimple
7967 Template:templateredirect
7969 #redirect [[Template:templatesimple]]
7973 Template:templateasargtestnum
7979 Template:templateasargtest
7981 {{template{{{templ}}}}}
7985 Template:templateasargtest2
7991 Template with template name as unnamed argument
7993 {{templateasargtestnum|templatesimple}}
8000 Template with template name as argument
8002 {{templateasargtest|templ=simple}}
8009 Template with template name as argument (2)
8011 {{templateasargtest2|templ=templatesimple}}
8018 Template:templateasargtestdefault
8020 {{{{{templ|templatesimple}}}}}
8030 Template with default value
8032 {{templateasargtestdefault}}
8039 Template with default value (value set)
8041 {{templateasargtestdefault|templ=templa}}
8050 {{templateredirect}}
8057 Template with argument in separate line
8059 {{ templateasargtest |
8067 Template with complex template as argument
8070 param ={{ templateasargtest |
8073 <p>This is a test template with parameter (test)
8078 Template with thumb image (with link in description)
8081 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
8083 This is a test template with parameter <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Noimage.png" class="new" title="File:Noimage.png">File:Noimage.png</a> <div class="thumbcaption"><a href="/index.php?title=No_link&action=edit&redlink=1" class="new" title="No link (page does not exist)">link</a> <a href="/index.php?title=No_link&action=edit&redlink=1" class="new" title="No link (page does not exist)">caption</a></div></div></div>
8088 Template:complextemplate
8090 {{{1}}} {{paramtest|
8091 param ={{{param}}}}}
8095 Template with complex arguments
8098 param ={{ templateasargtest |
8099 templ = simple }}|[[Template:complextemplate|link]]}}
8101 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
8106 BUG 553: link with two variables in a piped link
8109 |[[{{{1}}}|{{{2}}}]]
8114 <td>[[{{{1}}}|{{{2}}}]]
8120 Magic variable as template parameter
8122 {{paramtest|param={{SITENAME}}}}
8124 <p>This is a test template with parameter MediaWiki
8131 [[{{{param}}}|link]]
8135 Template parameter as link source
8137 {{linktest|param=Main Page}}
8139 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
8144 Template-generated attribute string (k='v')
8146 <span {{attr_str|id|v1}}>bar</span>
8148 <p><span id="v1">bar</span>
8155 including another template, {{paramtest|param={{{arg}}}}}
8159 Template passing argument to another template
8161 {{paramtest2|arg='hmm'}}
8163 <p>including another template, This is a test template with parameter 'hmm'
8174 Template as link source
8178 [[{{linktest2}}|Main Page]]
8180 [[{{linktest2}}]]Page
8182 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
8183 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
8184 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
8202 Template infinite loop
8206 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
8211 Template from main namespace
8230 BUG 529: Template with table, not included at beginning of line
8249 BUG 523: Template shouldn't eat newline (or add an extra one before table)
8269 BUG 41: Template parameters shown as broken links
8278 Template with targets containing wikilinks
8282 {{[[{{echo|foo}}]]}}
8284 {{{{echo|[[foo}}]]}}
8286 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
8287 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
8295 ''None'' of '''this''' should be
8297 but rather passed unmodified
8301 # hmm, fix this or just deprecate msgnw and document its behavior?
8307 {{msgnw:MSGNW test}}
8309 <p>''None'' of '''this''' should be
8311 but rather passed unmodified
8319 {{int:youhavenewmessages|lots of money|not!}}
8321 <p>You have lots of money (not!).
8328 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
8332 <includeonly> and <noinclude> being included
8343 <onlyinclude>Foo</onlyinclude>bar
8347 <onlyinclude> being included
8359 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
8363 <onlyinclude> and <includeonly> being included
8372 <includeonly> and <noinclude> on a page
8374 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
8381 Un-closed <noinclude>
8388 <onlyinclude> on a page
8390 <onlyinclude>Foo</onlyinclude>bar
8397 Un-closed <onlyinclude>
8404 Self-closed noinclude, includeonly, onlyinclude tags
8415 Unbalanced includeonly and noinclude tags
8419 |b</noinclude></noinclude>
8420 |c</noinclude></includeonly>
8421 |d</includeonly></includeonly>
8430 <td>c</includeonly>
8432 <td>d</includeonly></includeonly>
8438 Template:Includeonly section
8441 ==Includeonly section==
8447 Bug 6563: Edit link generation for section shown by <includeonly>
8449 {{includeonly section}}
8451 <h2><span class="mw-headline" id="Includeonly_section">Includeonly section</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Includeonly_section&action=edit&section=T-1" title="Template:Includeonly section">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
8452 <h2><span class="mw-headline" id="Section_T-1">Section T-1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Includeonly_section&action=edit&section=T-2" title="Template:Includeonly section">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
8456 # Uses same input as the contents of [[Template:Includeonly section]]
8458 Bug 6563: Section extraction for section shown by <includeonly>
8463 ==Includeonly section==
8471 Bug 6563: Edit link generation for section suppressed by <includeonly>
8474 ==Includeonly section==
8478 <h2><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
8483 Bug 6563: Section extraction for section suppressed by <includeonly>
8488 ==Includeonly section==
8496 Un-closed <includeonly>
8502 # TODO: test with DOM fragment reuse!
8504 Parsoid: DOM fragment reuse
8506 parsoid=wt2wt,wt2html
8508 a{{echo|b<table></table>c}}d
8520 a<span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b
8521 <table></table>c"}},"i":0}}]}'>b</span>
8522 <table about="#mwt1"></table><span about="#mwt1">c</span>d
8525 <p about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["a",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b\n<table></table>\nc"}},"i":0}},"d"]}'>ab</p><span about="#mwt2">
8527 <table about="#mwt2"></table><span about="#mwt2">
8529 <p about="#mwt2">cd</p>
8532 <p about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n\n<table></table>\n\nb"}},"i":0}}]}'>a</p><span about="#mwt3">
8535 <table about="#mwt3"></table><span about="#mwt3">
8538 <p about="#mwt3">b</p>
8542 Parsoid: Merge double tds (bug 50603)
8551 <tr><td about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{!}} foo"}},"i":0}}]}'> foo</td></tr>
8556 Parsoid: Merge double tds in nested transclusion content (bug 50603)
8566 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div>"}},"i":0}},"\n{|\n|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{!}} foo"}},"i":1}},"\n|}\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"</div>"}},"i":2}}]}'>
8568 <tr><td data-mw='{"parts":["|"]}'> foo</td></tr>
8574 ### <includeonly> and <noinclude> in attributes
8577 0. includeonly around the entire attribute
8579 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
8581 <p><span id="v2">bar</span>
8586 1. includeonly in html attr key
8588 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
8590 <p><span id="foo">bar</span>
8595 2. includeonly in html attr value
8597 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
8598 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
8600 <p><span id="v1">bar</span>
8601 <span id="v1">bar</span>
8606 3. includeonly in part of an attr value
8608 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
8610 <p><span style="color:red;">bar</span>
8615 4. includeonly in table attributes
8639 ### Testing parsing of templates where a template arg
8640 ### has the same name as the template itself.
8650 Templates: Template Name/Arg clash: 1. Use of positional param
8659 Templates: Template Name/Arg clash: 2. Use of named param
8668 Templates: Template Name/Arg clash: 3. Use of named param with empty input
8677 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
8681 Templates: 1. Simple use
8690 Templates: 2. Inside a block tag
8692 <div>{{echo|Foo}}</div>
8693 <blockquote>{{echo|Foo}}</blockquote>
8696 <blockquote>Foo</blockquote>
8701 Templates: P-wrapping: 1a. Templates on consecutive lines
8712 Templates: P-wrapping: 1b. Templates on consecutive lines
8726 Templates: P-wrapping: 1c. Templates on consecutive lines
8729 {{echo|bar}} <div>baz</div>
8738 Templates: P-wrapping: 1d. Template preceded by comment-only line
8747 <p about="#mwt223" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Bar"}},"i":0}}]}'>Bar</p>
8751 Templates: Inline Text: 1. Multiple tmeplate uses
8753 {{echo|Foo}}bar{{echo|baz}}
8760 Templates: Inline Text: 2. Back-to-back template uses
8762 {{echo|Foo}}{{echo|bar}}
8769 Templates: Block Tags: 1. Multiple template uses
8771 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
8773 <div>Foo</div><div>bar</div><div>baz</div>
8778 Templates: Block Tags: 2. Back-to-back template uses
8780 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
8782 <div>Foo</div><div>bar</div>
8787 Templates: Links: 1. Simple example
8789 {{echo|[[Foo|bar]]}}
8791 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8796 Templates: Links: 2. Generation of link href
8798 [[{{echo|Foo}}|bar]]
8800 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8805 Templates: Links: 3. Generation of part of a link href
8807 [[Fo{{echo|o}}|bar]]
8811 [[Foo{{echo|bar}}baz]]
8813 [[Foo{{echo|bar}}|bar]]
8815 [[:Foo{{echo|bar}}]]
8817 [[:Foo{{echo|bar}}|bar]]
8819 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8820 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
8821 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
8822 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
8823 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
8824 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
8829 Templates: Links: 4. Multiple templates generating link href
8831 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
8833 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
8838 Templates: Links: 5. Generation of link text
8840 [[Foo|{{echo|bar}}]]
8842 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8847 Templates: Links: 5. Nested templates (only outermost template should be marked)
8849 {{echo|[[{{echo|Foo}}|bar]]}}
8851 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8856 Templates: HTML Tag: 1. Generation of HTML attr. key
8858 <div {{echo|style}}="color:red;">foo</div>
8860 <div style="color:red;">foo</div>
8865 Templates: HTML Tag: 2. Generation of HTML attr. value
8867 <div style={{echo|'color:red;'}}>foo</div>
8869 <div style="color:red;">foo</div>
8874 Templates: HTML Tag: 3. Generation of HTML attr key and value
8876 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
8878 <div style="color:red;">foo</div>
8883 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
8885 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
8887 <div title="This is a long title with just one piece templated">foo</div>
8892 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
8894 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
8896 <div title="This is a long title with just one piece templated">foo</div>
8901 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
8903 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
8905 <div title="This is a long title with just one piece templated">foo</div>
8910 Templates: HTML Tag: 7. Generation of partial attribute key string
8912 <div st{{echo|yle}}="color:red;">foo</div>
8914 <div style="color:red;">foo</div>
8919 Templates: HTML Tables: 1. Generating start of a HTML table
8921 {{echo|<table><tr><td>foo</td>}}</tr></table>
8923 <table><tr><td>foo</td></tr></table>
8928 Templates: HTML Tables: 2a. Generating middle of a HTML table
8930 <table><tr>{{echo|<td>foo</td>}}</tr></table>
8932 <table><tr><td>foo</td></tr></table>
8937 Templates: HTML Tables: 2b. Generating middle of a HTML table
8939 <table>{{echo|<tr><td>foo</td></tr>}}</table>
8941 <table><tr><td>foo</td></tr></table>
8946 Templates: HTML Tables: 3. Generating end of a HTML table
8948 <table><tr>{{echo|<td>foo</td></tr></table>}}
8950 <table><tr><td>foo</td></tr></table>
8955 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
8957 {{echo|<table>}}<tr><td>foo</td></tr></table>
8959 <table><tr><td>foo</td></tr></table>
8964 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
8966 <table>{{echo|<tr>}}<td>foo</td></tr></table>
8968 <table><tr><td>foo</td></tr></table>
8973 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
8975 <table><tr>{{echo|<td>}}foo</td></tr></table>
8977 <table><tr><td>foo</td></tr></table>
8982 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
8984 <table><tr><td>foo{{echo|</td>}}</tr></table>
8986 <table><tr><td>foo</td></tr></table>
8991 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
8993 <table><tr><td>foo</td>{{echo|</tr>}}</table>
8995 <table><tr><td>foo</td></tr></table>
9000 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
9002 <table><tr><td>foo</td></tr>{{echo|</table>}}
9004 <table><tr><td>foo</td></tr></table>
9009 Templates: HTML Tables: 5. Proper fostering of categories from inside
9011 parsoid=wt2html,wt2wt
9013 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
9014 <!--Two categories (Bug 50330)-->
9015 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
9017 <link rel="mw:PageProp/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
9018 <!--Two categories (Bug 50330)-->
9019 <link rel="mw:PageProp/Category" href="./Category:Bar1"><link rel="mw:PageProp/Category" href="./Category:Bar2"><table><tbody><tr><td>foo</td></tr></tbody></table>
9023 Templates: Wiki Tables: 1a. Fostering of entire template content
9031 <tr><td></td></tr></table>
9036 Templates: Wiki Tables: 1b. Fostering of entire template content
9049 <tr><td></td></tr></table>
9054 Templates: Wiki Tables: 2. Fostering of partial template content
9064 <tr><td></td></tr></table>
9069 Templates: Wiki Tables: 3. td-content via multiple templates
9072 {{echo|{{pipe}}a}}{{echo|b}}
9083 Templates: Wiki Tables: 4. Templated tags, no content
9089 <tr><td></td></tr></table>
9094 Templates: Wiki Tables: 5. Templated tags, regular td-tags
9108 Templates: Wiki Tables: 6. Templated tags, templated td-tags
9122 Templates: Lists: Multi-line list-items via templates
9124 *{{echo|a {{nonexistent|
9126 *{{echo|b {{nonexistent|
9130 <li>a <a href="/index.php?title=Template:Nonexistent&action=edit&redlink=1" class="new" title="Template:Nonexistent (page does not exist)">Template:Nonexistent</a>
9132 <li>b <a href="/index.php?title=Template:Nonexistent&action=edit&redlink=1" class="new" title="Template:Nonexistent (page does not exist)">Template:Nonexistent</a>
9139 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
9141 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
9143 <p><i>ab</i>c<i>d</i>e
9148 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
9149 (PHP parser generates misnested html)
9151 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
9153 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_span","href":"./Template:Echo_with_span"},"params":{"1":{"wt":"''a"}},"i":0}}]}"><i>a</i></span><i about="#mwt2" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_span","href":"./Template:Echo_with_span"},"params":{"1":{"wt":"b''c''d"}},"i":0}},{"template":{"target":{"wt":"echo_with_span","href":"./Template:Echo_with_span"},"params":{"1":{"wt":"''e"}},"i":1}}]}"><span>b</span></i><span about="#mwt2">c</span><i about="#mwt2">d<span></span></i><span about="#mwt2">e</span></p>
9157 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
9158 (PHP parser generates misnested html; Parsoid html2wt mode adds newlines between {{echo}}s)
9160 parsoid=wt2html,wt2wt
9162 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
9164 <div about="#mwt1" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_div","href":"./Template:Echo_with_div"},"params":{"1":{"wt":"''a"}},"i":0}}]}"><i>a</i></div>
9165 <div about="#mwt2" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_div","href":"./Template:Echo_with_div"},"params":{"1":{"wt":"b''c''d"}},"i":0}}]}"><i>b</i>c<i>d</i></div>
9166 <div about="#mwt3" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_div","href":"./Template:Echo_with_div"},"params":{"1":{"wt":"''e"}},"i":0}}]}">e</div>
9170 Templates: Ugly nesting: 4. Divs opened/closed across templates
9172 a<div>b{{echo|c</div>d}}e
9179 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
9185 |{{echo|foo</table>}}
9189 <table about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["{|\n|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</table>"}},"i":0}},"\n|bar\n|}"]}'>
9193 <td>foo</td></tr></tbody></table><span about="#mwt1">
9194 </span><span about="#mwt1">|bar</span><span about="#mwt1">
9199 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
9209 <td>1. {{echo|foo </table>}}</td>
9211 <td>2. {{echo|baz </table>}}</td>
9224 <table about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["<table>\n <tr>\n <td>\n <table>\n <tr>\n <td>1. ",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo </table>"}},"i":0}},"</td>\n <td> bar </td>\n <td>2. ",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"baz </table>"}},"i":1}},"</td>\n </tr>\n <tr>\n <td>abc</td>\n </tr>\n </table>\n </td>\n </tr>\n <tr>\n <td>xyz</td>\n </tr>\n</table>"]}'>
9229 <td>1. foo </td></tr></tbody></table></td>
9231 <td>2. baz </td></tr></tbody></table><span about="#mwt2">
9232 </span><span about="#mwt2">
9233 </span><span about="#mwt2">
9234 </span><span about="#mwt2">abc</span><span about="#mwt2">
9235 </span><span about="#mwt2">
9236 </span><span about="#mwt2">
9237 </span><span about="#mwt2">
9238 </span><span about="#mwt2">
9239 </span><span about="#mwt2">
9240 </span><span about="#mwt2">xyz</span><span about="#mwt2">
9241 </span><span about="#mwt2">
9246 Templates: Ugly templates: 3. newline-only template parameter
9255 # This looks like a bug: a single newline triggers p/br for some reason.
9257 Templates: Ugly templates: 4. newline-only template parameter inconsistency
9268 Parser Functions: 1. Simple example
9277 Parser Functions: 2. Nested use (only outermost should be marked up)
9286 ### Pre-save transform tests
9289 pre-save transform: subst:
9295 This is a test template
9299 pre-save transform: normal template
9309 pre-save transform: nonexistent template
9313 {{thistemplatedoesnotexist}}
9315 {{thistemplatedoesnotexist}}
9320 pre-save transform: subst magic variables
9329 # This is bug 89, which I fixed. -- wtm
9331 pre-save transform: subst: templates with parameters
9335 {{subst:paramtest|param="something else"}}
9337 This is a test template with parameter "something else"
9343 <nowiki>'''not wiki'''</nowiki>
9347 pre-save transform: nowiki in subst (bug 1188)
9351 {{subst:nowikitest}}
9353 <nowiki>'''not wiki'''</nowiki>
9358 Template:commenttest
9360 This template has <!-- a comment --> in it.
9364 pre-save transform: comment in subst (bug 1936)
9368 {{subst:commenttest}}
9370 This template has <!-- a comment --> in it.
9374 pre-save transform: unclosed tag
9378 <nowiki>'''not wiki'''
9380 <nowiki>'''not wiki'''
9384 pre-save transform: mixed tag case
9388 <NOwiki>'''not wiki'''</noWIKI>
9390 <NOwiki>'''not wiki'''</noWIKI>
9394 pre-save transform: unclosed comment in <nowiki>
9398 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
9400 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
9403 # Leading @ in this template definition works around a limitation
9404 # in parsoid's parserTests which otherwise strips the <span> from the
9405 # result (confusing it for a template wrapper)
9409 @<span onmouseover="alert('crap')">Oh no</span>
9413 (confirming safety of fix for subst bug 1936)
9415 {{Template:dangerous}}
9417 <p>@<span>Oh no</span>
9422 pre-save transform: comment containing gallery (bug 5024)
9426 <!-- <gallery>data</gallery> -->
9428 <!-- <gallery>data</gallery> -->
9432 pre-save transform: comment containing extension
9436 <!-- <tag>data</tag> -->
9438 <!-- <tag>data</tag> -->
9442 pre-save transform: comment containing nowiki
9446 <!-- <nowiki>data</nowiki> -->
9448 <!-- <nowiki>data</nowiki> -->
9452 pre-save transform: <noinclude> in subst (bug 3298)
9462 pre-save transform: <onlyinclude> in subst (bug 3298)
9474 {{<includeonly>subst:</includeonly>Includes}}
9478 Template:SafeSubstTest
9480 {{<includeonly>safesubst:</includeonly>Includes}}
9484 bug 22297: safesubst: works during PST
9488 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
9494 bug 22297: safesubst: works during normal parse
9503 subst: does not work during normal parse
9507 <p>{{subst:Includes}}
9512 pre-save transform: context links ("pipe trick")
9516 [[Article (context)|]]
9519 [[Bar:Article (context)|]]
9520 [[:Bar:Article (context)|]]
9522 [[|Article (context)]]
9526 [[Article (context)|Article]]
9527 [[Bar:Article|Article]]
9528 [[:Bar:Article|Article]]
9529 [[Bar:Article (context)|Article]]
9530 [[:Bar:Article (context)|Article]]
9532 [[Article (context)]]
9533 [[Bar:X (Y) Z|X (Y) Z]]
9534 [[:Bar:X (Y) Z|X (Y) Z]]
9538 pre-save transform: context links ("pipe trick") with interwiki prefix
9542 [[interwiki:Article|]]
9543 [[:interwiki:Article|]]
9544 [[interwiki:Bar:Article|]]
9545 [[:interwiki:Bar:Article|]]
9547 [[interwiki:Article|Article]]
9548 [[:interwiki:Article|Article]]
9549 [[interwiki:Bar:Article|Bar:Article]]
9550 [[:interwiki:Bar:Article|Bar:Article]]
9554 pre-save transform: context links ("pipe trick") with parens in title
9556 pst title=[[Somearticle (context)]]
9560 [[Article (context)|Article]]
9564 pre-save transform: context links ("pipe trick") with comma in title
9566 pst title=[[Someplace, Somewhere]]
9569 [[Otherplace, Elsewhere|]]
9570 [[Otherplace, Elsewhere, Anywhere|]]
9572 [[Otherplace, Somewhere|Otherplace]]
9573 [[Otherplace, Elsewhere|Otherplace]]
9574 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
9578 pre-save transform: context links ("pipe trick") with parens and comma
9580 pst title=[[Someplace (IGNORED), Somewhere]]
9583 [[Otherplace (place), Elsewhere|]]
9585 [[Otherplace, Somewhere|Otherplace]]
9586 [[Otherplace (place), Elsewhere|Otherplace]]
9590 pre-save transform: context links ("pipe trick") with comma and parens
9592 pst title=[[Who, me? (context)]]
9595 [[Me, Myself, and I (1937 song)|]]
9597 [[Yes, you. (context)|Yes, you.]]
9598 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
9602 pre-save transform: context links ("pipe trick") with namespace
9604 pst title=[[Ns:Somearticle]]
9608 [[Ns:Article|Article]]
9612 pre-save transform: context links ("pipe trick") with namespace and parens
9614 pst title=[[Ns:Somearticle (context)]]
9618 [[Ns:Article (context)|Article]]
9622 pre-save transform: context links ("pipe trick") with namespace and comma
9624 pst title=[[Ns:Somearticle, Context, Whatever]]
9628 [[Ns:Article, Context, Whatever|Article]]
9632 pre-save transform: context links ("pipe trick") with namespace, comma and parens
9634 pst title=[[Ns:Somearticle, Context (context)]]
9638 [[Ns:Article (context)|Article]]
9642 pre-save transform: context links ("pipe trick") with namespace, parens and comma
9644 pst title=[[Ns:Somearticle (IGNORED), Context]]
9648 [[Ns:Article, Context|Article]]
9652 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
9656 [[Article(context)|]]
9657 [[Bar:Article(context)|]]
9658 [[:Bar:Article(context)|]]
9659 [[|Article(context)]]
9663 [[Article(context)|Article]]
9664 [[Bar:Article(context)|Article]]
9665 [[:Bar:Article(context)|Article]]
9666 [[Article(context)]]
9668 [[:Bar:X(Y)Z|X(Y)Z]]
9672 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
9676 [[Article (context)|]]
9677 [[Bar:Article (context)|]]
9678 [[:Bar:Article (context)|]]
9679 [[|Article (context)]]
9683 [[Article (context)|Article]]
9684 [[Bar:Article (context)|Article]]
9685 [[:Bar:Article (context)|Article]]
9686 [[Article (context)]]
9687 [[Bar:X (Y) Z|X (Y) Z]]
9688 [[:Bar:X (Y) Z|X (Y) Z]]
9692 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
9696 [[Article(context)|]]
9697 [[Bar:Article(context)|]]
9698 [[:Bar:Article(context)|]]
9699 [[|Article(context)]]
9703 [[Article(context)|Article]]
9704 [[Bar:Article(context)|Article]]
9705 [[:Bar:Article(context)|Article]]
9706 [[Article(context)]]
9708 [[:Bar:X(Y)Z|X(Y)Z]]
9712 pre-save transform: context links ("pipe trick") with commas (bug 21660)
9716 [[Article (context), context|]]
9717 [[Article (context),context|]]
9718 [[Bar:Article (context), context|]]
9719 [[Bar:Article (context),context|]]
9720 [[:Bar:Article (context), context|]]
9721 [[:Bar:Article (context),context|]]
9723 [[Article (context), context|Article]]
9724 [[Article (context),context|Article]]
9725 [[Bar:Article (context), context|Article]]
9726 [[Bar:Article (context),context|Article]]
9727 [[:Bar:Article (context), context|Article]]
9728 [[:Bar:Article (context),context|Article]]
9732 pre-save transform: trim trailing empty lines
9736 Empty lines are trimmed
9742 Empty lines are trimmed
9746 pre-save transform: Signature expansion
9751 * <noinclude>~~~</noinclude>
9752 * <includeonly>~~~</includeonly>
9753 * <onlyinclude>~~~</onlyinclude>
9755 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
9756 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
9757 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
9758 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
9763 pre-save transform: Signature expansion in nowiki tags (bug 93)
9769 <nowiki>~~~~</nowiki>
9771 <includeonly><nowiki>~~~~</nowiki></includeonly>
9773 <noinclude><nowiki>~~~~</nowiki></noinclude>
9775 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
9777 {{subst:Foo}} shall be converted to FOO
9779 As well as inside noinclude/onlyinclude
9780 <noinclude>{{subst:Foo}}</noinclude>
9781 <onlyinclude>{{subst:Foo}}</onlyinclude>
9783 But not inside includeonly
9784 <includeonly>{{subst:Foo}}</includeonly>
9788 <nowiki>~~~~</nowiki>
9790 <includeonly><nowiki>~~~~</nowiki></includeonly>
9792 <noinclude><nowiki>~~~~</nowiki></noinclude>
9794 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
9796 FOO shall be converted to FOO
9798 As well as inside noinclude/onlyinclude
9799 <noinclude>FOO</noinclude>
9800 <onlyinclude>FOO</onlyinclude>
9802 But not inside includeonly
9803 <includeonly>{{subst:Foo}}</includeonly>
9807 Parsoid: Recognize nowiki with trailing space in tags
9811 <nowiki ><div>[[foo]]</nowiki >
9819 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
9826 Parsoid: Recognize nowiki with odd capitalization
9830 <noWikI ><div>[[foo]]</Nowiki >
9832 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
9837 Parsoid: Escape nowiki with trailing space in tags
9841 <nowiki > foo </nowiki >
9847 <p><nowiki > foo </nowiki ></p>
9848 <p>a<nowiki />b</p>
9849 <p>c<nowiki/ >d</p>
9853 Parsoid: Escape weird noWikI capitalizations
9857 <noWikI > foo </NoWikI >
9859 <p><noWikI > foo </NoWikI ></p>
9863 ### Message transform tests
9866 message transform: magic variables
9876 message transform: should not transform wiki markup
9886 message transform: <noinclude> in transcluded template (bug 4926)
9896 message transform: <onlyinclude> in transcluded template (bug 4926)
9906 {{#special:}} page name, known
9910 {{#special:Recentchanges}}
9912 Special:RecentChanges
9916 {{#special:}} page name with subpage, known
9920 {{#special:Recentchanges/param}}
9922 Special:RecentChanges/param
9926 {{#special:}} page name, unknown
9930 {{#special:foobar nonexistent}}
9932 Special:Foobar nonexistent
9936 {{#speciale:}} page name, known
9940 {{#speciale:Recentchanges}}
9942 Special:RecentChanges
9946 {{#speciale:}} page name with subpage, known
9950 {{#speciale:Recentchanges/param}}
9952 Special:RecentChanges/param
9956 {{#speciale:}} page name, unknown
9960 {{#speciale:foobar nonexistent}}
9962 Special:Foobar_nonexistent
9968 ### For Parsoid-specific tests, see
9969 #### https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
9974 parsoid=wt2html,wt2wt,html2html
9976 [[Image:foobar.jpg]]
9978 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
9981 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>
9986 Simple image (using File: namespace, now canonical)
9990 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
9993 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>
10000 [[File:Foobar.jpg|right]]
10002 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10005 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>
10011 [[File:Foobar.jpg|right|Caption text]]
10013 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption text"><img alt="Caption text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10016 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
10020 Image with caption, bug 53312 #1
10022 [[File:Foobar.jpg|right|Caption page stuff]]
10024 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption page stuff"><img alt="Caption page stuff" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10027 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption page stuff</figcaption></figure>
10031 Image with caption, bug 53312 #2
10033 [[File:Foobar.jpg|right|Caption page=]]
10035 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption page="><img alt="Caption page=" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10038 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption page=</figcaption></figure>
10042 Image with caption, bug 53312 #3
10044 [[File:Foobar.jpg|right|Caption page=stuff]]
10046 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption page=stuff"><img alt="Caption page=stuff" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10049 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption page=stuff</figcaption></figure>
10053 Allow empty links in image captions (Bug 60753)
10057 [[File:Foobar.jpg|thumb|Caption [[Link1]]
10062 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Caption <a href="/index.php?title=Link1&action=edit&redlink=1" class="new" title="Link1 (page does not exist)">Link1</a> [[]] <a href="/index.php?title=Link2&action=edit&redlink=1" class="new" title="Link2 (page does not exist)">Link2</a></div></div></div>
10065 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"caption","ak":"Caption [[Link1]]\n[[]]\n[[Link2]]\n"}],"dsr":[0,59,2,2]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"dsr":[2,null,null,null]}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption data-parsoid='{"dsr":[null,57,null,null]}'>Caption <a rel="mw:WikiLink" href="./Link1" data-parsoid='{"stx":"simple","a":{"href":"./Link1"},"sa":{"href":"Link1"},"dsr":[32,41,2,2]}'>Link1</a>
10067 <a rel="mw:WikiLink" href="./Link2" data-parsoid='{"stx":"simple","a":{"href":"./Link2"},"sa":{"href":"Link2"},"dsr":[47,56,2,2]}'>Link2</a>
10068 </figcaption></figure>
10072 Link with empty target
10081 Image with empty attribute
10083 parsoid=wt2html,wt2wt,html2html
10085 [[File:Foobar.jpg|right||Caption text]]
10087 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption text"><img alt="Caption text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10090 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
10094 1. Block image with individual attributes from templates
10096 [[File:Foobar.jpg|thumb|{{echo|137px}}|This is a caption]]
10098 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption</div></div></div>
10101 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" data-mw='{"attribs":[["thumbnail",{"html":"thumb"}],["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;137px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[24,38,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">137px</span>"}]]}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
10105 2. Block Image with individual attributes from templates
10107 [[File:Foobar.jpg|{{echo|thumb}}|{{echo|137px}}|This is a caption]]
10109 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption</div></div></div>
10112 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" data-mw='{"attribs":[["thumbnail",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;thumb&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[18,32,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">thumb</span>"}],["width",{"html":"<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;137px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[33,47,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">137px</span>"}]]}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
10116 3. Inline image with individual attributes from templates
10118 [[File:Foobar.jpg|{{echo|50px}}]]
10120 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a>
10123 <p><span typeof="mw:Image mw:ExpandedAttrs" about="#mwt2" data-mw='{"attribs":[["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;50px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[18,31,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">50px</span>"}]]}' data-parsoid='{"optList":[{"ck":"width","ak":"{{echo|50px}}"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
10126 ## Parsoid does not provide editing support for images where templates produce multiple image attributes.
10127 ## To signal this, we add a 'mw:Placeholder' type to such images. This could change in the future.
10129 Image with multiple attributes from the same template
10131 [[File:Foobar.jpg|{{image_attribs}}]]
10133 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption text"><img alt="Caption text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10136 <figure class="mw-default-size mw-halign-right" typeof="mw:Image mw:Placeholder"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
10140 Image with link tails
10144 123[[File:Foobar.jpg]]456
10145 123[[File:Foobar.jpg|right]]456
10146 123[[File:Foobar.jpg|thumb]]456
10148 <p>123<a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>456
10150 123<div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>456
10151 123<div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>456
10154 <p>123<span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>456</p>
10155 123<figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>456
10156 123<figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220"></a></figure>456
10160 Image with multiple captions -- only last one is accepted
10162 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
10164 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption3 - accepted"><img alt="Caption3 - accepted" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10167 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption3 - accepted</figcaption></figure>
10171 Image with multiple widths -- use last
10173 [[File:Foobar.jpg|200px|300px|caption]]
10175 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" width="300" height="34" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/450px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/600px-Foobar.jpg 2x" /></a>
10178 <p><span typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="34" width="300"/></a></span></p>
10182 Image with multiple alignments -- use first (bug 48664)
10186 [[File:Foobar.jpg|thumb|left|right|center|caption]]
10188 [[File:Foobar.jpg|middle|text-top|caption]]
10190 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10191 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" style="vertical-align: middle" /></a>
10194 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
10195 <p><span class="mw-default-size mw-valign-middle" typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10199 Image with width attribute at different positions
10201 [[File:Foobar.jpg|200px|right|Caption]]
10202 [[File:Foobar.jpg|right|200px|Caption]]
10203 [[File:Foobar.jpg|right|Caption|200px]]
10205 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption"><img alt="Caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a></div>
10206 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption"><img alt="Caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a></div>
10207 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption"><img alt="Caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a></div>
10210 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
10211 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
10212 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
10215 # a sad bit of backward-compatibility
10217 Image with size specified with pxpx (bug 13500, 51628)
10219 parsoid=wt2html,wt2wt,html2html
10221 [[File:Foobar.jpg|20pxpx]]
10222 [[File:Foobar.jpg|200x20pxpx]]
10224 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/20px-Foobar.jpg" width="20" height="2" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/30px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/40px-Foobar.jpg 2x" /></a>
10225 <a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/177px-Foobar.jpg" width="177" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/265px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/353px-Foobar.jpg 2x" /></a>
10228 <p><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="2" width="20"/></a></span><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="20" width="177"/></a></span></p>
10232 Image with link parameter, wiki target
10234 [[File:Foobar.jpg|link=Main Page]]
10236 <p><a href="/wiki/Main_Page" title="Main Page"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10239 <p><span class="mw-default-size" typeof="mw:Image"><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10242 # parsoid bug 49293 (part 1)
10244 Image with link parameter, URL target
10246 [[File:Foobar.jpg|link=http://example.com/]]
10248 <p><a href="http://example.com/" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10251 <p><span class="mw-default-size" typeof="mw:Image"><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10254 # parsoid bug 49293 (part 2)
10256 Image with link parameter, protocol-less URL target
10258 [[File:Foobar.jpg|link=//example.com/]]
10260 <p><a href="//example.com/" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10263 <p><span class="mw-default-size" typeof="mw:Image"><a href="//example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10267 Image with link parameter, wgExternalLinkTarget
10269 [[Image:foobar.jpg|link=http://example.com/]]
10271 wgExternalLinkTarget='foobar'
10273 <p><a href="http://example.com/" target="foobar" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10278 Image with link parameter, wgNoFollowLinks set to false
10280 [[Image:foobar.jpg|link=http://example.com/]]
10282 wgNoFollowLinks=false
10284 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10289 Image with link parameter, wgNoFollowDomainExceptions
10291 [[Image:foobar.jpg|link=http://example.com/]]
10293 wgNoFollowDomainExceptions='example.com'
10295 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10300 Image with link parameter, wgExternalLinkTarget, unnamed parameter
10302 [[Image:foobar.jpg|link=http://example.com/|Title]]
10304 wgExternalLinkTarget='foobar'
10306 <p><a href="http://example.com/" title="Title" target="foobar" rel="nofollow"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10311 Image with empty link parameter
10313 [[File:Foobar.jpg|link=]]
10315 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
10318 <p><span class="mw-default-size" typeof="mw:Image"><span><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></span></span></p>
10322 Image with link parameter (wiki target) and unnamed parameter
10324 [[File:Foobar.jpg|link=Main_Page|Title]]
10326 <p><a href="/wiki/Main_Page" title="Title"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10329 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10333 Image with link parameter (URL target) and unnamed parameter
10335 [[File:Foobar.jpg|link=http://example.com/|Title]]
10337 <p><a href="http://example.com/" title="Title" rel="nofollow"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10340 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10344 Thumbnail image with link parameter
10347 parsoid=wt2html,wt2wt,html2html
10349 [[File:Foobar.jpg|thumb|link=http://example.com/|Title]]
10351 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="http://example.com/"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10354 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>Title</figcaption></figure>
10358 Manually-specified thumbnail image
10362 [[File:Foobar.jpg|thumb=Thumb.png|Title]]
10364 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/File:Foobar.jpg"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10367 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10371 Manually-specified thumbnail image with explicit link to wiki page
10374 parsoid=wt2html,wt2wt,html2html
10376 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|Title]]
10378 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10381 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10385 Manually-specified thumbnail image with explicit link to url
10388 parsoid=wt2html,wt2wt,html2html
10390 [[File:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
10392 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="http://example.com"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10395 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="http://example.com"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10399 Manually-specified thumbnail image with explicit no link
10402 parsoid=wt2html,wt2wt,html2html
10404 [[File:Foobar.jpg|thumb=Thumb.png|link=|Title]]
10406 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10409 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><span><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></span><figcaption>Title</figcaption></figure>
10413 Manually-specified thumbnail image with explicit link and alt text
10416 parsoid=wt2html,wt2wt,html2html
10418 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|alt=alttext|Title]]
10420 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="alttext" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10423 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="Main_Page"><img alt="alttext" resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10427 Image with frame and link
10429 parsoid=wt2html,wt2wt,html2html
10431 [[File:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
10433 <div class="thumb tleft"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">This is a test image <a href="/wiki/Main_Page" title="Main Page">Main Page</a></div></div></div>
10436 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page">Main Page</a></figcaption></figure>
10440 Image with frame and link and explicit alt
10442 parsoid=wt2html,wt2wt,html2html
10444 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
10446 <div class="thumb tleft"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Altitude" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">This is a test image <a href="/wiki/Main_Page" title="Main Page">Main Page</a></div></div></div>
10449 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img alt="Altitude" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page">Main Page</a></figcaption></figure>
10453 Image with wiki markup in implicit alt
10455 parsoid=wt2html,wt2wt,html2html
10457 [[Image:Foobar.jpg|testing '''bold''' in alt]]
10459 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
10461 <p><a href="/wiki/File:Foobar.jpg" class="image" title="testing bold in alt"><img alt="testing bold in alt" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10462 </p><p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="testing bold in alt" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10465 <p><span class="mw-default-size" typeof="mw:Image" data-mw="{"caption":"testing '''bold''' in alt"}"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10466 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img alt="testing bold in alt" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10469 ###################
10470 # Conflicting image format options.
10471 # First option specified should 'win'.
10472 # All three cases in each test should be identical.
10475 Image with 'frameless' first.
10477 [[File:Foobar.jpg|frameless|caption]]
10479 [[File:Foobar.jpg|frameless|frame|caption]]
10481 [[File:Foobar.jpg|frameless|thumb|caption]]
10483 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>
10484 </p><p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>
10485 </p><p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>
10490 Image with 'frame' first.
10492 [[File:Foobar.jpg|frame|caption]]
10493 [[File:Foobar.jpg|frame|frameless|caption]]
10494 [[File:Foobar.jpg|frame|thumb|caption]]
10496 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">caption</div></div></div>
10497 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">caption</div></div></div>
10498 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">caption</div></div></div>
10503 Image with 'thumb' first.
10505 [[File:Foobar.jpg|thumb|caption]]
10506 [[File:Foobar.jpg|thumb|frameless|caption]]
10507 [[File:Foobar.jpg|thumb|frame|caption]]
10509 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10510 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10511 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10515 ###################
10517 # See https://www.mediawiki.org/wiki/Help:Images#Size_and_frame
10518 # and https://bugzilla.wikimedia.org/show_bug.cgi?id=62258
10519 # Foobar has actual size of 1941x220
10520 # 1. Thumbs & frameless always reduce, can't be enlarged unless it's
10521 # a scalable format.
10522 # 2. Framed images always ignore size options; always render at default size.
10523 # 3. "Unspecified format" and border are the only types which can be
10527 Image: "unspecified format" and border enlarge
10529 parsoid=wt2html,wt2wt,html2html
10531 [[File:Foobar.jpg|2000px]]
10533 [[File:Foobar.jpg|border|2000px]]
10535 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="2000" height="227" /></a>
10536 </p><p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="2000" height="227" class="thumbborder" /></a>
10539 <p><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="227" width="2000"/></a></span></p>
10540 <p><span class="mw-image-border" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="227" width="2000"/></a></span></p>
10544 Image: "unspecified format" and border reduce
10546 parsoid=wt2html,wt2wt,html2html
10548 [[File:Foobar.jpg|1000px]]
10550 [[File:Foobar.jpg|border|1000px]]
10552 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/1000px-Foobar.jpg" width="1000" height="113" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/1500px-Foobar.jpg 1.5x, http://example.com/images/3/3a/Foobar.jpg 2x" /></a>
10553 </p><p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/1000px-Foobar.jpg" width="1000" height="113" class="thumbborder" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/1500px-Foobar.jpg 1.5x, http://example.com/images/3/3a/Foobar.jpg 2x" /></a>
10556 <p><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="113" width="1000"/></a></span></p>
10557 <p><span class="mw-image-border" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="113" width="1000"/></a></span></p>
10561 Image: thumbs reduce
10563 parsoid=wt2html,wt2wt,html2html
10565 [[File:Foobar.jpg|thumb|50px]]
10567 <div class="thumb tright"><div class="thumbinner" style="width:52px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10570 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="6" width="50"/></a></figure>
10574 Image: bitmap thumbs can't be enlarged past original size, but vector can.
10576 parsoid=wt2html,wt2wt,html2html
10578 [[File:Foobar.jpg|thumb|2000px]]
10580 [[File:Foobar.svg|thumb|2000px]]
10582 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10583 <div class="thumb tright"><div class="thumbinner" style="width:2002px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="Foobar.svg" src="http://example.com/images/thumb/f/ff/Foobar.svg/2000px-Foobar.svg.png" width="2000" height="1500" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/3000px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/4000px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10586 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure>
10587 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="1500" width="2000"/></a></figure>
10591 Image: frameless can reduce in size
10593 parsoid=wt2html,wt2wt,html2html
10595 [[File:Foobar.jpg|frameless|50px]]
10597 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a>
10600 <p><span typeof="mw:Image/Frameless"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="6" width="50"/></a></span></p>
10604 Image: bitmap frameless can't be enlarged past original size, but vector can
10606 parsoid=wt2html,wt2wt,html2html
10608 [[File:Foobar.jpg|frameless|2000px]]
10610 [[File:Foobar.svg|frameless|2000px]]
10612 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10613 </p><p><a href="/wiki/File:Foobar.svg" class="image"><img alt="Foobar.svg" src="http://example.com/images/thumb/f/ff/Foobar.svg/2000px-Foobar.svg.png" width="2000" height="1500" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/3000px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/4000px-Foobar.svg.png 2x" /></a>
10616 <p><span typeof="mw:Image/Frameless"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10617 <p><span typeof="mw:Image/Frameless"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="1500" width="2000"/></a></span></p>
10621 Image: framed images are always unscaled.
10623 parsoid=wt2html,wt2wt,html2html
10625 [[File:Foobar.jpg|frame]]
10627 [[File:Foobar.jpg|frame|50px]]
10629 [[File:Foobar.jpg|frame|50x50px]]
10631 [[File:Foobar.jpg|frame|2000px]]
10633 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10634 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10635 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10636 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10639 <figure class="mw-default-size" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure>
10642 ###################
10645 Link to image page- image page normally doesn't exists, hence edit link
10646 Add test with existing image page
10647 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
10651 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
10656 bug 18784 Link to non-existent image page with caption should use caption as link text
10658 [[:Image:test|caption]]
10660 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
10665 Frameless image caption with a free URL
10667 [[File:Foobar.jpg|http://example.com]]
10669 <p><a href="/wiki/File:Foobar.jpg" class="image" title="http://example.com"><img alt="http://example.com" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10672 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"http://example.com"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10676 Thumbnail image caption with a free URL
10680 [[File:Foobar.jpg|thumb|http://example.com]]
10682 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
10685 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
10689 Thumbnail image caption with a free URL and explicit alt
10692 parsoid=wt2html,wt2wt,html2html
10694 [[File:Foobar.jpg|thumb|http://example.com|alt=Alteration]]
10696 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
10699 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img alt="Alteration" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
10703 SVG thumbnails with no language set
10706 [[File:Foobar.svg|thumb|caption]]
10708 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10711 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="165" width="220"/></a><figcaption>caption</figcaption></figure>
10715 SVG thumbnails with language de
10717 parsoid=wt2html,wt2wt,html2html
10719 [[File:Foobar.svg|thumb|caption|lang=de]]
10721 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=File:Foobar.svg&lang=de" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/langde-180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/langde-270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/langde-360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10724 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" lang="de" height="165" width="220"/></a><figcaption>caption</figcaption></figure>
10728 SVG thumbnails with invalid language code
10730 parsoid=wt2html,wt2wt,html2html
10732 [[File:Foobar.svg|thumb|caption|lang=invalid.language.code]]
10734 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>lang=invalid.language.code</div></div></div>
10737 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="165" width="220"/></a><figcaption>lang=invalid.language.code</figcaption></figure>
10741 BUG 1887: A ISBN with a thumbnail
10743 [[File:Foobar.jpg|thumb|ISBN 1235467890]]
10745 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div>
10748 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption><a href="Special:BookSources/1235467890" rel="mw:ExtLink">ISBN 1235467890</a></figcaption></figure>
10752 BUG 1887: A RFC with a thumbnail
10754 [[File:Foobar.jpg|thumb|This is RFC 12354]]
10756 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
10759 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>This is <a href="//tools.ietf.org/html/rfc12354" rel="mw:ExtLink">RFC 12354</a></figcaption></figure>
10763 BUG 1887: A mailto link with a thumbnail
10765 [[File:Foobar.jpg|thumb|Please mailto:nobody@example.com]]
10767 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a rel="nofollow" class="external free" href="mailto:nobody@example.com">mailto:nobody@example.com</a></div></div></div>
10770 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>Please <a rel="mw:ExtLink" href="mailto:nobody@example.com">mailto:nobody@example.com</a></figcaption></figure>
10773 # Pending resolution to bug 368
10775 BUG 648: Frameless image caption with a link
10777 [[File:Foobar.jpg|text with a [[link]] in it]]
10779 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a link in it"><img alt="text with a link in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10782 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[link]] in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10786 BUG 648: Frameless image caption with a link (suffix)
10788 [[File:Foobar.jpg|text with a [[link]]foo in it]]
10790 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a linkfoo in it"><img alt="text with a linkfoo in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10793 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[link]]foo in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10797 BUG 648: Frameless image caption with an interwiki link
10799 [[File:Foobar.jpg|text with a [[MeatBall:Link]] in it]]
10801 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a MeatBall:Link in it"><img alt="text with a MeatBall:Link in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10804 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[MeatBall:Link]] in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10808 BUG 648: Frameless image caption with a piped interwiki link
10810 [[File:Foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
10812 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a link in it"><img alt="text with a link in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10815 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[MeatBall:Link|link]] in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10819 Escape HTML special chars in image alt text
10821 [[File:Foobar.jpg|& < > "]]
10823 <p><a href="/wiki/File:Foobar.jpg" class="image" title="& < > ""><img alt="& < > "" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10826 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"& < > \""}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10830 BUG 499: Alt text should have Ӓ, not &1234;
10832 [[File:Foobar.jpg|♀]]
10834 <p><a href="/wiki/File:Foobar.jpg" class="image" title="♀"><img alt="♀" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10837 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"&#9792;"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10841 Broken image caption with link
10843 parsoid=wt2html,wt2wt,html2html
10845 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
10847 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a href="/wiki/Main_Page" title="Main Page">this</a> is just an ordinary link.
10850 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="Main_Page">this</a> is just an ordinary link.</p>
10854 Image caption containing another image
10856 [[File:Foobar.jpg|thumb|This is a caption with another [[File:Thumb.png|image]] inside it!]]
10858 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption with another <a href="/wiki/File:Thumb.png" class="image" title="image"><img alt="image" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" /></a> inside it!</div></div></div>
10861 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>This is a caption with another <span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"image"}'><a href="File:Thumb.png"><img resource="./File:Thumb.png" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a></span> inside it!</figcaption></figure>
10865 Image: caption containing a newline
10867 [[File:Foobar.jpg|This
10870 <p><a href="/wiki/File:Foobar.jpg" class="image" title="This *is some text"><img alt="This *is some text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10873 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"This\n*is some text"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10877 Image: caption containing leading space
10878 (The leading space should not trigger nowiki escaping in wt2wt mode)
10880 [[File:Foobar.jpg|thumb| bar]]
10882 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>bar</div></div></div>
10885 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption> bar</figcaption></figure>
10889 Image: caption containing a table
10891 parsoid=wt2html,wt2wt,html2html
10893 [[Image:Foobar.jpg|thumb|200px|This is an example image thumbnail caption with a table
10899 and some more text.]]
10901 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is an example image thumbnail caption with a table <table> <tr> <th> Foo </th> <th> Bar </th></tr> <tr> <td> Foo1 </td> <td> Bar1 </td></tr></table> and some more text.</div></div></div>
10904 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="23" width="200"/></a><figcaption>This is an example image thumbnail caption with a table
10907 <tr><th>Foo </th><th>Bar</th></tr>
10910 <td>Bar1</td></tr></tbody></table>and some more text.</figcaption></figure>
10914 Bug 3090: External links other than http: in image captions
10916 [[File:Foobar.jpg|thumb|200x200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
10918 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a rel="nofollow" class="external text" href="irc://example.net">irc</a> and <a rel="nofollow" class="external text" href="https://example.com">Secure</a> ext links in it.</div></div></div>
10921 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="23" width="200"/></a><figcaption>This caption has <a rel="mw:ExtLink" href="irc://example.net">irc</a> and <a rel="mw:ExtLink" href="https://example.com">Secure</a> ext links in it.</figcaption></figure>
10927 parsoid=wt2html,wt2wt,html2html
10929 [[Image:foobar.jpg|a|class=b]]
10931 <p><a href="/wiki/File:Foobar.jpg" class="image" title="a"><img alt="a" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="b" /></a>
10934 <p><span class="mw-default-size b" typeof="mw:Image" data-mw='{"caption":"a"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10938 Localized image handling (1).
10940 parsoid=wt2html,wt2wt,html2html
10943 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
10945 <div class="floatleft"><a href="/wiki/Foo" title="caption"><img alt="caption" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10948 <figure class="mw-default-size mw-halign-left" typeof="mw:Image"><a href="./Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
10952 Localized image handling (2).
10955 parsoid=wt2html,wt2wt,html2html
10958 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
10960 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/Foo" title="Foo"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/Archivo:Foobar.jpg" class="internal" title="Aumentar"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10963 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="./Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
10967 "border", "frameless" and "class" attributes on an image.
10970 parsoid=wt2html,wt2wt,html2html
10972 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
10974 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="extra thumbborder" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a>
10977 <p><span class="mw-default-size mw-image-border extra" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}'><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a></span></p>
10980 # Note that 'right' is the default alignment, despite the misspelled 'righ' below
10982 Invalid image attributes (bug 62500)
10985 parsoid=wt2html,wt2wt,html2html
10987 [[File:Foobar.jpg|thumb|float|left|caption]]
10989 [[File:Foobar.jpg|thumb|righ|caption]]
10991 [[File:Foobar.jpg|bogus1|thumb|bogus2|left|bogus3|caption]]
10993 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10994 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10995 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10998 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
11004 #REDIRECT [[File:Barfoo.jpg]]
11010 [[Image:Barfoo.jpg]]
11012 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
11017 Missing image with uploads disabled
11021 [[Image:Foobaz.jpg]]
11023 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
11027 # Parsoid-specific testing for images
11028 # https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
11029 # Currently imperfect due to a flaw in the Parsoid testrunner
11031 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
11035 Parsoid-specific image handling - simple image with size and middle alignment
11037 [[File:Foobar.jpg|middle|50px]]
11039 <p><span class="mw-valign-middle" typeof="mw:Image">
11040 <a href="File:Foobar.jpg">
11041 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
11048 Parsoid-specific image handling - simple image with size, middle alignment,
11049 non-standard namespace alias
11051 parsoid=wt2wt,wt2html,html2html
11053 [[Image:Foobar.jpg|middle|50px]]
11055 <p><span class="mw-valign-middle" typeof="mw:Image">
11056 <a href="File:Foobar.jpg">
11057 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
11064 Parsoid-specific image handling - simple image with size and middle alignment
11067 [[File:Foobar.jpg|50px|middle]]
11069 <p><span class="mw-valign-middle" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"width","ak":"50px"},{"ck":"middle","ak":"middle"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
11073 Parsoid-specific image handling - simple image with size and middle alignment
11074 and non-standard namespace name
11076 parsoid=wt2html,wt2wt,html2html
11078 [[Image:Foobar.jpg|50px|middle]]
11080 <p><span class="mw-valign-middle" typeof="mw:Image">
11081 <a href="File:Foobar.jpg">
11082 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
11089 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
11091 [[File:Foobar.jpg|500x10px|baseline|caption]]
11093 <p><span class="mw-valign-baseline" typeof="mw:Image" data-mw='{"caption":"caption"}' data-parsoid='{"optList":[{"ck":"width","ak":"500x10px"},{"ck":"baseline","ak":"baseline"},{"ck":"caption","ak":"caption"}],"size":"500x10"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/89px-Foobar.jpg" height="10" width="89" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"10","width":"89"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
11097 Parsoid-specific image handling - simple image with border and size spec
11099 [[File:Foobar.jpg|50px|border|caption]]
11101 <p><span class="mw-image-border" typeof="mw:Image" data-mw='{"caption":"caption"}' data-parsoid='{"optList":[{"ck":"width","ak":"50px"},{"ck":"border","ak":"border"},{"ck":"caption","ak":"caption"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
11105 Parsoid-specific image handling - thumbnail with halign, valign, and caption
11107 [[File:Foobar.jpg|left|baseline|thumb|caption content]]
11109 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb">
11110 <a href="File:Foobar.jpg">
11111 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220" />
11113 <figcaption>caption content</figcaption>
11118 Parsoid-specific image handling - thumbnail with halign, valign, and caption
11121 [[File:Foobar.jpg|thumb|left|baseline|caption content]]
11123 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"left","ak":"left"},{"ck":"baseline","ak":"baseline"},{"ck":"caption","ak":"caption content"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>caption content</figcaption></figure>
11127 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
11129 [[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
11131 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb">
11132 <a href="File:Foobar.jpg">
11133 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" />
11135 <figcaption>caption</figcaption>
11140 Parsoid-specific image handling - thumbnail with specific size, halign,
11141 valign, and caption (existing content)
11143 [[File:Foobar.jpg|thumb|50x50px|right|middle|caption]]
11145 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"50x50px"},{"ck":"right","ak":"right"},{"ck":"middle","ak":"middle"},{"ck":"caption","ak":"caption"}],"size":"50x50"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>caption</figcaption></figure>
11149 Parsoid-specific image handling - framed image with specific size and caption
11152 parsoid=wt2html,wt2wt,html2html
11154 [[File:Foobar.jpg|frame|500x50px|caption]]
11156 <figure typeof="mw:Image/Frame">
11157 <a href="File:Foobar.jpg">
11158 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941" />
11160 <figcaption>caption</figcaption>
11165 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
11168 parsoid=wt2html,wt2wt,html2html
11170 [[File:Foobar.jpg|left|baseline|frame|500x50px|caption]]
11172 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame">
11173 <a href="File:Foobar.jpg">
11174 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941" />
11176 <figcaption>caption</figcaption>
11181 Parsoid-specific image handling - frameless image with specific size, border, and caption
11183 [[File:Foobar.jpg|frameless|442x50px|border|caption]]
11185 <p><span class="mw-image-border" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}' data-parsoid='{"optList":[{"ck":"frameless","ak":"frameless"},{"ck":"width","ak":"442x50px"},{"ck":"border","ak":"border"},{"ck":"caption","ak":"caption"}],"size":"442x50"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"50","width":"442"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
11189 Parsoid-specific image handling - simple image with a formatted caption
11191 [[File:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
11193 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>"}'>
11194 <a href="File:Foobar.jpg">
11195 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941">
11200 Parsoid-specific image handling - caption with a template in it
11202 [[File:Foobar.jpg|thumb|200x23px|This caption has a {{echo|transclusion}} in it.]]
11204 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>This caption has a <span about="#mwt1" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}">transclusion</span> in it.</figcaption></figure>
11208 Parsoid-specific image handling - caption with unbalanced tags in it
11210 parsoid=wt2html,wt2wt,html2html
11213 [[File:Foobar.jpg|thumb|200x200px|This caption has a <center>unbalanced tag in it.]]
11217 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="23" width="200"></a><figcaption>This caption has a <center>unbalanced tag in it.</center></figcaption></figure>
11222 Parsoid-specific image handling - empty caption (1)
11224 parsoid=wt2html,wt2wt
11226 [[File:Foobar.jpg|thumb|]]
11228 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption></figcaption></figure>
11231 # empty captions don't get serialized unless we're in the "round trip" case
11233 Parsoid-specific image handling - empty caption (2)
11237 <figure class="mw-default-size" typeof="mw:Image/Thumb">
11238 <a href="File:Foobar.jpg">
11239 <img resource="./File:Foobar.jpg"
11240 src="//example.com/images/3/3a/Foobar.jpg"
11241 height="25" width="220"/>
11243 <figcaption></figcaption>
11246 [[File:Foobar.jpg|thumb]]
11250 Parsoid-specific image handling - whitespace caption
11252 [[File:Foobar.jpg|thumb| ]]
11254 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption> </figcaption></figure>
11258 Parsoid-specific image handling - lang option
11261 [[File:Foobar.svg|lang=de|caption]]
11265 <span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="./File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" lang="de" height="180" width="240"/></a></span>
11274 Subpage test/subpage
11282 subpage title=[[Subpage test]]
11286 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
11291 Subpage noslash link
11293 subpage title=[[Subpage test]]
11297 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
11301 # TODO: make this PHP-parser compatible!
11303 Relative subpage noslash link
11305 parsoid=wt2wt,wt2html,html2html
11306 subpage title=[[Subpage test/1/2/3/4]]
11312 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage/">subpage</a></p>
11313 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
11317 Parsoid: dot-slash prefixed wikilinks
11327 </p><p>[[././baz/]]
11332 </p><p>[[././baz/]]
11337 Render invalid page names as plain text (bug 51090)
11350 [[{{echo|./../foo}}|bar]]
11351 [[{{echo|foo/.}}|bar]]
11352 [[{{echo|foo/..}}|bar]]
11353 [[{{echo|foo~~~~bar}}]]
11354 [[{{echo|foo>bar}}]]
11355 [[{{echo|foo././bar}}]]
11356 [[{{echo|foo{bar}}]]
11357 [[{{echo|foo}bar}}]]
11358 [[{{echo|foo[bar}}]]
11359 [[{{echo|foo]bar}}]]
11360 [[{{echo|foo<bar}}]]
11362 <p>[[./../foo|bar]]
11372 </p><p>[[./../foo|bar]]
11385 <p>[[./../foo|bar]][[foo�|bar]][[foo/.|bar]][[foo/..|bar]][[foo~~~bar]][[foo>bar]][[foo[bar]][[.]][[..]][[foo././bar]]</p>
11386 <p>[[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"./../foo"}},"i":0}}]}'>./../foo</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/."}},"i":0}}]}'>foo/.</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/.."}},"i":0}}]}'>foo/..</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo~~~~bar"}},"i":0}}]}'>foo~~~~bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo>bar"}},"i":0}}]}'>foo>bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo././bar"}},"i":0}}]}'>foo././bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo{bar"}},"i":0}}]}'>foo{bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo}bar"}},"i":0}}]}'>foo}bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo[bar"}},"i":0}}]}'>foo[bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo]bar"}},"i":0}}]}'>foo]bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<bar"}},"i":0}}]}'>foo<bar</span>]]</p>
11394 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
11399 BUG 561: {{/Subpage}}
11401 subpage title=[[Page]]
11405 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
11413 Category:MediaWiki User's Guide
11421 [[:Category:MediaWiki User's Guide]]
11423 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
11432 [[Category:MediaWiki User's Guide]]
11434 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11438 PAGESINCATEGORY invalid title fatal (r33546 fix)
11440 {{PAGESINCATEGORY:<bogus>}}
11447 Category with different sort key
11451 [[Category:MediaWiki User's Guide|Foo]]
11453 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11457 Category with identical sort key
11461 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
11463 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11467 Category with empty sort key
11472 [[Category:MediaWiki User's Guide|]]
11474 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
11478 Category with empty sort key and parentheses
11483 [[Category:Foo (bar)|]]
11485 [[Category:Foo (bar)|Foo]]
11489 Category with link tail
11494 123[[Category:Foo]]456
11496 123[[Category:Foo]]456
11500 Category with template
11505 [[Category:{{echo|Foo}}]]
11507 [[Category:{{echo|Foo}}]]
11511 Category with template in sort key
11516 [[Category:Foo|{{echo|Bar}}]]
11518 [[Category:Foo|{{echo|Bar}}]]
11522 Category with template in sort key and title
11527 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
11529 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
11533 Category / paragraph interactions
11535 Foo [[Category:Baz]] Bar
11537 Foo [[Category:Baz]]
11545 [[Category:Baz]] Bar
11558 {{echo|[[Category:Baz]]}}
11573 Parsoid: Serialize link to category page with colon escape
11579 [[:Category:Foo|Bar]]
11582 <a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a>
11583 <a rel="mw:WikiLink" href="Category:Foo">Bar</a>
11588 Parsoid: Link prefix/suffixes aren't applied to category links
11590 parsoid=wt2html,wt2wt,html2html
11595 <p>x<link rel="mw:PageProp/Category" href="Category:Foo">y</p>
11599 Parsoid: Serialize link to file page with colon escape
11605 [[:File:Foo.png|Bar]]
11608 <a rel="mw:WikiLink" href="File:Foo.png">File:Foo.png</a>
11609 <a rel="mw:WikiLink" href="File:Foo.png">Bar</a>
11614 Parsoid: Serialize a genuine category link without colon escape
11619 [[Category:Foo|Bar]]
11621 <link rel="mw:PageProp/Category" href="Category:Foo">
11622 <link rel="mw:PageProp/Category" href="Category:Foo#Bar">
11626 Parsoid: Defaultsort
11630 {{DEFAULTSORT:Foo}}
11632 <meta property="mw:PageProp/categorydefaultsort" content="Foo"/>
11636 ### Inter-language links
11639 Inter-language links
11645 [[zh:食品]]
11647 es:Alimento fr:Nourriture zh:食品
11651 Duplicate interlanguage links (bug 24502)
11667 Basic section headings
11674 ===Smaller headline===
11677 <h2><span class="mw-headline" id="Headline_1">Headline 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Headline 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11680 <h2><span class="mw-headline" id="Headline_2">Headline 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Headline 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11683 <h3><span class="mw-headline" id="Smaller_headline">Smaller headline</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Smaller headline">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11689 Section headings with TOC
11692 === Subheadline 1 ===
11693 ===== Skipping a level =====
11694 ====== Skipping a level ======
11698 ===Another headline===
11700 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11702 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
11704 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
11706 <li class="toclevel-3 tocsection-3"><a href="#Skipping_a_level"><span class="tocnumber">1.1.1</span> <span class="toctext">Skipping a level</span></a>
11708 <li class="toclevel-4 tocsection-4"><a href="#Skipping_a_level_2"><span class="tocnumber">1.1.1.1</span> <span class="toctext">Skipping a level</span></a></li>
11715 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
11717 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
11723 <h2><span class="mw-headline" id="Headline_1">Headline 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Headline 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11724 <h3><span class="mw-headline" id="Subheadline_1">Subheadline 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Subheadline 1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11725 <h5><span class="mw-headline" id="Skipping_a_level">Skipping a level</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Skipping a level">edit</a><span class="mw-editsection-bracket">]</span></span></h5>
11726 <h6><span class="mw-headline" id="Skipping_a_level_2">Skipping a level</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Skipping a level">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11727 <h2><span class="mw-headline" id="Headline_2">Headline 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Headline 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11730 <h3><span class="mw-headline" id="Another_headline">Another headline</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Another headline">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11734 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
11736 Handling of sections up to level 6 and beyond
11739 == Level 2 Heading==
11740 === Level 3 Heading===
11741 ==== Level 4 Heading====
11742 ===== Level 5 Heading=====
11743 ====== Level 6 Heading======
11744 ======= Level 7 Heading=======
11745 ======== Level 8 Heading========
11746 ========= Level 9 Heading=========
11747 ========== Level 10 Heading==========
11749 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11751 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
11753 <li class="toclevel-2 tocsection-2"><a href="#Level_2_Heading"><span class="tocnumber">1.1</span> <span class="toctext">Level 2 Heading</span></a>
11755 <li class="toclevel-3 tocsection-3"><a href="#Level_3_Heading"><span class="tocnumber">1.1.1</span> <span class="toctext">Level 3 Heading</span></a>
11757 <li class="toclevel-4 tocsection-4"><a href="#Level_4_Heading"><span class="tocnumber">1.1.1.1</span> <span class="toctext">Level 4 Heading</span></a>
11759 <li class="toclevel-5 tocsection-5"><a href="#Level_5_Heading"><span class="tocnumber">1.1.1.1.1</span> <span class="toctext">Level 5 Heading</span></a>
11761 <li class="toclevel-6 tocsection-6"><a href="#Level_6_Heading"><span class="tocnumber">1.1.1.1.1.1</span> <span class="toctext">Level 6 Heading</span></a></li>
11762 <li class="toclevel-6 tocsection-7"><a href="#.3D_Level_7_Heading.3D"><span class="tocnumber">1.1.1.1.1.2</span> <span class="toctext">= Level 7 Heading=</span></a></li>
11763 <li class="toclevel-6 tocsection-8"><a href="#.3D.3D_Level_8_Heading.3D.3D"><span class="tocnumber">1.1.1.1.1.3</span> <span class="toctext">== Level 8 Heading==</span></a></li>
11764 <li class="toclevel-6 tocsection-9"><a href="#.3D.3D.3D_Level_9_Heading.3D.3D.3D"><span class="tocnumber">1.1.1.1.1.4</span> <span class="toctext">=== Level 9 Heading===</span></a></li>
11765 <li class="toclevel-6 tocsection-10"><a href="#.3D.3D.3D.3D_Level_10_Heading.3D.3D.3D.3D"><span class="tocnumber">1.1.1.1.1.5</span> <span class="toctext">==== Level 10 Heading====</span></a></li>
11779 <h1><span class="mw-headline" id="Level_1_Heading">Level 1 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Level 1 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11780 <h2><span class="mw-headline" id="Level_2_Heading">Level 2 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Level 2 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11781 <h3><span class="mw-headline" id="Level_3_Heading">Level 3 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Level 3 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11782 <h4><span class="mw-headline" id="Level_4_Heading">Level 4 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Level 4 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11783 <h5><span class="mw-headline" id="Level_5_Heading">Level 5 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Level 5 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h5>
11784 <h6><span class="mw-headline" id="Level_6_Heading">Level 6 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Level 6 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11785 <h6><span class="mw-headline" id=".3D_Level_7_Heading.3D">= Level 7 Heading=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=7" title="Edit section: = Level 7 Heading=">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11786 <h6><span class="mw-headline" id=".3D.3D_Level_8_Heading.3D.3D">== Level 8 Heading==</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=8" title="Edit section: == Level 8 Heading==">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11787 <h6><span class="mw-headline" id=".3D.3D.3D_Level_9_Heading.3D.3D.3D">=== Level 9 Heading===</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=9" title="Edit section: === Level 9 Heading===">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11788 <h6><span class="mw-headline" id=".3D.3D.3D.3D_Level_10_Heading.3D.3D.3D.3D">==== Level 10 Heading====</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=10" title="Edit section: ==== Level 10 Heading====">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11793 TOC regression (bug 9764)
11797 ==== title 1.1.1 ====
11802 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11804 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
11806 <li class="toclevel-2 tocsection-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a>
11808 <li class="toclevel-3 tocsection-3"><a href="#title_1.1.1"><span class="tocnumber">1.1.1</span> <span class="toctext">title 1.1.1</span></a></li>
11811 <li class="toclevel-2 tocsection-4"><a href="#title_1.2"><span class="tocnumber">1.2</span> <span class="toctext">title 1.2</span></a></li>
11814 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
11816 <li class="toclevel-2 tocsection-6"><a href="#title_2.1"><span class="tocnumber">2.1</span> <span class="toctext">title 2.1</span></a></li>
11822 <h2><span class="mw-headline" id="title_1">title 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11823 <h3><span class="mw-headline" id="title_1.1">title 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11824 <h4><span class="mw-headline" id="title_1.1.1">title 1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11825 <h3><span class="mw-headline" id="title_1.2">title 1.2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: title 1.2">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11826 <h2><span class="mw-headline" id="title_2">title 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: title 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11827 <h3><span class="mw-headline" id="title_2.1">title 2.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: title 2.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11832 TOC with wgMaxTocLevel=3 (bug 6204)
11838 ==== title 1.1.1 ====
11843 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11845 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
11847 <li class="toclevel-2 tocsection-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a></li>
11848 <li class="toclevel-2 tocsection-4"><a href="#title_1.2"><span class="tocnumber">1.2</span> <span class="toctext">title 1.2</span></a></li>
11851 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
11853 <li class="toclevel-2 tocsection-6"><a href="#title_2.1"><span class="tocnumber">2.1</span> <span class="toctext">title 2.1</span></a></li>
11859 <h2><span class="mw-headline" id="title_1">title 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11860 <h3><span class="mw-headline" id="title_1.1">title 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11861 <h4><span class="mw-headline" id="title_1.1.1">title 1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11862 <h3><span class="mw-headline" id="title_1.2">title 1.2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: title 1.2">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11863 <h2><span class="mw-headline" id="title_2">title 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: title 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11864 <h3><span class="mw-headline" id="title_2.1">title 2.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: title 2.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11869 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
11875 ====Section 1.1.1====
11876 ====Section 1.1.1.1====
11879 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11881 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
11883 <li class="toclevel-2 tocsection-2"><a href="#Section_1.1"><span class="tocnumber">1.1</span> <span class="toctext">Section 1.1</span></a></li>
11886 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
11890 <h2><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11891 <h3><span class="mw-headline" id="Section_1.1">Section 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11892 <h4><span class="mw-headline" id="Section_1.1.1">Section 1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Section 1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11893 <h4><span class="mw-headline" id="Section_1.1.1.1">Section 1.1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Section 1.1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11894 <h2><span class="mw-headline" id="Section_2">Section 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Section 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11900 Resolving duplicate section names
11905 <h2><span class="mw-headline" id="Foo_bar">Foo bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11906 <h2><span class="mw-headline" id="Foo_bar_2">Foo bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11911 Resolving duplicate section names with differing case (bug 10721)
11916 <h2><span class="mw-headline" id="Foo_bar">Foo bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11917 <h2><span class="mw-headline" id="Foo_Bar_2">Foo Bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11929 Template with sections, __NOTOC__
11936 <h2><span class="mw-headline" id="Section_0">Section 0</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 0">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11937 <h3><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Sections&action=edit&section=T-1" title="Template:Sections">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11938 <h2><span class="mw-headline" id="Section_2">Section 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Sections&action=edit&section=T-2" title="Template:Sections">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11939 <h2><span class="mw-headline" id="Section_4">Section 4</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 4">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11944 __NOEDITSECTION__ keyword
11950 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
11951 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
11956 Link inside a section heading
11958 ==Section with a [[Main Page|link]] in it==
11960 <h2><span class="mw-headline" id="Section_with_a_link_in_it">Section with a <a href="/wiki/Main_Page" title="Main Page">link</a> in it</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section with a link in it">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11965 TOC regression (bug 12077)
11972 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11974 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
11976 <li class="toclevel-2 tocsection-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a></li>
11979 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
11983 <h2><span class="mw-headline" id="title_1">title 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11984 <h3><span class="mw-headline" id="title_1.1">title 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11985 <h2><span class="mw-headline" id="title_2">title 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11990 BUG 1219 URL next to image (good)
11992 http://example.com [[Image:foobar.jpg]]
11994 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> <a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11999 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
12002 The line above must have a trailing space!
12005 But just in case it doesn't...
12007 <h1><span class="mw-headline" id=".3D">=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: =">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
12008 <p>The line above must have a trailing space!
12010 <h1><span class="mw-headline" id=".3D_2">=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: =">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
12011 <p>But just in case it doesn't...
12016 Header with special characters (bug 25462)
12018 The tooltips shall not show entities to the user (ie. be double escaped)
12035 <p>The tooltips shall not show entities to the user (ie. be double escaped)
12037 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12039 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
12040 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
12041 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
12042 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
12043 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
12047 <h2><span class="mw-headline" id="text_.3E_text">text > text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: text > text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
12050 <h2><span class="mw-headline" id="text_.3C_text">text < text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: text < text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
12053 <h2><span class="mw-headline" id="text_.26_text">text & text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: text & text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
12056 <h2><span class="mw-headline" id="text_.27_text">text ' text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: text ' text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
12059 <h2><span class="mw-headline" id="text_.22_text">text " text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: text " text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
12065 Headers with excess '=' characters
12066 (Are similar tests necessary beyond the 1st level?)
12070 =''italic'' heading==
12071 ==''italic'' heading=
12073 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12075 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
12076 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
12077 <li class="toclevel-1 tocsection-3"><a href="#italic_heading.3D"><span class="tocnumber">3</span> <span class="toctext"><i>italic</i> heading=</span></a></li>
12078 <li class="toclevel-1 tocsection-4"><a href="#.3Ditalic_heading"><span class="tocnumber">4</span> <span class="toctext">=<i>italic</i> heading</span></a></li>
12082 <h1><span class="mw-headline" id="foo.3D">foo=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: foo=">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
12083 <h1><span class="mw-headline" id=".3Dfoo">=foo</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: =foo">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
12084 <h1><span class="mw-headline" id="italic_heading.3D"><i>italic</i> heading=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: italic heading=">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
12085 <h1><span class="mw-headline" id=".3Ditalic_heading">=<i>italic</i> heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: =italic heading">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
12090 HTML headers vs TOC (bug 23393)
12091 (__NOEDITSECTION__ for clearer output, doesn't matter here)
12103 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12105 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
12107 <li class="toclevel-2 tocsection-1"><a href="#Header_1.1"><span class="tocnumber">1.1</span> <span class="toctext">Header 1.1</span></a></li>
12108 <li class="toclevel-2 tocsection-2"><a href="#Header_1.2"><span class="tocnumber">1.2</span> <span class="toctext">Header 1.2</span></a></li>
12111 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
12113 <li class="toclevel-2 tocsection-3"><a href="#Header_2.1"><span class="tocnumber">2.1</span> <span class="toctext">Header 2.1</span></a></li>
12114 <li class="toclevel-2 tocsection-4"><a href="#Header_2.2"><span class="tocnumber">2.2</span> <span class="toctext">Header 2.2</span></a></li>
12120 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
12121 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
12122 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
12123 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
12124 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
12125 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
12130 Single-line or multiline-comments can follow headings
12132 parsoid=wt2html,wt2wt
12140 <h2><span class="mw-headline" id="foo">foo</span></h2>
12141 <h2><span class="mw-headline" id="bar">bar</span></h2>
12142 <h2><span class="mw-headline" id="baz">baz</span></h2>
12147 BUG 1219 URL next to image (broken)
12149 http://example.com[[Image:foobar.jpg]]
12151 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
12156 Bug 1186 news: in the middle of text
12158 http://en.wikinews.org/wiki/Wikinews:Workplace
12160 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
12166 Namespaced link must have a title
12175 Namespaced link must have a title (bad fragment version)
12177 [[Project:#fragment]]
12179 <p>[[Project:#fragment]]
12185 ### HTML tags and HTML attributes
12189 div with no attributes
12191 <div>HTML rocks</div>
12193 <div>HTML rocks</div>
12198 div with double-quoted attribute
12200 <div id="rock">HTML rocks</div>
12202 <div id="rock">HTML rocks</div>
12207 div with single-quoted attribute
12209 <div id='rock'>HTML rocks</div>
12211 <div id="rock">HTML rocks</div>
12216 div with unquoted attribute
12218 <div id=rock>HTML rocks</div>
12220 <div id="rock">HTML rocks</div>
12225 div with illegal double attributes
12227 <div id="a" id="b">HTML rocks</div>
12229 <div id="b">HTML rocks</div>
12233 # FIXME: produce empty string instead of "class" in the PHP parser, following
12236 div with empty attribute value, space before equals
12240 <div class =>HTML rocks</div>
12242 <div class="">HTML rocks</div>
12246 # The PHP parser escapes the opening brace to { for some reason, so
12247 # disabled this test for it.
12249 div with braces in attribute value
12253 <div title="{}">Foo</div>
12255 <div title="{}">Foo</div>
12258 # This it very inconsistent in the PHP parser: it returns
12259 # class="class" if there is a space between the name and the equal sign (see
12260 # 'div with empty attribute value, space before equals'), but strips the
12261 # attribute completely if the space is missing. We hope that not much content
12262 # depends on this, so are implementing the behavior below in Parsoid for
12263 # consistencies' sake. Disabled for the PHP parser.
12264 # FIXME: fix this behavior in the PHP parser?
12266 div with empty attribute value, no space before equals
12270 <div class=>HTML rocks</div>
12272 <div class="">HTML rocks</div>
12277 HTML multiple attributes correction
12279 <p class="error" class="awesome">Awesome!</p>
12281 <p class="awesome">Awesome!</p>
12286 Table multiple attributes correction
12289 !+ class="error" class="awesome"| status
12294 <th class="awesome"> status
12302 <DIV ID="x">HTML ROCKS</DIV>
12304 <div id="x">HTML ROCKS</div>
12309 Non-ASCII pseudo-tags are rendered as text
12318 Pseudo-tag with URL 'name' renders as url link
12320 <http://example.com/>
12322 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
12327 text with amp in the middle of nowhere
12331 <p>Remember AT&T?
12336 text with character entity: eacute
12338 I always thought é was a cute letter.
12340 <p>I always thought é was a cute letter.
12345 text with entity-escaped character entity-like string: eacute
12347 I always thought &eacute; was a cute letter.
12349 <p>I always thought &eacute; was a cute letter.
12354 text with undefined character entity: xacute
12356 I always thought &xacute; was a cute letter.
12358 <p>I always thought &xacute; was a cute letter.
12362 # TODO: generalize to PHP parser?
12368 <data value="5">five</data>
12369 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
12370 <mark>This highlighted text</mark>
12372 <p><data value="5">five</data>
12373 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
12374 <mark>This highlighted text</mark></p>
12378 HTML tag with leading space is parsed as text
12382 <p>< div>foo< /div>
12387 ### Nesting tests (see bug 41545, 50604, 51081)
12390 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
12391 # Note that html2wt is considerably more difficult if we use <b> in
12392 # the test case, instead of <big>
12394 Ensure that HTML adoption agency algorithm is properly implemented.
12396 <big>X<big>Y</big>Z</big>
12398 <p><big>X<big>Y</big>Z</big>
12402 # This was bug 41545 in the PHP parser.
12406 <kbd>X<kbd>Y</kbd>Z</kbd>
12408 <p><kbd>X<kbd>Y</kbd>Z</kbd>
12412 # The following cases were bug 51081 in the PHP parser.
12413 # Note that there are some other nestable tags (b, i, etc) which are
12414 # not covered; see bug 51081 for discussion.
12418 <em>X<em>Y</em>Z</em>
12420 <p><em>X<em>Y</em>Z</em>
12425 Nesting of <strong>
12427 <strong>X<strong>Y</strong>Z</strong>
12429 <p><strong>X<strong>Y</strong>Z</strong>
12438 <p><q>X<q>Y</q>Z</q>
12445 <ruby>X<ruby>Y</ruby>Z</ruby>
12447 <p><ruby>X<ruby>Y</ruby>Z</ruby>
12454 <bdo>X<bdo>Y</bdo>Z</bdo>
12456 <p><bdo>X<bdo>Y</bdo>Z</bdo>
12468 [[Media:Foobar.jpg]]
12470 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
12475 Media link with text
12477 [[Media:Foobar.jpg|A neat file to look at]]
12479 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
12483 # FIXME: this is still bad HTML tag nesting
12485 Media link with nasty text
12486 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
12488 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
12490 <a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Safe Link<div style="display:none">" onmouseover="alert(document.cookie)" onfoo="</div></a>
12495 Media link to nonexistent file (bug 1702)
12497 [[Media:No such.jpg]]
12499 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
12504 Image link to nonexistent file (bug 1850 - good)
12506 [[Image:No such.jpg]]
12508 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
12513 :Image link to nonexistent file (bug 1850 - bad)
12515 [[:Image:No such.jpg]]
12517 <p><a href="/index.php?title=File:No_such.jpg&action=edit&redlink=1" class="new" title="File:No such.jpg (page does not exist)">Image:No such.jpg</a>
12524 Character reference normalization in link text (bug 1938)
12526 [[Main Page|this&that]]
12528 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
12535 Test for unicode normalization
12537 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
12541 (bug 19451) Links should refer to the normalized form.
12549 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12550 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12551 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12552 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12553 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12558 Empty attribute crash test (bug 2067)
12560 <font color="">foo</font>
12562 <p><font color="">foo</font>
12567 Empty attribute crash test single-quotes (bug 2067)
12569 <font color=''>foo</font>
12571 <p><font color="">foo</font>
12576 Attribute test: equals, then nothing
12578 <font color=>foo</font>
12580 <p><font>foo</font>
12585 Attribute test: unquoted value
12587 <font color=x>foo</font>
12589 <p><font color="x">foo</font>
12594 Attribute test: unquoted but illegal value (hash)
12596 <font color=#x>foo</font>
12598 <p><font color="#x">foo</font>
12603 Attribute test: no value
12605 <font color>foo</font>
12607 <p><font color="color">foo</font>
12612 Bug 2095: link with three closing brackets
12616 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
12621 Bug 2095: link with pipe and three closing brackets
12623 [[Main Page|link]]]
12625 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
12630 Bug 2095: link with pipe and three closing brackets, version 2
12632 [[Main Page|[http://example.com/]]]
12634 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
12644 Template:Dangerous attribute
12646 " onmouseover="alert(document.cookie)
12650 Template:Dangerous style attribute
12652 border-size: expression(alert(document.cookie))
12658 <div style="float: right; {{{1}}}">Magic div</div>
12662 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
12664 <div title="{{test}}"></div>
12666 <div title="This is a test template"></div>
12671 Bug 2304: HTML attribute safety (dangerous template; 2309)
12673 <div title="{{dangerous attribute}}"></div>
12675 <div title=""></div>
12680 Bug 2304: HTML attribute safety (dangerous style template; 2309)
12682 <div style="{{dangerous style attribute}}"></div>
12684 <div style="/* insecure input */"></div>
12689 Bug 2304: HTML attribute safety (safe parameter; 2309)
12691 {{div style|width: 200px}}
12693 <div style="float: right; width: 200px">Magic div</div>
12698 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
12700 {{div style|width: expression(alert(document.cookie))}}
12702 <div style="/* insecure input */">Magic div</div>
12707 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
12709 {{div style|"><script>alert(document.cookie)</script>}}
12711 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
12716 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
12718 {{div style|" ><script>alert(document.cookie)</script>}}
12720 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
12725 Bug 2304: HTML attribute safety (link)
12727 <div title="[[Main Page]]"></div>
12729 <div title="[[Main Page]]"></div>
12734 Bug 2304: HTML attribute safety (italics)
12736 <div title="''foobar''"></div>
12738 <div title="''foobar''"></div>
12743 Bug 2304: HTML attribute safety (bold)
12745 <div title="'''foobar'''"></div>
12747 <div title="'''foobar'''"></div>
12753 Bug 2304: HTML attribute safety (ISBN)
12755 <div title="ISBN 1234567890"></div>
12757 <div title="ISBN 1234567890"></div>
12762 Bug 2304: HTML attribute safety (RFC)
12764 <div title="RFC 1234"></div>
12766 <div title="RFC 1234"></div>
12771 Bug 2304: HTML attribute safety (PMID)
12773 <div title="PMID 1234567890"></div>
12775 <div title="PMID 1234567890"></div>
12780 Bug 2304: HTML attribute safety (web link)
12782 <div title="http://example.com/"></div>
12784 <div title="http://example.com/"></div>
12789 Bug 2304: HTML attribute safety (named web link)
12791 <div title="[http://example.com/ link]"></div>
12793 <div title="[http://example.com/ link]"></div>
12798 Bug 3244: HTML attribute safety (extension; safe)
12800 <div style="<nowiki>background:blue</nowiki>"></div>
12802 <div style="background:blue"></div>
12807 Bug 3244: HTML attribute safety (extension; unsafe)
12809 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
12811 <div style="/* insecure input */"></div>
12815 # More MSIE fun discovered by Tom Gilder
12818 MSIE CSS safety test: spurious slash
12820 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
12822 <div style="/* insecure input */">evil</div>
12827 MSIE CSS safety test: hex code
12829 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
12831 <div style="/* insecure input */">evil</div>
12836 MSIE CSS safety test: comment in url
12838 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
12840 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
12845 MSIE CSS safety test: comment in expression
12847 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
12849 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
12854 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
12856 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
12858 <p style="/* invalid control char */">A</p>
12863 MSIE 6 CSS safety test: Fullwidth (bug 55332)
12865 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
12866 <div style="top:EXPRESSION(alert())">B</div>
12868 <p style="/* insecure input */">A</p>
12869 <div style="/* insecure input */">B</div>
12874 MSIE 6 CSS safety test: IPA extensions (bug 55332)
12876 <div style="background-image:uʀʟ(javascript:alert())">A</div>
12877 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
12879 <div style="/* insecure input */">A</div>
12880 <p style="/* insecure input */">B</p>
12885 MSIE 6 CSS safety test: sup/sub script (bug 55332)
12887 <div style="background-image:url⁽javascript:alert())">A</div>
12888 <div style="background-image:url₍javascript:alert())">B</div>
12889 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
12891 <div style="/* insecure input */">A</div>
12892 <div style="/* insecure input */">B</div>
12893 <p style="/* insecure input */">C</p>
12901 title="data:text/html,<img src=1 onerror=alert(1)>"
12902 style="-o-link:attr(title);-o-link-source:current">X</div>
12904 <div title="data:text/html,<img src=1 onerror=alert(1)>" style="/* insecure input */">X</div>
12909 MSIE 6 CSS safety test: Repetition markers (bug 55332)
12911 <p style="font-size: 100px; color: expres〱ion((title='XSSed'),'red')">A</p>
12912 <p style="font-size: 100px; color: expresゝion((title='XSSed'),'red')">B</p>
12913 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">C</p>
12914 <p style="font-size: 100px; color: expresヽion((title='XSSed'),'red')">D</p>
12915 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
12916 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
12917 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
12919 <p style="/* insecure input */">A</p>
12920 <p style="/* insecure input */">B</p>
12921 <p style="/* insecure input */">C</p>
12922 <p style="/* insecure input */">D</p>
12923 <p style="/* insecure input */">E</p>
12924 <p style="/* insecure input */">F</p>
12925 <p style="/* insecure input */">G</p>
12930 Table attribute legitimate extension
12933 !+ style="<nowiki>color:blue</nowiki>"| status
12938 <th style="color:blue"> status
12944 Table attribute safety
12947 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
12952 <th style="/* insecure input */"> status
12958 CSS line continuation 1
12960 <div style="background-image: u\ rl(test.jpg);"></div>
12962 <div style="/* insecure input */"></div>
12967 CSS line continuation 2
12969 <div style="background-image: u\ rl(test.jpg); "></div>
12971 <div style="/* insecure input */"></div>
12982 Expansion of multi-line templates in attribute values (bug 6255)
12984 <div style="background: {{identity|#00FF00}}">-</div>
12986 <div style="background: #00FF00">-</div>
12992 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
12994 <div style="background:
12997 <div style="background: #00FF00">-</div>
13002 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
13004 <div style="background: #00FF00">-</div>
13006 <div style="background: #00FF00">-</div>
13011 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
13014 Parser hook: empty input
13027 Parser hook: empty input using terminated empty elements
13040 Parser hook: empty input using terminated empty elements (space before)
13053 Parser hook: basic input
13067 Parser hook: case insensitive
13081 Parser hook: case insensitive, redux
13094 Parser hook: nested tags
13098 <tag><tag></tag></tag>
13109 Parser hook: basic arguments
13111 <tag width=200 height = "100" depth = '50' square></tag>
13119 'square' => 'square',
13126 Parser hook: argument containing a forward slash (bug 5344)
13128 <tag filename='/tmp/bla'></tag>
13133 'filename' => '/tmp/bla',
13140 Parser hook: empty input using terminated empty elements (bug 2374)
13153 # </tag> should be output literally since there is no matching tag that begins it
13155 Parser hook: basic arguments using terminated empty elements (bug 2374)
13157 <tag width=200 height = "100" depth = '50' square/>
13167 'square' => 'square',
13176 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
13180 Parser hook: static parser hook not inside a comment
13182 <statictag>hello, world</statictag>
13183 <statictag action=flush/>
13191 Parser hook: static parser hook inside a comment
13193 <!-- <statictag>hello, world</statictag> -->
13194 <statictag action=flush/>
13200 # Nested template calls; this case was broken by Parser.php rev 1.506,
13204 Template:One-parameter
13206 (My parameter is: {{{1}}})
13210 Template:Map-one-parameter
13212 {{{{{1}}}|{{{2}}}}}
13216 Nested template calls
13218 {{Map-one-parameter|One-parameter|param}}
13220 <p>(My parameter is: param)
13229 Sanitizer: Closing of open tags
13231 <s></s><table></table>
13233 <s></s><table></table>
13238 Sanitizer: Closing of open but not closed tags
13247 Sanitizer: Closing of closed but not open tags
13256 Sanitizer: Closing of closed but not open table tags
13258 Table not started</td></tr></table>
13260 <p>Table not started</td></tr></table>
13265 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
13267 <span id="æ: v">byte</span>[[#æ: v|backlink]]
13269 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
13274 Sanitizer: Validating the contents of the id attribute (bug 4515)
13280 Something, but definitely not <br id="9" />...
13284 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
13288 <br id="foo" /><br id="foo" />
13290 Something need to be done. foo-2 ?
13294 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
13297 <meta itemprop="hello" content="world">
13298 <meta http-equiv="refresh" content="5">
13299 <meta itemprop="hello" http-equiv="refresh" content="5">
13300 <link itemprop="hello" href="{{SERVER}}">
13301 <link rel="stylesheet" href="{{SERVER}}">
13302 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
13305 <div itemscope="itemscope">
13306 <p> <meta itemprop="hello" content="world" />
13307 <meta http-equiv="refresh" content="5">
13308 <meta itemprop="hello" content="5" />
13310 <link itemprop="hello" href="http://example.org" />
13311 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
13312 <link itemprop="hello" href="http://example.org" />
13318 Language converter: output gets cut off unexpectedly (bug 5757)
13322 this bit is safe: }-
13324 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
13326 then we get cut off here: }-
13328 all additional text is vanished
13330 <p>this bit is safe: }-
13331 </p><p>but if we add a conversion instance: xxx
13332 </p><p>then we get cut off here: }-
13333 </p><p>all additional text is vanished
13338 Self closed html pairs (bug 5487)
13341 <center><font id="bug" />Centered text</center>
13342 <div><font id="bug2" />In div text</div>
13344 <center><font id="bug" />Centered text</center>
13345 <div><font id="bug2" />In div text</div>
13354 Punctuation: nbsp before exclamation
13358 <p>C'est grave !
13363 Punctuation: CSS !important (bug 11874)
13365 <div style="width:50% !important">important</div>
13367 <div style="width:50% !important">important</div>
13372 Punctuation: CSS ! important (bug 11874; with space after)
13374 <div style="width:50% ! important">important</div>
13376 <div style="width:50% ! important">important</div>
13382 HTML bullet list, closed tags (bug 5497)
13397 HTML bullet list, unclosed tags (bug 5497)
13416 HTML ordered list, closed tags (bug 5497)
13431 HTML ordered list, unclosed tags (bug 5497)
13450 HTML nested bullet list, closed tags (bug 5497)
13475 HTML nested bullet list, open tags (bug 5497)
13504 HTML nested ordered list, closed tags (bug 5497)
13529 HTML nested ordered list, open tags (bug 5497)
13558 HTML ordered list item with parameters oddity
13560 <ol><li id="fragment">One</li>
13563 <ol><li id="fragment">One</li>
13569 bug 5918: autonumbering
13571 [http://first/] [http://second] [ftp://ftp]
13575 [mailto:enclosed@mail.tld With target]
13577 [mailto:enclosed@mail.tld]
13579 mailto:inline@mail.tld
13581 <p><a rel="nofollow" class="external autonumber" href="http://first/">[1]</a> <a rel="nofollow" class="external autonumber" href="http://second">[2]</a> <a rel="nofollow" class="external autonumber" href="ftp://ftp">[3]</a>
13582 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
13583 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
13584 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
13585 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
13591 # Security and HTML correctness
13592 # From Nick Jenkins' fuzz testing
13596 Fuzz testing: Parser13
13611 Fuzz testing: Parser14
13616 <h2><span class="mw-headline" id="onmouseover.3D">onmouseover=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: onmouseover=">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13617 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13619 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
13627 Fuzz testing: Parser14-table
13632 <h2><span class="mw-headline" id="a">a</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: a">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13633 <table style="__TOC__">
13639 # Known to produce bogus xml (extra </td>)
13641 Fuzz testing: Parser16
13661 Fuzz testing: Parser21
13664 ! irc://{{ftp://a" onmouseover="alert('hello world');"
13669 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
13679 Fuzz testing: Parser22
13681 http://===r:::https://b
13685 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
13693 # Known to produce bad XML for now
13695 Fuzz testing: Parser24
13702 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
13703 <br style="onmouseover='alert(document.cookie);' " />
13705 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
13710 <u class="|">}}}} >
13711 <br style="onmouseover='alert(document.cookie);'" />
13713 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
13722 # Note: the current result listed for this is not what the original one was,
13723 # but the original bug was JavaScript injection, which is fixed in any case.
13724 # It's not clear that the original result listed was any more correct than the
13725 # current one. Original result:
13728 # <li class="||">
13729 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
13731 Fuzz testing: Parser25 (bug 6055)
13737 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
13739 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
13744 Fuzz testing: URL adjacent extension (with space, clean)
13747 http://example.com <nowiki>junk</nowiki>
13749 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
13754 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
13757 http://example.com<nowiki>junk</nowiki>
13759 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
13764 Fuzz testing: URL adjacent extension (no space, dirty; pre)
13767 http://example.com<pre>junk</pre>
13769 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
13774 Fuzz testing: image with bogus manual thumbnail
13776 [[Image:foobar.jpg|thumbnail= ]]
13778 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
13781 <meta typeof="mw:Placeholder" data-parsoid='{"src":"[[Image:foobar.jpg|thumbnail= ]]","optList":[{"ck":"manualthumb","ak":"thumbnail= "}],"dsr":[0,32,null,null]}'/>
13785 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
13787 <pre dir=" "></pre>
13789 <pre dir=" "></pre>
13794 Parsing optional HTML elements (Bug 6171)
13799 <td> Some tabular data</td>
13800 <td> More tabular data ...
13801 <td> And yet som tabular data</td>
13807 <td> Some tabular data</td>
13808 <td> More tabular data ...
13809 </td><td> And yet som tabular data</td>
13816 Correct handling of <td>, <tr> (Bug 6171)
13821 <td> Some tabular data</td>
13822 <td> More tabular data ...</td>
13823 <td> And yet som tabular data</td>
13829 <td> Some tabular data</td>
13830 <td> More tabular data ...</td>
13831 <td> And yet som tabular data</td>
13839 Parsing crashing regression (fr:JavaScript)
13843 <p></body></x>
13848 Inline wiki vs wiki block nesting
13854 <p><b>Bold paragraph</b>
13855 </p><p>New wiki paragraph
13860 Inline HTML vs wiki block nesting
13868 <p><b>Bold paragraph</b>
13869 </p><p>New wiki paragraph
13873 # Original result was this:
13874 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
13876 # While that might be marginally more intuitive, maybe, the six-apostrophe
13877 # construct is clearly pathological and the result stated here (which is what
13878 # the parser actually does) is about as reasonable as anything.
13880 Mixing markup for italics and bold
13883 '''bold''''''bold''bolditalics'''''
13885 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
13893 Article for special page transclusion test
13897 Special page transclusion
13900 {{Special:Prefixindex/Xyzzyx}}
13902 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
13907 Special page transclusion twice (bug 5021)
13910 {{Special:Prefixindex/Xyzzyx}}
13911 {{Special:Prefixindex/Xyzzyx}}
13913 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
13914 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
13919 Transclusion of default MediaWiki message
13921 {{MediaWiki:Mainpage}}
13928 Transclusion of nonexistent MediaWiki message
13930 {{MediaWiki:Mainpagexxx}}
13932 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
13937 Transclusion of MediaWiki message with underscore
13939 {{MediaWiki:history_short}}
13946 Transclusion of MediaWiki message with space
13948 {{MediaWiki:history short}}
13955 Invalid header with following text
13965 Section extraction test (section 0)
13985 Section extraction test (section 1)
14007 Section extraction test (section 2)
14028 Section extraction test (section 3)
14048 Section extraction test (section 4)
14072 Section extraction test (section 5)
14092 Section extraction test (section 6)
14113 Section extraction test (section 7)
14133 Section extraction test (section 8)
14153 Section extraction test (section 9)
14174 Section extraction test (section 10)
14194 Section extraction test (nonexistent section 11)
14213 Section extraction test with bogus heading (section 1)
14218 ==bogus== not a legal section
14222 ==bogus== not a legal section
14226 Section extraction test with bogus heading (section 2)
14231 ==bogus== not a legal section
14238 Section extraction test with comment after heading (section 1)
14250 Section extraction test with comment after heading (section 2)
14262 Section extraction test with bogus <nowiki> heading (section 1)
14267 ==bogus== <nowiki>not a legal section</nowiki>
14271 ==bogus== <nowiki>not a legal section</nowiki>
14275 Section extraction test with bogus <nowiki> heading (section 2)
14280 ==bogus== <nowiki>not a legal section</nowiki>
14287 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
14288 # instead of respecting commented sections
14290 Section extraction prefixed by comment (section 1)
14301 Section extraction prefixed by comment (section 2)
14312 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
14313 # instead of respecting HTML-style headings
14315 Section extraction, mixed wiki and html (section 1)
14331 Section extraction, mixed wiki and html (section 2)
14347 # Formerly testing for bug 3342
14349 Section extraction, heading surrounded by <noinclude>
14353 <noinclude>==unmarked==</noinclude>
14359 # Test behavior of bug 19910
14361 Sectiion with all-equals
14366 The line above must have a trailing space
14369 But just in case it doesn't...
14373 But just in case it doesn't...
14377 Section replacement test (section 0)
14408 Section replacement test (section 1)
14437 Section replacement test (section 2)
14467 Section replacement test (section 3)
14498 Section replacement test (section 4)
14525 Section replacement test (section 5)
14556 Section replacement test (section 6)
14586 Section replacement test (section 7)
14617 Section replacement test (section 8)
14648 Section replacement test (section 9)
14677 Section replacement test (section 10)
14707 Section replacement test with initial whitespace (bug 13728)
14711 Preformatted initial line
14715 Preformatted initial line
14722 Section extraction, heading followed by pre with 20 spaces (bug 6398)
14734 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
14747 Section extraction, <pre> around bogus header (bug 10309)
14764 Section replacement, <pre> around bogus header (bug 10309)
14766 noxml replace=2,"xxx"
14787 Handling of 
 in URLs
14793 <li><a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a>
14801 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
14803 5 quotes, code coverage +1 line
14810 <p><b><i></i></b></p>
14813 # same html as previous, but wikitext adjusted to match parsoid html2wt
14814 # note that wt2html and html2html will put the <i> before the <b>
14816 5 quotes, code coverage +1 line w/ nowiki (1)
14818 parsoid=wt2wt,html2wt
14820 '''''<nowiki/>'''''
14825 <p><b><i></i></b></p>
14828 # same as previous, just swapping the <i> and <b>
14830 5 quotes, code coverage +1 line w/ nowiki (2)
14832 '''''<nowiki/>'''''
14837 <p><i><b></b></i></p>
14841 Special:Search page linking.
14845 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
14852 title=[[Parser test]]
14857 * {{FULLPAGENAMEE}}
14859 * {{BASEPAGENAMEE}}
14863 * {{ROOTPAGENAMEE}}
14865 * {{TALKPAGENAMEE}}
14866 * {{SUBJECTPAGENAME}}
14867 * {{SUBJECTPAGENAMEE}}
14870 * {{NAMESPACENUMBER}}
14874 * {{SUBJECTSPACEE}}
14875 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
14898 <li> Talk:Parser test
14900 <li> Talk:Parser_test
14920 <li> <a href="/index.php?title=Template:Dynamic&action=edit&redlink=1" class="new" title="Template:Dynamic (page does not exist)">Template:Dynamic</a>
14925 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
14935 image4 |300px| centre
14936 image5.svg| http://///////
14941 <ul class="gallery mw-gallery-traditional">
14942 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14943 <div class="thumb" style="height: 150px;">Image1.png</div>
14944 <div class="gallerytext">
14947 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14948 <div class="thumb" style="height: 150px;">Image2.gif</div>
14949 <div class="gallerytext">
14954 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14955 <div class="thumb" style="height: 150px;">Image3</div>
14956 <div class="gallerytext">
14959 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14960 <div class="thumb" style="height: 150px;">Image4</div>
14961 <div class="gallerytext">
14966 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14967 <div class="thumb" style="height: 150px;">Image5.svg</div>
14968 <div class="gallerytext">
14969 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
14973 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14974 <div class="thumb" style="height: 150px;">* image6</div>
14975 <div class="gallerytext">
14983 Gallery (with options)
14985 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
14986 File:Nonexistant.jpg|caption
14987 File:Nonexistant.jpg
14988 image:foobar.jpg|some '''caption''' [[Main Page]]
14990 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
14993 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
14994 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
14995 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
14996 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
14997 <div class="gallerytext">
15002 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15003 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
15004 <div class="gallerytext">
15007 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15008 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
15009 <div class="gallerytext">
15010 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
15014 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15015 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
15016 <div class="gallerytext">
15019 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15020 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="This is a foo-bar." src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
15021 <div class="gallerytext">
15031 Gallery with wikitext inside caption
15034 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
15035 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
15038 <ul class="gallery mw-gallery-traditional">
15039 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15040 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
15041 <div class="gallerytext">
15042 <p><a href="/wiki/File:Foobar.jpg" class="image" title="desc"><img alt="inneralt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/20px-Foobar.jpg" width="20" height="2" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/30px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/40px-Foobar.jpg 2x" /></a>
15046 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15047 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
15048 <div class="gallerytext">
15049 <p>This is a test template
15058 gallery (with showfilename option)
15060 <gallery showfilename>
15061 File:Nonexistant.jpg|caption
15062 File:Nonexistant.jpg
15063 image:foobar.jpg|some '''caption''' [[Main Page]]
15067 <ul class="gallery mw-gallery-traditional">
15068 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15069 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15070 <div class="gallerytext">
15071 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
15076 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15077 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15078 <div class="gallerytext">
15079 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
15083 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15084 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
15085 <div class="gallerytext">
15086 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
15087 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
15091 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15092 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
15093 <div class="gallerytext">
15094 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
15103 Gallery (with namespace-less filenames)
15106 File:Nonexistant.jpg
15112 <ul class="gallery mw-gallery-traditional">
15113 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15114 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15115 <div class="gallerytext">
15118 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15119 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15120 <div class="gallerytext">
15123 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15124 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
15125 <div class="gallerytext">
15128 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15129 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
15130 <div class="gallerytext">
15138 HTML Hex character encoding (spells the word "JavaScript")
15140 JavaScript
15142 <p>JavaScript
15147 HTML Hex character encoding bogus encoding (bug 26437 regression check)
15151 <p>&#xsee;&#XSEE;
15156 HTML Hex character encoding mixed case
15165 __FORCETOC__ override
15177 ISBN 978-0-1234-56 789
15179 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
15184 ISBN followed by 5 spaces
15195 ISBN ISBN 1234567890
15197 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
15206 <p><a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-X</a>
15211 ISBN with empty prefix (parsoid test)
15215 <p><a href="Special:BookSources/1234567890" rel="mw:ExtLink">ISBN 1234567890</a></p>
15219 Bug 22905: <abbr> followed by ISBN followed by </a>
15221 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
15223 <p><abbr>(fr)</abbr> <a href="/wiki/Special:BookSources/2753300917" class="internal mw-magiclink-isbn">ISBN 2753300917</a> <a rel="nofollow" class="external text" href="http://www.example.com">example.com</a>
15232 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
15237 Double RFC with a wiki link
15241 <p>RFC <a href="/index.php?title=RFC_1234&action=edit&redlink=1" class="new" title="RFC 1234 (page does not exist)">RFC 1234</a>
15250 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
15255 Centre-aligned image
15257 [[Image:foobar.jpg|centre]]
15259 <div class="center"><div class="floatnone"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div></div>
15266 [[Image:foobar.jpg|none]]
15268 <div class="floatnone"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
15273 Width + Height sized image (using px) (height is ignored)
15275 [[Image:foobar.jpg|640x480px]]
15277 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15282 Width-sized image (using px, no following whitespace)
15284 [[Image:foobar.jpg|640px]]
15286 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15291 Width-sized image (using px, with following whitespace - test regression from r39467)
15293 [[Image:foobar.jpg|640px ]]
15295 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15300 Width-sized image (using px, with preceding whitespace - test regression from r39467)
15302 [[Image:foobar.jpg| 640px]]
15304 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15309 Another italics / bold test
15317 # Note the results may be incorrect, as parserTest output included this:
15318 # XML error: Mismatched tag at byte 6120:
15319 # ...<dd> </dt></dl> </dd...
15350 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
15352 Images with the "|" character in the comment
15354 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
15356 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&param2=%7Cx">external</a> URL</div></div></div>
15361 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
15363 <html><script>alert(1);</script></html>
15365 <p><html><script>alert(1);</script></html>
15370 HTML with raw HTML ($wgRawHtml==true)
15374 <html><script>alert(1);</script></html>
15376 <p><script>alert(1);</script>
15381 Parents of subpages, one level up
15383 subpage title=[[Subpage test/L1/L2/L3]]
15387 <p><a href="/index.php?title=Subpage_test/L1/L2&action=edit&redlink=1" class="new" title="Subpage test/L1/L2 (page does not exist)">L2</a>
15393 Parents of subpages, one level up, not named
15395 subpage title=[[Subpage test/L1/L2/L3]]
15399 <p><a href="/index.php?title=Subpage_test/L1/L2&action=edit&redlink=1" class="new" title="Subpage test/L1/L2 (page does not exist)">Subpage test/L1/L2</a>
15406 Parents of subpages, two levels up
15408 subpage title=[[Subpage test/L1/L2/L3]]
15414 <p><a href="/index.php?title=Subpage_test/L1&action=edit&redlink=1" class="new" title="Subpage test/L1 (page does not exist)">L1</a>2
15415 </p><p><a href="/index.php?title=Subpage_test/L1&action=edit&redlink=1" class="new" title="Subpage test/L1 (page does not exist)">L1l</a>
15420 Parents of subpages, two levels up, without trailing slash or name.
15422 subpage title=[[Subpage test/L1/L2/L3]]
15431 Parents of subpages, two levels up, with lots of extra trailing slashes.
15433 subpage title=[[Subpage test/L1/L2/L3]]
15437 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
15442 Subpage test/L1/L2/L3Sibling
15448 Transclusion of a sibling page (one level up)
15450 subpage title=[[Subpage test/L1/L2/L3]]
15459 Transclusion of a child page
15461 subpage title=[[Subpage test/L1/L2]]
15470 Non-transclusion because of too many up levels
15472 subpage title=[[Subpage test/L1/L2/L3]]
15474 {{../../../../More than parent}}
15476 <p>{{../../../../More than parent}}
15481 Definition list code coverage
15488 <dt> title  </dt>
15491 <dt> title </dt>
15502 Don't fall for the self-closing div
15504 <div>hello world</div/>
15506 <div>hello world</div>
15515 <p>[[:Template:Msg]]
15524 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
15528 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
15530 Always escape literal '>' in output, not just after '<'
15544 <p>This is a test template
15545 This is a test template
15557 Inclusion of !userCanEdit() content
15561 <h2><span class="mw-headline" id="header">header</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=MediaWiki:Fake&action=edit&section=T-1" title="MediaWiki:Fake">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15567 Out-of-order TOC heading levels
15576 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15578 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
15580 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
15581 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
15584 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
15586 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
15587 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
15593 <h2><span class="mw-headline" id="2">2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15594 <h6><span class="mw-headline" id="6">6</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: 6">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
15595 <h3><span class="mw-headline" id="3">3</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: 3">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
15596 <h1><span class="mw-headline" id="1">1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: 1">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
15597 <h5><span class="mw-headline" id="5">5</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: 5">edit</a><span class="mw-editsection-bracket">]</span></span></h5>
15598 <h2><span class="mw-headline" id="2_2">2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15604 ISBN with a dummy number
15614 ISBN with space-delimited number
15618 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
15624 ISBN with multiple spaces, no number
15643 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
15644 </p><p>ISBN 12345678901
15650 ISBN with trailing year (bug 8110)
15652 ISBN 1-234-56789-0 - 2006
15654 ISBN 1 234 56789 0 - 2006
15656 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
15657 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
15665 {{anchorencode:foo bar©#%n}}
15667 <p>foo_bar.C2.A9.23.25n
15672 anchorencode trims spaces
15674 {{anchorencode: __pretty__please__}}
15681 anchorencode deals with links
15683 {{anchorencode: [[hello|world]] [[hi]]}}
15690 anchorencode deals with templates
15692 {{anchorencode: {{Foo}} }}
15699 anchorencode encodes like the TOC generator: (bug 18431)
15701 === _ +:.3A%3A&&]] ===
15702 {{anchorencode: _ +:.3A%3A&&]] }}
15705 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
15706 <p>.2B:.3A.253A.26.26.5D.5D
15711 Bug 6200: blockquotes and paragraph formatting
15732 Bug 8293: Use of center tag ruins paragraph formatting
15753 Parsing of overlapping (improperly nested) inline html tags
15755 <span><s>x</span></s>
15757 <p><span><s>x</span></s></span>
15760 <p><span><s>x</s></span>
15765 ### Language variants related tests
15768 Self-link in language variants
15770 title=[[Dunav]] language=sr
15772 Both [[Dunav]] and [[Дунав]] are names for this river.
15774 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
15785 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
15787 title=[[Duna]] language=sr
15789 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
15791 <p><a href="/wiki/%D0%94%D1%83%D0%BD%D0%B0" title="Дуна">Дуна</a> is not a self-link while <strong class="selflink">Duna</strong> and <strong class="selflink">Dуна</strong> are still self-links.
15796 Link to a section of a variant of this title shouldn't be parsed as self-link
15798 title=[[Duna]] language=sr
15800 [[Dуна]] is a self-link while [[Dunа#Foo]] and [[Dуна#Foo]] are not self-links.
15802 <p><strong class="selflink">Dуна</strong> is a self-link while <a href="/wiki/%D0%94%D1%83%D0%BD%D0%B0" title="Дуна">Dunа#Foo</a> and <a href="/wiki/%D0%94%D1%83%D0%BD%D0%B0" title="Дуна">Dуна#Foo</a> are not self-links.
15807 Link to pages in language variants
15811 Main Page can be written as [[Маин Паге]]
15813 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
15819 Multiple links to pages in language variants
15823 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
15825 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a> can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a> same as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>.
15831 Simple template in language variants
15837 <p>This is a test template
15843 Template with explicit namespace in language variants
15849 <p>This is a test template
15855 Basic test for template parameter in language variants
15859 {{парамтест|param=foo}}
15861 <p>This is a test template with parameter foo
15867 Simple category in language variants
15871 [[Category:МедиаWики Усер'с Гуиде]]
15873 <a href="/wiki/%D0%9A%D0%B0%D1%82%D0%B5%D0%B3%D0%BE%D1%80%D0%B8%D1%98%D0%B0:MediaWiki_User%27s_Guide" title="Категорија:MediaWiki User's Guide">MediaWiki User's Guide</a>
15890 Don't convert blue categorylinks to another variant (bug 33210)
15894 [[A]][[Category:分类]]
15896 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
15901 Stripping -{}- tags (language variants)
15905 Latin proverb: -{Ne nuntium necare}-
15907 <p>Latin proverb: Ne nuntium necare
15913 Prevent conversion with -{}- tags (language variants)
15915 language=sr variant=sr-ec
15917 Latinski: -{Ne nuntium necare}-
15919 <p>Латински: Ne nuntium necare
15925 Prevent conversion of text with -{}- tags (language variants)
15927 language=sr variant=sr-ec
15929 Latinski: -{Ne nuntium necare}-
15931 <p>Латински: Ne nuntium necare
15937 Prevent conversion of links with -{}- tags (language variants)
15939 language=sr variant=sr-ec
15943 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
15949 -{}- tags within headlines (within html for parserConvert())
15951 language=sr variant=sr-ec
15955 <h2><span class="mw-headline" id="-.7BNaslov.7D-">Naslov</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Уредите одељак „Naslov“">уреди</a><span class="mw-editsection-bracket">]</span></span></h2>
15961 Explicit definition of language variant alternatives
15963 language=zh variant=zh-tw
15965 -{zh:China;zh-tw:Taiwan}-, not China
15967 <p>Taiwan, not China
15973 Conversion around HTML tags
15975 language=sr variant=sr-ec
15977 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
15978 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
15981 <span title="ЛаCтин">ски</span>
15987 Explicit session-wise language variant mapping (A flag and - flag)
15989 language=zh variant=zh-tw
15991 Taiwan is not China.
15992 But -{A|zh:China;zh-tw:Taiwan}- is China,
15993 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
15994 and -{China}- is China.
15996 <p>Taiwan is not China.
15997 But Taiwan is Taiwan,
15998 (This should be stripped!)
15999 and China is China.
16004 Explicit session-wise language variant mapping (H flag for hide)
16006 language=zh variant=zh-tw
16008 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
16011 <p>(This should be stripped!)
16017 Adding explicit conversion rule for title (T flag)
16019 language=zh variant=zh-tw showtitle
16021 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
16024 <p>Should be stripped!
16029 Testing that changing the language variant here in the tests actually works
16031 language=zh variant=zh showtitle
16033 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
16036 <p>Should be stripped!
16041 Recursive conversion of alt and title attrs shouldn't clear converter state
16043 language=zh variant=zh-cn showtitle
16045 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
16046 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
16050 Should be stripped<span title="Exclamation">!</span>
16055 Bug 24072: more test on conversion rule for title
16057 language=zh variant=zh-tw showtitle
16059 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
16060 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
16063 <p>This should be stripped!
16064 This won't take interferes with the title rule.
16069 Partly disable title conversion if variant == main language code
16071 language=zh variant=zh title=[[ZH]] showtitle
16073 -{T|zh-cn:CN;zh-tw:TW}-
16081 Partly disable title conversion if variant == main language code, more
16083 language=zh variant=zh title=[[ZH]] showtitle
16093 Raw output of variant escape tags (R flag)
16095 language=zh variant=zh-tw
16097 Raw: -{R|zh:China;zh-tw:Taiwan}-
16099 <p>Raw: zh:China;zh-tw:Taiwan
16104 Nested using of manual convert syntax
16106 language=zh variant=zh-hk
16108 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
16110 <p>Nested: Hello Hong Kong!
16115 Proper conversion of text in external links
16117 language=sr variant=sr-ec
16119 http://www.google.com
16120 gopher://www.google.com
16121 [http://www.google.com http://www.google.com]
16122 [gopher://www.google.com gopher://www.google.com]
16123 [https://www.google.com irc://www.google.com]
16124 [ftp://www.google.com www.google.com/ftp://dir]
16125 [//www.google.com www.google.com]
16127 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
16128 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
16129 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
16130 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
16131 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
16132 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
16133 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
16138 Do not convert roman numbers to language variants
16140 language=sr variant=sr-ec
16144 <p>Фридрих IV је цар.
16149 Unclosed language converter markup "-{"
16160 Don't convert raw rule "-{R|=>}-" to "=>"
16171 Don't break link parsing if language converter markup is in the caption.
16173 language=sr variant=sr-ec
16175 [[Main Page|-{R|main page}-]]
16177 <p><a href="/wiki/Main_Page" title="Маин Паге">main page</a>
16181 # This test is currently broken in the PHP parser (bug 52661)
16183 Don't break image parsing if language converter markup is in the caption.
16188 [[File:Foobar.jpg|-{R|caption}-]]
16190 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
16194 # This test is currently broken in the PHP parser (bug 52661)
16196 Don't break list handling if language converter markup is in the item.
16198 language=zh variant=zh-cn
16201 ;-{zh-cn:AAA;zh-tw:BBB}-
16208 # This test is currently broken in the PHP parser (bug 52661)
16210 Don't break table handling if language converter markup is in the cell.
16212 language=sr variant=sr-ec
16229 Bug 529: Uncovered bullet
16242 # Plain MediaWiki does not remove empty lists, but tidy actually does.
16243 # Templates in Wikipedia rely on this behavior, as tidy has always been
16244 # enabled there. These tests are normally run *without* tidy, so specify the
16245 # full output here.
16246 # To test realistic parsing behavior, apply a tidy-like transformation to both
16247 # the expected output and your parser's output.
16249 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
16251 ******* Foo {{bullet}}
16281 Bug 529: Uncovered table already at line-start
16304 Bug 529: Uncovered bullet in parser function result
16306 * Foo {{lc:{{bullet}} }}
16318 Bug 5678: Double-parsed template argument
16320 {{lc:{{{1}}}|hello}}
16327 Bug 5678: Double-parsed template invocation
16329 {{lc:{{paramtest {{!}} param = hello }} }}
16331 <p>{{paramtest | param = hello }}
16336 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
16339 title=[[Main Page]]
16341 {{PRVNÍVELKÉ:ěščř}}
16342 {{prvnívelké:ěščř}}
16362 Morwen/13: Unclosed link followed by heading
16369 <h2><span class="mw-headline" id="heading">heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
16374 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
16381 <h1><span class="mw-headline" id="heading">heading</span></h1>
16386 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
16393 <h2><span class="mw-headline" id="heading">heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
16408 Paragraphs inside divs (no extra line breaks)
16420 Paragraphs inside divs (extra line break on open)
16435 Paragraphs inside divs (extra line break on close)
16450 Paragraphs inside divs (extra line break on open and close)
16467 Nesting tags, paragraphs on lines which begin with <div>
16471 <div></div><strong>A
16480 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
16482 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
16484 <blockquote>Line one
16486 Line two</blockquote>
16488 <blockquote>Line one
16489 Line two</blockquote>
16494 Bug 6200: paragraphs inside blockquotes (extra line break on open)
16499 Line two</blockquote>
16504 Line two</blockquote>
16509 Bug 6200: paragraphs inside blockquotes (extra line break on close)
16511 <blockquote>Line one
16516 <blockquote>Line one
16524 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
16541 Paragraphs inside blockquotes/divs (no extra line breaks)
16543 <blockquote><div>Line one
16545 Line two</div></blockquote>
16547 <blockquote><div>Line one
16548 Line two</div></blockquote>
16553 Paragraphs inside blockquotes/divs (extra line break on open)
16558 Line two</div></blockquote>
16563 Line two</div></blockquote>
16568 Paragraphs inside blockquotes/divs (extra line break on close)
16570 <blockquote><div>Line one
16573 </div></blockquote>
16575 <blockquote><div>Line one
16578 </div></blockquote>
16583 Paragraphs inside blockquotes/divs (extra line break on open and close)
16589 </div></blockquote>
16595 </div></blockquote>
16600 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
16602 wgLinkHolderBatchSize=0
16608 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
16609 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
16610 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
16615 Free external link invading image caption
16617 [[Image:Foobar.jpg|thumb|http://x|hello]]
16619 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>hello</div></div></div>
16624 Bug 15196: localised external link numbers
16628 [http://en.wikipedia.org/]
16630 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
16635 Multibyte character in padleft
16637 {{padleft:-Hello|7|Æ}}
16644 Multibyte character in padright
16646 {{padright:Hello-|7|Æ}}
16653 formatdate parser function
16655 {{#formatdate:2009-03-24}}
16657 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
16662 formatdate parser function, with default format
16664 {{#formatdate:2009-03-24|mdy}}
16666 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
16671 Spacing of numbers in formatted dates
16673 {{#formatdate:January 15}}
16675 <p><span class="mw-formatted-date" title="01-15">January 15</span>
16680 formatdate parser function, with default format and on a page of which the content language is always English and different from the wiki content language
16682 language=nl title=[[MediaWiki:Common.css]]
16684 {{#formatdate:2009-03-24|dmy}}
16686 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
16699 Edit comment with link
16703 I like the [[Main Page]] a lot
16705 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
16709 Edit comment with link and link text
16713 I like the [[Main Page|best pages]] a lot
16715 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
16719 Edit comment with link and link text with suffix
16723 I like the [[Main Page|best page]]s a lot
16725 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
16729 Edit comment with section link (non-local, eg in history list)
16731 comment title=[[Main Page]]
16733 /* External links */ removed bogus entries
16735 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
16739 Edit comment with section link and text before it (non-local, eg in history list)
16741 comment title=[[Main Page]]
16743 pre-comment text /* External links */ removed bogus entries
16745 pre-comment text <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
16749 Edit comment with section link (local, eg in diff view)
16751 comment local title=[[Main Page]]
16753 /* External links */ removed bogus entries
16755 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
16759 Edit comment with subpage link (bug 14080)
16763 title=[[Subpage test]]
16765 Poked at a [[/subpage]] here...
16767 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
16771 Edit comment with subpage link and link text (bug 14080)
16775 title=[[Subpage test]]
16777 Poked at a [[/subpage|neat little page]] here...
16779 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
16783 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
16786 title=[[Subpage test]]
16788 Poked at a [[/subpage]] here...
16790 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
16794 Edit comment with bare anchor link (local, as on diff)
16798 title=[[Main Page]]
16802 <a href="#section">#section</a>
16806 Edit comment with bare anchor link (non-local, as on history)
16809 title=[[Main Page]]
16813 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
16817 Anchor starting with underscore
16821 <p><a href="#_ref">One</a>
16826 Id starting with underscore
16828 <div id="_ref"></div>
16830 <div id="_ref"></div>
16835 Space normalisation on autocomment (bug 22784)
16838 title=[[Main Page]]
16840 /* __hello__world__ */
16842 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
16846 percent-encoding and + signs in comments (Bug 26410)
16850 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
16852 <a href="/index.php?title=ABC3D%25_%2B%2B&action=edit&redlink=1" class="new" title="ABC3D% ++ (page does not exist)">ABC3D% ++</a> <a href="/index.php?title=ABC3D%25_%2B%2B&action=edit&redlink=1" class="new" title="ABC3D% ++ (page does not exist)">+%20</a>
16856 Bad images - basic functionality
16865 Bad images - bug 16039: text after bad image disappears
16879 Verify that displaytitle works (bug #22501) no displaytitle
16883 wgAllowDisplayTitle=true
16884 wgRestrictDisplayTitle=false
16886 this is not the the title
16889 <p>this is not the the title
16894 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
16899 wgAllowDisplayTitle=true
16900 wgRestrictDisplayTitle=false
16902 this is not the the title
16903 {{DISPLAYTITLE:whatever}}
16906 <p>this is not the the title
16911 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
16916 wgAllowDisplayTitle=true
16917 wgRestrictDisplayTitle=true
16919 this is not the the title
16920 {{DISPLAYTITLE:whatever}}
16923 <p>this is not the the title
16928 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
16933 wgAllowDisplayTitle=true
16934 wgRestrictDisplayTitle=true
16936 this is not the the title
16937 {{DISPLAYTITLE:screen}}
16940 <p>this is not the the title
16945 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
16950 wgAllowDisplayTitle=false
16952 this is not the the title
16953 {{DISPLAYTITLE:screen}}
16956 <p>this is not the the title
16957 <a href="/index.php?title=Template:DISPLAYTITLE:screen&action=edit&redlink=1" class="new" title="Template:DISPLAYTITLE:screen (page does not exist)">Template:DISPLAYTITLE:screen</a>
16962 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
16967 wgAllowDisplayTitle=false
16969 this is not the the title
16972 <p>this is not the the title
16977 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
16982 wgAllowDisplayTitle=true
16983 wgRestrictDisplayTitle=true
16985 this is not the the title
16986 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
16988 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
16989 <p>this is not the the title
16994 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
16999 wgAllowDisplayTitle=true
17000 wgRestrictDisplayTitle=true
17002 this is not the the title
17003 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
17005 <span style="color: red;">s</span>creen
17006 <p>this is not the the title
17011 preload: check <noinclude> and <includeonly>
17015 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
17021 preload: check <onlyinclude>
17025 Goodbye <onlyinclude>Hello world</onlyinclude>
17031 preload: can pass tags through if we want to
17035 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
17037 <includeonly>Hello world</includeonly>
17041 preload: check that it doesn't try to do tricks
17045 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
17047 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
17051 Play a bit with r67090 and bug 3158
17055 <div style="width:50% !important"> </div>
17056 <div style="width:50% !important"> </div>
17057 <div style="width:50% !important"> </div>
17058 <div style="border : solid;"> </div>
17060 <div style="width:50% !important"> </div>
17061 <div style="width:50% !important"> </div>
17062 <div style="width:50% !important"> </div>
17063 <div style="border : solid;"> </div>
17068 HTML5 data attributes
17070 <span data-foo="bar">Baz</span>
17071 <p data-abc-def_hij="">Quuz</p>
17073 <p><span data-foo="bar">Baz</span>
17075 <p data-abc-def_hij="">Quuz</p>
17080 percent-encoding and + signs in internal links (Bug 26410)
17082 [[User:+%]] [[Page+title%]]
17083 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
17084 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
17085 [[%33%45]] [[%33%45+]]
17087 <p><a href="/index.php?title=User:%2B%25&action=edit&redlink=1" class="new" title="User:+% (page does not exist)">User:+%</a> <a href="/index.php?title=Page%2Btitle%25&action=edit&redlink=1" class="new" title="Page+title% (page does not exist)">Page+title%</a>
17088 <a href="/index.php?title=%25%2B&action=edit&redlink=1" class="new" title="%+ (page does not exist)">%+</a> <a href="/index.php?title=%25%2B&action=edit&redlink=1" class="new" title="%+ (page does not exist)">%20</a> <a href="/index.php?title=%25%2B&action=edit&redlink=1" class="new" title="%+ (page does not exist)">%+ </a> <a href="/index.php?title=%25%2Br&action=edit&redlink=1" class="new" title="%+r (page does not exist)">%+r</a>
17089 <a href="/index.php?title=%25&action=edit&redlink=1" class="new" title="% (page does not exist)">%</a> <a href="/index.php?title=%2B&action=edit&redlink=1" class="new" title="+ (page does not exist)">+</a> <a href="/index.php?title=Special:Upload&wpDestFile=%25%2Babc9" class="new" title="File:%+abc9">bar</a>
17090 <a href="/index.php?title=3E&action=edit&redlink=1" class="new" title="3E (page does not exist)">3E</a> <a href="/index.php?title=3E%2B&action=edit&redlink=1" class="new" title="3E+ (page does not exist)">3E+</a>
17095 Special characters in embedded file links (bug 27679)
17097 [[File:Contains & ampersand.jpg]]
17098 [[File:Does not exist.jpg|Title with & ampersand]]
17100 <p><a href="/index.php?title=Special:Upload&wpDestFile=Contains_%26_ampersand.jpg" class="new" title="File:Contains & ampersand.jpg">File:Contains & ampersand.jpg</a>
17101 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
17107 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
17109 Text's been normalized?
17111 <p>Text's been normalized?
17116 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
17118 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
17120 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
17125 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
17127 [http://www.example.org/ ideograms]
17129 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
17134 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
17136 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
17138 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
17162 Bug 31098 Template which includes system messages which includes the template
17166 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
17167 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
17172 Bug31490 Turkish: ucfirst 'blah'
17183 Bug31490 Turkish: ucfirst 'ix'
17194 Bug31490 Turkish: lcfirst 'BLAH'
17205 Bug31490 Turkish: ucfırst (with a dotless i)
17211 <p><a href="/index.php?title=%C5%9Eablon:Ucf%C4%B1rst:blah&action=edit&redlink=1" class="new" title="Şablon:Ucfırst:blah (sayfa mevcut değil)">Şablon:Ucfırst:blah</a>
17216 Bug31490 ucfırst (with a dotless i) with English language
17222 <p><a href="/index.php?title=Template:Ucf%C4%B1rst:blah&action=edit&redlink=1" class="new" title="Template:Ucfırst:blah (page does not exist)">Template:Ucfırst:blah</a>
17227 Bug 26375: TOC with italics
17229 title=[[Main Page]]
17232 == ''Lost'' episodes ==
17234 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17236 <li class="toclevel-1 tocsection-1"><a href="#Lost_episodes"><span class="tocnumber">1</span> <span class="toctext"><i>Lost</i> episodes</span></a></li>
17240 <h2><span class="mw-headline" id="Lost_episodes"><i>Lost</i> episodes</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Lost episodes">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17245 Bug 26375: TOC with bold
17247 title=[[Main Page]]
17250 == '''should be bold''' then normal text ==
17252 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17254 <li class="toclevel-1 tocsection-1"><a href="#should_be_bold_then_normal_text"><span class="tocnumber">1</span> <span class="toctext"><b>should be bold</b> then normal text</span></a></li>
17258 <h2><span class="mw-headline" id="should_be_bold_then_normal_text"><b>should be bold</b> then normal text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: should be bold then normal text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17263 Bug 33845: Headings become cursive in TOC when they contain an image
17265 title=[[Main Page]]
17268 == Image [[Image:foobar.jpg]] ==
17270 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17272 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
17276 <h2><span class="mw-headline" id="Image">Image <a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Image">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17281 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
17283 title=[[Main Page]]
17286 == <blockquote>Quote</blockquote> ==
17288 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17290 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
17294 <h2><span class="mw-headline" id="Quote"><blockquote>Quote</blockquote></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Quote">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17299 Unclosed tags in TOC
17301 title=[[Main Page]]
17305 <small>Hanc marginis exiguitas non caperet.</small>
17308 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17310 <li class="toclevel-1 tocsection-1"><a href="#Proof:_2_.3C_3"><span class="tocnumber">1</span> <span class="toctext">Proof: 2 < 3</span></a></li>
17314 <h2><span class="mw-headline" id="Proof:_2_.3C_3">Proof: 2 < 3</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Proof: 2 < 3">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17315 <p><small>Hanc marginis exiguitas non caperet.</small>
17321 Multiple tags in TOC
17324 == <i>Foo</i> <b>Bar</b> ==
17326 == <i>Foo</i> <blockquote>Bar</blockquote> ==
17328 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17330 <li class="toclevel-1 tocsection-1"><a href="#Foo_Bar"><span class="tocnumber">1</span> <span class="toctext"><i>Foo</i> <b>Bar</b></span></a></li>
17331 <li class="toclevel-1 tocsection-2"><a href="#Foo_Bar_2"><span class="tocnumber">2</span> <span class="toctext"><i>Foo</i> Bar</span></a></li>
17335 <h2><span class="mw-headline" id="Foo_Bar"><i>Foo</i> <b>Bar</b></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17336 <h2><span class="mw-headline" id="Foo_Bar_2"><i>Foo</i> <blockquote>Bar</blockquote></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17341 Tags with parameters in TOC
17344 == <sup class="in-h2">Hello</sup> ==
17346 == <sup class="a > b">Evilbye</sup> ==
17348 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17350 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
17351 <li class="toclevel-1 tocsection-2"><a href="#b.22.3EEvilbye"><span class="tocnumber">2</span> <span class="toctext"><sup> b">Evilbye</sup></span></a></li>
17355 <h2><span class="mw-headline" id="Hello"><sup class="in-h2">Hello</sup></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Hello">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17356 <h2><span class="mw-headline" id="b.22.3EEvilbye"><sup> b">Evilbye</sup></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: b">Evilbye">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17361 span tags with directionality in TOC
17364 == <span dir="ltr">C++</span> ==
17366 == <span dir="rtl">זבנג!</span> ==
17368 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
17370 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
17372 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
17374 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17376 <li class="toclevel-1 tocsection-1"><a href="#C.2B.2B"><span class="tocnumber">1</span> <span class="toctext"><span dir="ltr">C++</span></span></a></li>
17377 <li class="toclevel-1 tocsection-2"><a href="#.D7.96.D7.91.D7.A0.D7.92.21"><span class="tocnumber">2</span> <span class="toctext"><span dir="rtl">זבנג!</span></span></a></li>
17378 <li class="toclevel-1 tocsection-3"><a href="#The_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span class="tocnumber">3</span> <span class="toctext"><span>The attributes on these span tags must be deleted from the TOC</span></span></a></li>
17379 <li class="toclevel-1 tocsection-4"><a href="#All_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span class="tocnumber">4</span> <span class="toctext"><span>All attributes on these span tags must be deleted from the TOC</span></span></a></li>
17380 <li class="toclevel-1 tocsection-5"><a href="#Attributes_after_dir_on_these_span_tags_must_be_deleted_from_the_TOC"><span class="tocnumber">5</span> <span class="toctext"><span dir="ltr">Attributes after dir on these span tags must be deleted from the TOC</span></span></a></li>
17384 <h2><span class="mw-headline" id="C.2B.2B"><span dir="ltr">C++</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: C++">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17385 <h2><span class="mw-headline" id=".D7.96.D7.91.D7.A0.D7.92.21"><span dir="rtl">זבנג!</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: זבנג!">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17386 <h2><span class="mw-headline" id="The_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: The attributes on these span tags must be deleted from the TOC">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17387 <h2><span class="mw-headline" id="All_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: All attributes on these span tags must be deleted from the TOC">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17388 <h2><span class="mw-headline" id="Attributes_after_dir_on_these_span_tags_must_be_deleted_from_the_TOC"><span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Attributes after dir on these span tags must be deleted from the TOC">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17395 == {{int:headline_sample}} ==
17399 Bug 32057: Title needed when expanding <h> nodes.
17401 title=[[Main Page]]
17405 <h2><span class="mw-headline" id="Headline_text">Headline text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Headline text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17410 Strip marker in urlencode
17412 {{urlencode:x<nowiki/>y}}
17413 {{urlencode:x<nowiki/>y|wiki}}
17414 {{urlencode:x<nowiki/>y|path}}
17441 Strip marker in formatNum
17443 {{formatnum:1<nowiki/>2}}
17444 {{formatnum:1<nowiki/>2|R}}
17452 Check noCommafy in formatNum
17456 {{formatnum:123456.78}}
17457 {{formatnum:123456.78|NOSEP}}
17465 Wrong option for formatNum (bug 56199)
17467 {{formatnum:1,234.56|Random}}
17468 {{formatnum:1,234.56|EVERYTHING}}
17469 {{formatnum:1234.56|any argument that has the string 'NOSEP'}}
17478 Strip marker in grammar
17482 {{grammar:elative|foo<nowiki/>bar}}
17489 Strip marker in padleft
17491 {{padleft:|2|x<nowiki/>y}}
17498 Strip marker in padright
17500 {{padright:|2|x<nowiki/>y}}
17507 Strip marker in anchorencode
17509 {{anchorencode:x<nowiki/>y}}
17516 nowiki inside link inside heading (bug 18295)
17518 ==[[foo|x<nowiki>y</nowiki>z]]==
17520 <h2><span class="mw-headline" id="xyz"><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">xyz</a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: xyz">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17525 new support for bdi element (bug 31817)
17527 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
17529 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
17534 Ignore pipe between table row attributes
17538 |- id=foo | style='color: red'
17546 <tr id="foo" style="color: red">
17553 Gallery override link with WikiLink (bug 34852)
17556 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
17559 <ul class="gallery mw-gallery-traditional">
17560 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17561 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/InterWikiLink"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17562 <div class="gallerytext">
17572 Gallery override link with absolute external link (bug 34852)
17575 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
17578 <ul class="gallery mw-gallery-traditional">
17579 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17580 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="http://www.example.org"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17581 <div class="gallerytext">
17591 Gallery override link with malicious javascript (bug 34852)
17594 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
17597 <ul class="gallery mw-gallery-traditional">
17598 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17599 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/%22_onclick%3D%22alert(%27malicious_javascript_code!%27);"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17600 <div class="gallerytext">
17610 Gallery with invalid title as link (bug 43964)
17613 File:foobar.jpg|link=<
17616 <ul class="gallery mw-gallery-traditional">
17617 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17618 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17619 <div class="gallerytext">
17627 Language parser function
17636 Padleft and padright as substr
17638 {{padleft:|3|abcde}}
17639 {{padright:|3|abcde}}
17647 Special parser function
17649 {{#special:RandomPage}}
17650 {{#special:BaDtItLe}}
17651 {{#special:Foobar}}
17660 Bug 34939 - Case insensitive link parsing ([HttP://])
17662 [HttP://MediaWiki.Org/]
17664 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
17669 Bug 34939 - Case insensitive link parsing ([HttP:// title])
17671 [HttP://MediaWiki.Org/ MediaWiki]
17673 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
17678 Bug 34939 - Case insensitive link parsing (HttP://)
17680 HttP://MediaWiki.Org/
17682 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
17701 <h2><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17702 <h2><span class="mw-headline" id="Section_2">Section 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17703 <h2><span class="mw-headline" id="Section_3">Section 3</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Section 3">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17704 <h2><span class="mw-headline" id="Section_4">Section 4</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Section 4">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17705 <h2><span class="mw-headline" id="Section_5">Section 5</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Section 5">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17711 ### Parsoids-specific tests
17712 ### Parsoid-PHP parser incompatibilities
17715 1. SOL-sensitive wikitext tokens as template-args
17717 parsoid=wt2html,wt2wt
17723 <span about="#mwt1" typeof="mw:Transclusion">
17724 </span><ul about="#mwt1"><li>a</li>
17726 <span about="#mwt2" typeof="mw:Transclusion">
17727 </span><ol about="#mwt2"><li>a</li>
17729 <span about="#mwt3" typeof="mw:Transclusion">
17730 </span><dl about="#mwt3"><dd>a</dd>
17734 #### ----------------------------------------------------------------
17735 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
17736 #### tags. Parsoid's output for these tags differs from that of the
17738 #### ----------------------------------------------------------------
17741 Ref: 1. ref-location should be replaced with an index span
17746 B <ref name="x">foo</ref>
17749 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
17750 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-2">[2]</a></span>
17751 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"y"}}' id="cite_ref-y-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-y-3">[3]</a></span></p>
17755 Ref: 2. ref-tags with identical names should all get the same index
17759 A <ref name="x">foo</ref>
17762 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
17763 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
17767 Ref: 3. spaces in ref-names should be ignored
17771 A <ref name="x">foo</ref>
17772 B <ref name=" x " />
17775 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
17776 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
17777 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-2" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
17781 Ref: 4. 'constructor' should be accepted as a valid ref-name
17782 (NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
17786 A <ref name="constructor">foo</ref>
17788 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"constructor"}}' id="cite_ref-constructor-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-constructor-1">[1]</a></span></p>
17792 Ref: 5. body should accept generic wikitext
17797 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
17802 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"This is a <b data-parsoid='{\"dsr\":[19,40,3,3]}'><a rel=\"mw:WikiLink\" href=\"./Bolded_link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Bolded_link\"},\"sa\":{\"href\":\"bolded link\"},\"dsr\":[22,37,2,2]}'>bolded link</a></b> and this is a <span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"transclusion\"}},\"i\":0}}]}' data-parsoid='{\"dsr\":[55,76,null,null],\"pi\":[[{\"k\":\"1\",\"spc\":[\"\",\"\",\"\",\"\"]}]]}'>transclusion</span>\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17804 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
17805 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> This is a <b><a rel="mw:WikiLink" href="./Bolded_link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
17811 Ref: 6. indent-pres should not be output in ref-body
17823 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n bar\n baz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17825 <ol class="references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{}}'>
17826 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
17834 Ref: 7. No p-wrapping in ref-body
17853 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n\nbar\n\n\nbaz\n\n\n\nbooz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17855 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
17856 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
17871 Ref: 8. transclusion wikitext has lower precedence
17875 A <ref> foo {{echo|</ref> B C}}
17879 <p>A <span class="reference" data-mw="{"name":"ref","body":{"html":"foo <span typeof=\"mw:Nowiki\" data-parsoid='{\"src\":\"{{\",\"dsr\":[12,14,0,0]}'>{{</span>echo|"},"attrs":{}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C<span typeof="mw:Nowiki">}}</span></p>
17880 <ol class="references" typeof="mw:Extension/references" data-mw="{"name":"references","attrs":{}}">
17881 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <span typeof="mw:Nowiki">{{</span>echo|</li>
17886 Ref: 9. unclosed comments should not leak out of ref-body
17890 A <ref> foo <!--</ref> B C
17893 <p>A <span class="reference" data-mw='{"name":"ref","body":{"html":"foo <!---->"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C</p>
17894 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
17895 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo </li>
17900 Ref: 10. Unclosed HTML tags should not leak out of ref-body
17904 A <ref> <b> foo </ref> B C
17908 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"<b data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[8,16,3,0]}'> foo </b>"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref> <b> foo </ref>"}'><a href="#cite_note-1">[1]</a></span> B C</p>
17911 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'>
17912 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> <b data-parsoid='{"stx":"html","autoInsertedEnd":true}'> foo </b></li>
17917 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
17924 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo</ref>"}'><a href="#cite_note-1">[1]</a></span> B
17925 C <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bar</ref>"}'><a href="#cite_note-2">[2]</a></span> D</p>
17929 Ref: 12. ref-tags act as trailing newline migration barrier
17933 <!--the newline at the end of this line moves out of the p-tag-->a
17935 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
17940 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
17943 <p>b<!--the newline at the end of this line stays inside the p-tag--> <span about="#mwt1" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
17944 <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span></p>
17951 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
17959 <p><span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> A
17960 <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"bar\n"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span> B</p>
17964 Ref: 14. A nested ref-tag should be emitted as plain text
17968 <ref>foo <ref>bar</ref> baz</ref>
17972 <p><span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo &lt;ref>bar&lt;/ref> baz"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo <ref>bar</ref> baz</ref>"}'><a href="#cite_note-1">[1]</a></span></p>
17974 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'>
17975 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <ref>bar</ref> baz</li>
17980 Ref: 15. ref-tags with identical names should get identical indexes
17984 A1 <ref name="a">foo</ref> A2 <ref name="a" />
17985 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
17989 <p>A1 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span> A2 <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span>
17990 B1 <span about="#mwt7" class="reference" data-mw='{"name":"ref","attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span> B2 <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span></p>
17992 <ol about="#mwt10" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy">↑ <a href="#cite_ref-a-1-0">1.0</a> <a href="#cite_ref-a-1-1">1.1</a></span> foo</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy">↑ <a href="#cite_ref-b-2-0">2.0</a> <a href="#cite_ref-b-2-1">2.1</a></span> bar</li>
17996 ## We don't bother wt2wt-ing non-standard whitespace
17998 Ref: 16. Tokenizer should accept non-standard whitespace in <ref> and </ref> tags
18006 <p>A <span class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18008 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
18009 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
18013 References: 1. references tag without any refs should be handled properly
18019 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'></ol>
18023 References: 2. references tag with group only outputs references from that group
18027 A <ref group="a">foo</ref>
18028 B <ref group="b">bar</ref>
18030 <references group="a" />
18032 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
18033 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"group":"b"}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[b 1]</a></span></p>
18035 <ol about="#mwt6" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li>
18040 References: 3. ref list should be cleared after processing references
18052 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18054 <ol about="#mwt4" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li>
18057 <p>B <span about="#mwt6" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[1]</a></span></p>
18059 <ol about="#mwt8" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> bar</li>
18064 References: 4. only referenced group should be cleared after processing references
18068 A <ref group="a">afoo</ref>
18071 <references group="a" />
18077 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"afoo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
18078 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bfoo"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bfoo</ref>"}'><a href="#cite_note-2">[1]</a></span></p>
18080 <ol about="#mwt6" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> afoo</li>
18083 <p>C <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"cfoo"},"attrs":{}}' id="cite_ref-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-3">[2]</a></span></p>
18085 <ol about="#mwt10" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> bfoo</li><li about="#cite_note-3" id="cite_note-3"><span rel="mw:referencedBy"><a href="#cite_ref-3-0">↑</a></span> cfoo</li>
18090 References: 5. ref tags in references should be processed while ignoring all other content
18095 B <ref name="b">bar</ref>
18098 <ref name="a">foo</ref>
18099 This should just get lost.
18102 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"a\" />"}'><a href="#cite_note-a-1">[1]</a></span>
18103 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"b\">bar</ref>"}'><a href="#cite_note-b-2">[2]</a></span></p>
18106 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-parsoid='{"src":"<references>\n<ref name=\"a\">foo</ref>\nThis should just get lost.\n</references>"}' data-mw='{"name":"references","body":{"extsrc":"<ref name=\"a\">foo</ref>\nThis should just get lost.","html":"\n<span about=\"#mwt8\" class=\"reference\" data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"a\"}}' rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-a-1\">[1]</a></span>\n"},"attrs":{}}'>
18107 <li about="#cite_note-a-1" id="cite_note-a-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-a-1-0">↑</a></span> foo</li>
18108 <li about="#cite_note-b-2" id="cite_note-b-2" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> bar</li>
18113 References: 6. <references /> from a transclusion
18117 <ref>Foo</ref> {{echo|<references />}}
18119 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"Foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> <ol class="references" typeof="mw:Extension/references mw:Transclusion" about="#mwt4" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references />"}},"i":0}}]}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> Foo</li></ol>
18123 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
18127 A <ref>foo bar for a</ref>
18128 B <ref group="X" name="b" />
18132 <references group="X">
18133 <ref name="b">foo</ref>
18136 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo bar for a"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo bar for a</ref>"}'><a href="#cite_note-2" data-parsoid="{}">[2]</a></span>
18137 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}' id="cite_ref-b-3-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"b\" group=\"X\" />"}'><a href="#cite_note-b-3" data-parsoid="{}">[X 1]</a></span></p>
18139 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-b-1" id="cite_note-b-1" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}">↑</span> foo</li><li about="#cite_note-2" id="cite_note-2" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-2-0" data-parsoid="{}">↑</a></span> foo bar for a</li></ol>
18141 <ol class="references" typeof="mw:Extension/references" about="#mwt8" data-parsoid='{"src":"<references group=\"X\">\n<ref name=\"b\">foo</ref>\n</references>","group":"X"}' data-mw='{"name":"references","body":{"extsrc":"<ref name=\"b\">foo</ref>","html":"\n<span about=\"#mwt10\" class=\"reference\" data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"b\"}}' rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-b-1\">[1]</a></span>\n"},"attrs":{"group":"X"}}'><li about="#cite_note-b-3" id="cite_note-b-3" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-b-3-0" data-parsoid="{}">↑</a></span> </li></ol>
18144 # This test is wt2html only because we're permitting the serializer to produce
18145 # dirty diffs, normalizing the unclosed references to the self-closed version.
18147 Generate references for unclosed references tag
18155 <p data-parsoid='{}'>a<span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo</ref>"}'><a href="#cite_note-1" data-parsoid="{}">[1]</a></span></p>
18158 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-parsoid='{"src":"<references>"}' data-mw='{"name":"references","attrs":{}}'>
18159 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-1-0" data-parsoid="{}">↑</a></span> foo</li></ol>
18163 New reference serializes on its own line
18165 parsoid=wt2wt,html2wt
18170 foo<ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
18173 #### ----------------------------------------------------------------
18174 #### The following section of tests are primarily to test
18175 #### wikitext escaping capabilities of Parsoid. Given that
18176 #### escaping can be done any number of ways, the wikitext (input)
18177 #### is always adjusted to reflect how Parsoid adds nowiki
18180 #### We are marking several tests as parsoid-only since the
18181 #### HTML in the result section is different from what the
18182 #### PHP parser generates for it.
18183 #### ----------------------------------------------------------------
18186 #### --------------- Headings ---------------
18188 #### 1. Nested inside html <h1>=foo=</h1>
18189 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
18190 #### 3. Nested inside html with wikitext split by html tags
18191 #### 4. No escape needed
18192 #### 5. Empty headings <h1></h1>
18193 #### 6. Heading chars in SOL context
18194 #### ----------------------------------------
18196 Headings: 0. Unnested
18200 <nowiki>=foo=</nowiki>
18202 <nowiki> =foo= </nowiki>
18204 <nowiki>=foo=</nowiki>
18206 =foo''a''<nowiki>=</nowiki>
18208 <p><span typeof="mw:Nowiki">=foo=</span></p>
18210 <p><span typeof="mw:Nowiki"> =foo= </span>
18212 <span typeof="mw:Nowiki">=foo=</span></p>
18214 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
18218 Headings: 1. Nested inside html
18219 (New headings and existing headings are handled differently)
18229 =<nowiki>=foo=</nowiki>=
18230 ==<nowiki>=foo=</nowiki>==
18231 ===<nowiki>=foo=</nowiki>===
18232 ====<nowiki>=foo=</nowiki>====
18233 =====<nowiki>=foo=</nowiki>=====
18234 ======<nowiki>=foo=</nowiki>======
18241 <h1 data-parsoid='{}'>=foo=</h1>
18242 <h2 data-parsoid='{}'>=foo=</h2>
18243 <h3 data-parsoid='{}'>=foo=</h3>
18244 <h4 data-parsoid='{}'>=foo=</h4>
18245 <h5 data-parsoid='{}'>=foo=</h5>
18246 <h6 data-parsoid='{}'>=foo=</h6>
18250 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
18255 <nowiki>*</nowiki>bar
18261 <nowiki>=bar=</nowiki>
18269 Headings: 3. Nested inside html with wikitext split by html tags
18273 = ='''bold'''<nowiki>foo=</nowiki> =
18275 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
18279 Headings: 4a. No escaping needed (testing just h1 and h2)
18297 = <nowiki>=</nowiki> =
18305 <h1><i>=</i>foo=</h1>
18306 <h1><span typeof="mw:Nowiki">=</span></h1>
18310 Headings: 4b. No escaping needed (inside p-tags)
18325 Headings: 5. Empty headings
18337 =====<nowiki/>=====
18339 ======<nowiki/>======
18350 Headings: 6a. Heading chars in SOL context (with trailing spaces)
18354 <nowiki>=a=</nowiki>
18356 <nowiki>=a=</nowiki>
18358 <nowiki>=a=</nowiki>
18360 <nowiki>=a=</nowiki>
18369 Headings: 6b. Heading chars in SOL context (with trailing newlines)
18397 Headings: 6c. Heading chars in SOL context (leading newline break)
18402 <nowiki>=b=</nowiki>
18409 Headings: 6d. Heading chars in SOL context (with interspersed comments)
18413 <!--c0--><nowiki>=a=</nowiki>
18415 <!--c1--><nowiki>=a=</nowiki> <!--c2--> <!--c3-->
18417 <p><!--c0-->=a=</p>
18418 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
18422 Headings: 6d. Heading chars in SOL context (No escaping needed)
18431 #### --------------- Lists ---------------
18432 #### 0. Outside nests (*foo, etc.)
18433 #### 1. Nested inside html <ul><li>*foo</li></ul>
18434 #### 2. Inside definition lists
18435 #### 3. Only bullets at start should be escaped
18436 #### 4. No escapes needed
18437 #### 5. No unnecessary escapes
18438 #### 6. Escape bullets in SOL position
18439 #### 7. Escape bullets in a multi-line context
18440 #### ----------------------------------------
18443 Lists: 0. Outside nests
18445 <nowiki>*</nowiki>foo
18447 <nowiki>#</nowiki>foo
18455 Lists: 1. Nested inside html
18457 *<nowiki>*foo</nowiki>
18459 *<nowiki>#foo</nowiki>
18461 *<nowiki>:foo</nowiki>
18463 *<nowiki>;foo</nowiki>
18465 #<nowiki>*foo</nowiki>
18467 #<nowiki>#foo</nowiki>
18469 #<nowiki>:foo</nowiki>
18471 #<nowiki>;foo</nowiki>
18509 Lists: 2. Inside definition lists
18511 ;<nowiki>;foo</nowiki>
18513 ;<nowiki>:foo</nowiki>
18515 ;<nowiki>:foo</nowiki>
18518 :<nowiki>:foo</nowiki>
18542 Lists: 3. Only bullets at start of text should be escaped
18544 *<nowiki>*foo*bar</nowiki>
18546 *<nowiki>*foo</nowiki>''it''*bar
18553 <li>*foo<i>it</i>*bar
18560 Lists: 4. No escapes needed
18581 <li><a rel="mw:WikiLink" href="Foo">Foo</a>: bar
18585 <li><a rel="mw:WikiLink" href="Foo">Foo</a>*bar
18591 Lists: 5. No unnecessary escapes
18593 * bar <span><nowiki>[[foo]]</nowiki></span>
18595 *=bar <span><nowiki>[[foo]]</nowiki></span>
18597 *[[bar <span><nowiki>[[foo]]</nowiki></span>
18599 *]]bar <span><nowiki>[[foo]]</nowiki></span>
18601 *=bar <span>foo]]</span>=
18606 <li> bar <span>[[foo]]</span>
18610 <li>=bar <span>[[foo]]</span>
18614 <li>[[bar <span>[[foo]]</span>
18618 <li>]]bar <span>[[foo]]</span>
18622 <li>=bar <span>foo]]</span>=
18633 Lists: 6. Escape bullets in SOL position
18637 <!--cmt--><nowiki>*foo</nowiki>
18639 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
18643 Lists: 7. Escape bullets in a multi-line context
18646 <nowiki>*</nowiki>b
18653 #### --------------- HRs ---------------
18654 #### 1. Single line
18655 #### -----------------------------------
18658 HRs: 1. Single line
18662 ----<nowiki>----</nowiki>
18666 <hr><span typeof="mw:Nowiki">----</span>
18671 #### --------------- Tables ---------------
18672 #### 1a. Simple example
18673 #### 1b. No escaping needed (!foo)
18674 #### 1c. No escaping needed (|foo)
18675 #### 1d. No escaping needed (|}foo)
18677 #### 2a. Nested in td (<td>foo|bar</td>)
18678 #### 2b. Nested in td (<td>foo||bar</td>)
18679 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
18681 #### 3a. Nested in th (<th>foo!bar</th>)
18682 #### 3b. Nested in th (<th>foo!!bar</th>)
18683 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
18687 #### 4c. No escaping needed
18688 #### --------------------------------------
18691 Tables: 1a. Simple example
18702 Tables: 1b. No escaping needed
18711 Tables: 1c. No escaping needed
18720 Tables: 1d. No escaping needed
18729 Tables: 2a. Nested in td
18734 |<nowiki>foo|bar</nowiki>
18736 |x<div><nowiki>a|b</nowiki></div>
18740 <td>foo|bar</td></tr>
18741 <tr><td>x<div>a|b</div></td>
18746 Tables: 2b. Nested in td
18751 |<nowiki>foo||bar</nowiki>
18752 |''it''<nowiki>foo||bar</nowiki>
18756 <td><span typeof="mw:Nowiki">foo||bar</span></td>
18757 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
18761 Tables: 2c. Nested in td -- no escaping needed
18769 <table><tbody><tr><td>foo!!bar
18770 </td></tr></tbody></table>
18775 Tables: 3a. Nested in th
18783 <table><tbody><tr><th>foo!bar
18784 </th></tr></tbody></table>
18789 Tables: 3b. Nested in th
18794 !<nowiki>foo!!bar</nowiki>
18798 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
18803 Tables: 3c. Nested in th -- no escaping needed
18808 !<nowiki>foo||bar</nowiki>
18812 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
18816 Tables: 4a. Escape -
18823 |<nowiki>-bar</nowiki>
18827 <tr><th>-bar</th></tr>
18829 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
18833 Tables: 4b. Escape +
18840 |<nowiki>+bar</nowiki>
18844 <tr><th>+bar</th></tr>
18846 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
18850 Tables: 4c. No escaping needed
18871 <tr><td>foo-bar</td><td>foo+bar</td></tr>
18872 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
18878 <div>a|b</div></td>
18883 Tables: 4d. No escaping needed
18894 <tbody><tr><td><a rel="mw:WikiLink" href="./Foo">Foo</a>-bar</td>
18895 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>+1</td>
18896 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>-2</td></tr>
18901 Tables: Digest broken attributes on table and tr tag
18917 #### --------------- Links ----------------
18918 #### 1. Quote marks in link text
18919 #### 2. Wikilinks: Escapes needed
18920 #### 3. Wikilinks: No escapes needed
18921 #### 4. Extlinks: Escapes needed
18922 #### 5. Extlinks: No escapes needed
18923 #### --------------------------------------
18925 Links 1. Quote marks in link text
18929 [[Foo|Foo<nowiki>''boo''</nowiki>]]
18931 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
18935 Links 2. WikiLinks: Escapes needed
18940 [[Foo|<nowiki>Foobar]</nowiki>]]
18941 [[Foo|x [Foobar] x]]
18942 [[Foo|x <nowiki>[http://google.com g]</nowiki> x]]
18943 [[Foo|<nowiki>[[Bar]]</nowiki>]]
18944 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
18945 [[Foo|<nowiki>|Bar</nowiki>]]
18946 [[Foo|<nowiki>]]bar</nowiki>]]
18947 [[Foo|<nowiki>[[bar</nowiki>]]
18948 [[Foo|<nowiki>x [[ y</nowiki>]]
18949 [[Foo|<nowiki>x ]] y</nowiki>]]
18950 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
18952 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
18953 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
18954 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
18955 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
18956 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
18957 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
18958 <a href="Foo" rel="mw:WikiLink">|Bar</a>
18959 <a href="Foo" rel="mw:WikiLink">]]bar</a>
18960 <a href="Foo" rel="mw:WikiLink">[[bar</a>
18961 <a href="Foo" rel="mw:WikiLink">x [[ y</a>
18962 <a href="Foo" rel="mw:WikiLink">x ]] y</a>
18963 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
18967 Links 3. WikiLinks: No escapes needed
18974 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
18975 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
18979 Links 4. ExtLinks: Escapes needed
18983 [http://google.com <nowiki>[google]</nowiki>]
18984 [http://google.com <nowiki>google]</nowiki>]
18986 <nowiki>[http://google.com]</nowiki>
18988 <nowiki>[http://google.com google]</nowiki>
18991 <p><a href="http://google.com" rel="mw:ExtLink">[google]</a>
18992 <a href="http://google.com" rel="mw:ExtLink">google]</a></p>
18993 <p>[http://google.com]</p>
18994 <p>[http://google.com google]</p>
18998 Links 5. ExtLinks: No escapes needed
19002 [http://google.com [google]
19004 <a href="http://google.com" rel="mw:ExtLink">[google</a>
19007 #### --------------- Quotes ---------------
19008 #### 1. Quotes inside <b> and <i>
19009 #### 2. Link fragments separated by <i> and <b> tags
19010 #### 3. Link fragments inside <i> and <b>
19011 #### 4. No escaping needed
19012 #### --------------------------------------
19014 1. Quotes inside <b> and <i>
19016 parsoid=html2wt,wt2wt
19018 ''<nowiki>'foo'</nowiki>''
19019 ''<nowiki>''foo''</nowiki>''
19020 ''<nowiki>'''foo'''</nowiki>''
19022 '''<nowiki>'foo'</nowiki>'''
19023 '''<nowiki>''foo''</nowiki>'''
19024 '''<nowiki>'''foo'''</nowiki>'''
19025 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
19026 '''foo'''<nowiki/>'s
19029 '<nowiki/>''foo''<nowiki/>'
19031 '''foo'''<nowiki/>'
19032 '<nowiki/>'''foo'''<nowiki/>'
19033 ''fools'<span> errand</span>''
19034 ''<span>fool</span>'s errand''
19043 <b>foo'<i>bar'</i>baz</b>
19051 <i>fools'<span> errand</span></i>
19052 <i><span>fool</span>'s errand</i>
19056 2. Link fragments separated by <i> and <b> tags
19058 [[''foo''<nowiki>hello]]</nowiki>
19060 [['''foo'''<nowiki>hello]]</nowiki>
19062 <p>[[<i>foo</i>hello]]
19063 </p><p>[[<b>foo</b>hello]]
19068 3. Link fragments inside <i> and <b>
19069 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
19070 this is one of the shortcomings of this format)
19072 ''[[foo''<nowiki>]]</nowiki>
19074 '''[[foo'''<nowiki>]]</nowiki>
19077 </p><p><b>[[foo</b>]]
19082 4. No escaping needed
19084 '<span>''bar''</span>'
19085 '<span>'''bar'''</span>'
19087 <p>'<span><i>bar</i></span>'
19088 '<span><b>bar</b></span>'
19092 #### ----------- Paragraphs ---------------
19093 #### 1. No unnecessary escapes
19094 #### --------------------------------------
19097 1. No unnecessary escapes
19099 bar <span><nowiki>[[foo]]</nowiki></span>
19101 =bar <span><nowiki>[[foo]]</nowiki></span>
19103 [[bar <span><nowiki>[[foo]]</nowiki></span>
19105 ]]bar <span><nowiki>[[foo]]</nowiki></span>
19107 =bar <span>foo]]</span><nowiki>=</nowiki>
19109 <p>bar <span>[[foo]]</span>
19110 </p><p>=bar <span>[[foo]]</span>
19111 </p><p>[[bar <span>[[foo]]</span>
19112 </p><p>]]bar <span>[[foo]]</span>
19113 </p><p>=bar <span>foo]]</span>=
19117 #### ----------------------- PRE --------------------------
19118 #### 1. Leading whitespace in SOL context should be escaped
19119 #### ------------------------------------------------------
19121 1. Leading whitespace in SOL context should be escaped
19125 <nowiki> </nowiki>a
19127 <nowiki> </nowiki> a
19129 <nowiki> </nowiki>a(tab)
19131 <nowiki> </nowiki> a
19133 <nowiki> </nowiki> a
19136 <nowiki> </nowiki>b
19139 <nowiki> </nowiki>b
19142 <nowiki> </nowiki> b
19148 <p><!--cmt--> a</p>
19157 #### --------------- Behavior Switches --------------------
19159 1. Valid behavior switches should be escaped
19163 <nowiki>__TOC__</nowiki>
19169 2. Invalid behavior switches should not be escaped
19180 #### --------------- HTML tags ---------------
19183 #### 3. multi-line html tag
19184 #### 4. extension tags
19185 #### -----------------------------------------
19191 <a href="http://google.com">google</a>
19193 <a href="http://google.com">google</a>
19199 <nowiki><div>foo</div>
19200 <div style="color:red">foo</div></nowiki>
19202 <p><div>foo</div>
19203 <div style="color:red">foo</div>
19208 3. multi-line html tag
19223 <nowiki><ref>foo</ref></nowiki>
19225 <nowiki><ref>bar</nowiki>
19227 baz<nowiki></ref></nowiki>
19229 <p><ref>foo</ref>
19230 </p><p><ref>bar
19231 </p><p>baz</ref>
19235 #### --------------- Others ---------------
19239 <nowiki>foo</nowiki>
19241 <p><nowiki>foo</nowiki>
19245 ## The quote-char in the input is necessary for triggering the bug
19247 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
19249 parsoid=wt2wt,html2wt
19258 Tag-like HTML structures are passed through as text
19280 </p><p>1<d e>f
19285 # This was a bug in the PHP parser (see bug 17663 and its dups,
19286 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
19288 Tag names followed by punctuation should not be recognized as tags
19292 <p><s.ome> text
19297 HTML tag with necessary entities in attributes
19299 <span title="&amp;">foo</span>
19301 <p><span title="&amp;">foo</span>
19306 HTML tag with 'unnecessary' entity encoding in attributes
19308 <span title="&">foo</span>
19310 <p><span title="&">foo</span>
19315 HTML tag with broken attribute value quoting
19317 <span title="Hello world>Foo</span>
19319 <p><span>Foo</span>
19324 Parsoid-only: HTML tag with broken attribute value quoting
19328 <span title="Hello world>Foo</span>
19330 <p><span title="Hello world">Foo</span>
19335 Table with broken attribute value quoting
19338 | title="Hello world|Foo
19349 Table with broken attribute value quoting on consecutive lines
19352 | title="Hello world|Foo
19353 | style="color:red|Bar
19366 Parsoid-only: Table with broken attribute value quoting on consecutive lines
19371 | title="Hello world|Foo
19372 | style="color:red|Bar
19377 <td title="Hello world">Foo
19378 </td><td style="color: red">Bar
19379 </td></tr></tbody></table>
19384 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
19394 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
19404 Accept empty td cell attribute
19407 | align="center" | foo || |
19412 <td align="center"> foo </td>
19419 Non-empty attributes in th-cells
19422 ! Foo !! style="color: red" | Bar
19428 <th style="color: red"> Bar
19434 Accept empty attributes in th-cells
19449 Empty table rows go away
19470 ### Parsoid-centric tests for testing RTing of inter-element separators
19471 ### Edge cases not tested by existing parser tests and specific to
19472 ### Parsoid-specific serialization strategies.
19476 RT-ed inter-element separators should be valid separators
19489 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
19490 (Parsoid-only since PHP parser relies on Tidy for correct output)
19506 Empty TD followed by TD with tpl-generated attribute
19511 |{{echo|style='color:red'}}|foo
19525 Indented table with an empty td
19544 Empty TR followed by a template-generated TR
19545 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
19551 {{echo|<tr><td>foo</td></tr>}}
19557 <tr about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<tr><td>foo</td></tr>"}},"i":0}}]}'>
19562 ## PHP and parsoid output differ for this, and since this is primarily
19563 ## for testing Parsoid's serializer, marking this Parsoid only
19565 Empty TR followed by mixed-ws-comment line should RT correctly
19581 <!--c--> </tr><!--d-->
19587 Multi-line image caption generated by templates with/without trailing newlines
19591 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
19592 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
19594 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC</div></div></div>
19595 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC\n\n</div></div></div>
19600 New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
19604 <includeonly>foo</includeonly>
19611 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>foo</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><p>new para</p>
19613 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid=''/><h1>new heading</h1>
19616 ## PHP emits broken html for this, and since this is primarily
19617 ## a Parsoid serializer test, marking this Parsoid only
19619 Improperly nested inline or quotes tags with whitespace in between
19623 <span> <s>x</span> </s>
19626 <p><span> <s>x</s></span><s> </s>
19627 <b> <i>x</i></b><i> </i>
19632 Encapsulate protected attributes from wt
19636 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
19638 <body><div data-x-typeof="mw:placeholder stuff" data-x-data-parsoid="weird" data-x-data-parsoid-other="no" data-x-about="time" data-x-rel="mw:true">foo</div>
19642 ## Currently the p-wrapper is fragile in how it adds / removes transformations.
19643 ## Having nested or stray pre tags results in the attempt to add duplicates,
19644 ## causing an assertion fail. This test tries to prevent that situation.
19646 Ensure ParagraphWrapper can deal with stray closing pre tags
19656 1. Ensure fostered text content is wrapped in spans
19660 <table>hi</table><table>ho</table>
19669 2. Ensure fostered text content is wrapped in spans (traps regressions around fostered marker on the span getting lost)
19671 parsoid=wt2html,wt2wt
19678 <span> || ||</span>
19687 Encapsulation properly handles null DSR information from foster box
19689 parsoid=wt2html,wt2wt
19691 {{echo|<table>foo<tr><td>bar</td></tr></table>}}
19693 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"
19696 <td>bar</td></tr></table>"}},"i":0}}]}">foo</span>
19700 <td>bar</td></tr></tbody></table>
19704 1. Encapsulate foster-parented transclusion content
19706 parsoid=wt2wt,wt2html
19708 <table>{{echo|foo<tr><td>bar</td></tr>}}</table>
19710 <span typeof="mw:Transclusion" data-mw="{"parts":["
19711 <table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo
19713 <td>bar</td></tr>"}},"i":0}},"</table>"]}">foo</span>
19717 <td>bar</td></tr></tbody></table>
19721 2. Encapsulate foster-parented transclusion content
19723 parsoid=wt2wt,wt2html
19725 <table><div>{{echo|foo}}</div><tr><td>bar</td></tr></table>
19727 <div typeof="mw:Transclusion" data-mw="{"parts":["
19729 <div>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}},"</div>
19731 <td>bar</td></tr></table>"]}">foo</div>
19735 <td>bar</td></tr></tbody></table>
19739 3. Encapsulate foster-parented transclusion content
19741 parsoid=wt2wt,wt2html
19743 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
19745 <div typeof="mw:Transclusion" data-mw="{"parts":["
19748 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div>
19750 <td>"}},"i":0}},"bar</td></tr></table>"]}">
19755 <td>bar</td></tr></tbody></table>
19759 4. Encapsulate foster-parented transclusion content
19761 parsoid=wt2wt,wt2html
19763 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
19765 <div typeof="mw:Transclusion" data-mw="{"parts":["
19768 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div>
19770 <td>"}},"i":0}},"bar</td></tr></table>"]}">
19775 <td>bar</td></tr></tbody></table>
19779 5. Encapsulate foster-parented transclusion content
19781 parsoid=wt2wt,wt2html
19783 <table><tr><td><div><p>{{echo|foo</p></div></td>foo}}</tr></table>
19785 <span typeof="mw:Transclusion" data-mw="{"parts":["
19790 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo"}},"i":0}},"</tr></table>"]}">foo</span>
19796 <p>foo</p></div></td></tr></tbody></table>
19800 6. Encapsulate foster-parented transclusion content
19802 parsoid=wt2wt,wt2html
19804 <table><tr><td><div><p>{{echo|foo</p></div></td>foo</tr></table>}}<p>ok</p>
19806 <span typeof="mw:Transclusion" data-mw="{"parts":["
19811 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo</tr></table>"}},"i":0}}]}">foo</span>
19817 <p>foo</p></div></td></tr></tbody></table>
19822 7. Encapsulate foster-parented transclusion content
19824 parsoid=wt2wt,wt2html
19826 <table>{{echo|<p>foo</p>}}<td>bar</td></table>
19828 <p typeof="mw:Transclusion" data-mw="{"parts":["
19829 <table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"
19830 <p>foo</p>"}},"i":0}},"
19831 <td>bar</td></table>"]}">foo</p>
19835 <td>bar</td></tr></tbody></table>
19839 8. Encapsulate foster-parented transclusion content
19841 parsoid=wt2wt,wt2html
19844 }}{|{{echo|style='color:red'}}
19849 <p typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n"}},"i":0}}]}">a</p><span typeof="mw:Transclusion" data-mw="{"parts":["{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"style":{"wt":"'color:red'"}},"i":0}},"\n|-\n|b\n|}"]}">{{{1}}}</span>
19853 <td>b</td></tr></tbody></table>
19857 9. Encapsulate foster-parented transclusion content
19859 parsoid=wt2wt,wt2html
19861 <table>{{echo|hi</table>hello}}
19863 <span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"hi</table>hello"}},"i":0}}]}' data-parsoid='{"fostered":true,"autoInsertedEnd":true,"autoInsertedStart":true,"pi":[[{"k":"1","spc":["","","",""]}]]}'>hi</span>
19864 <table about="#mwt2" data-parsoid='{"stx":"html"}'></table><span about="#mwt2" data-parsoid="{}">hello</span>
19868 Table in fosterable position
19870 parsoid=wt2html,wt2wt
19879 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"OpenTable","href":"./Template:OpenTable"},"params":{},"i":0}},"\n<div>"]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[]]}'></div><span about="#mwt1" data-parsoid="{}">
19881 <table about="#mwt1" data-parsoid='{"autoInsertedEnd":true}'></table>
19888 Support <object> element with .data attribute
19892 <object data="test.swf"></object>
19894 <object data="test.swf"></object>
19897 # -----------------------------------------------------------------
19898 # The following section of tests are primarily to spec requirements
19899 # around serialization of new/edited content.
19901 # All these tests are marked Parsoid html2wt and html2html only
19902 # ----------------------------------------------------------------
19905 Image: Modifying size of an image (1)
19908 "modes": ["wt2wt"],
19910 ["img[height]", "attr", "height", "22"],
19911 ["img[width]", "attr", "width", "200"]
19915 [[Image:Foobar.jpg|230x230px]]
19917 [[Image:Foobar.jpg|200x200px]]
19921 Image: Modifying size of an image (2)
19924 "modes": ["wt2wt"],
19926 ["img[height]", "attr", "height", "100"],
19927 ["img[width]", "attr", "width", "500"]
19931 [[Image:Foobar.jpg|230x230px]]
19933 [[Image:Foobar.jpg|500x500px]]
19936 # Change in size is ignored so long as class='mw-default-size'
19938 Image: Modifying size of an image (3)
19941 "modes": ["wt2wt"],
19943 ["figure[class]", "removeClass", "mw-default-size"],
19944 ["figure img", "attr", "height", "19"],
19945 ["figure img", "attr", "width", "170"]
19949 [[Image:Foobar.jpg|thumb]]
19951 [[Image:Foobar.jpg|thumb|170x170px]]
19955 Image: Modifying alignment of an image (bug 48665)
19958 "modes": ["wt2wt"],
19960 ["figure[class]", "removeClass", "mw-halign-right"],
19961 ["figure[class]", "addClass", "mw-halign-left"]
19965 [[Image:Foobar.jpg|thumb|caption|right]]
19967 [[Image:Foobar.jpg|thumb|caption|left]]
19971 Image: Modifying mw-default-size of an frameless image (bug 62805)
19974 "modes": ["wt2wt"],
19976 ["figure.mw-default-size", "removeClass", "mw-default-size"]
19980 [[Image:Foobar.jpg|frameless|right]]
19982 [[Image:Foobar.jpg|frameless|right|220x220px]]
19986 Image: Modifying valign of an image (bug 49221)
19989 "modes": ["wt2wt"],
19991 ["*[typeof=\"mw:Image\"]", "removeClass", "mw-valign-middle"],
19992 ["*[typeof=\"mw:Image\"]", "addClass", "mw-valign-text-top"]
19996 [[File:Foobar.jpg|20px|middle]]
19998 [[File:Foobar.jpg|20px|text-top]]
20002 Image: Modifying alt attribute of an image (bug 56400)
20005 "modes": ["wt2wt"],
20007 ["img[alt]", "attr", "alt", "some alternate edited text"]
20011 [[File:Foobar.jpg|thumb|some caption|alt=some alternate text]]
20013 [[File:Foobar.jpg|thumb|some caption|alt=some alternate edited text]]
20017 Image: Modifying caption of an image
20020 "modes": ["wt2wt"],
20022 ["figcaption", "text", "new caption"]
20026 [[Image:Foobar.jpg|thumb|original caption]]
20028 [[Image:Foobar.jpg|thumb|new caption]]
20032 Image: empty alt attribute (bug 48924)
20036 [[File:Foobar.jpg|thumb|alt=|bar]]
20038 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"alt","ak":"alt="},{"ck":"caption","ak":"bar"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img alt="" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"alt":"","resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"alt":"alt=","resource":"File:Foobar.jpg"}}'/></a><figcaption>bar</figcaption></figure>
20042 #Image: new attributes should be serialized in wiki's language for RTL languages (bug 51852)
20047 #[[Imagen:Foobar.jpg|derecha|miniaturadeimagen]]
20049 #<figure class="mw-default-size mw-halign-right" typeof="mw:Image/Thumb"><a href="Imagen:Foobar.jpg"><img resource="./Imagen:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="20" width="180"/></a></figure>
20053 Image: Block level image should have \n before and after
20058 [[File:Foobar.jpg|right|thumb|150x150px]]
20061 <p>123</p><figure typeof="mw:Image/Thumb" class="mw-halign-right"><a href="./File:Foobar.png"><img src="http://192.168.142.128/mw/images/thumb/b/bc/Foobar.png/131px-Foobar.png" width="131" height="150" resource="./File:Foobar.png" data-parsoid='{"a":{"resource":"./File:Foobar.png","width":"131"},"sa":{"resource":"File:Foobar.png","width":"150"}}'></a></figure><p>456</p>
20065 Image: New block level image should have \n before and after (existing
20071 [[File:Foobar.jpg|right|thumb|150x150px]]
20074 <p data-parsoid='{"dsr":[0,3,0,0]}'>123</p>
20075 <figure class="mw-halign-right" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"right","ak":"right"},{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"150x150px"}],"dsr":[4,45,2,2]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"dsr":[6,43,null,null]}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/150px-Foobar.jpg" height="17" width="150" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"17","width":"150"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></figure>
20076 <p data-parsoid='{"dsr":[46,49,0,0]}'>456</p>
20080 Image: upright option (parsoid)
20084 [[File:Foobar.jpg|thumb|upright|caption]]
20085 [[File:Foobar.jpg|thumb|upright=0.5|caption]]
20086 [[File:Foobar.jpg|thumb|500x500px|upright=0.5|caption]]
20088 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="19" width="170"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="19" width="170"/></a><figcaption>caption</figcaption></figure><figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="57" width="500"/></a><figcaption>caption</figcaption></figure>
20092 Image: upright option is ignored on inline and frame images (parsoid)
20096 [[File:Foobar.jpg|500x500px|upright=0.5|caption]]
20098 <p><span typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="57" width="500"/></a></span></p>
20102 Image: from basic HTML (1)
20106 <span typeof="mw:Image">
20107 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
20110 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
20114 Image: from basic HTML (2)
20118 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
20120 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
20124 Image: from basic HTML (3)
20128 <a href="Main"><img src="File:Foobar.jpg" width=100 height=100 alt="Alt"></a>
20130 [[File:Foobar.jpg|link=Main|alt=Alt|100x100px]]
20134 Image: from basic HTML (4)
20138 <img src="File:Foobar.jpg">
20140 [[File:Foobar.jpg|link=]]
20144 Lists: Serialize correctly even when list content is wrapped in p-tags (like VE does)
20151 <li><p>foo</p></li>
20156 Lists: Serialize correctly even when list tags has unneeded whitespace between tags
20162 <ul> <li>foo</li></ul>
20166 Don't strip leading whitespace when handling indent-pre suppressing tags
20174 '''This is very bold of you!'''
20178 indented cell (no pre-wrapping!)
20185 <tr><td> indented row</td></tr>
20188 <b>This is very bold of you!</b>
20191 indented cell (no pre-wrapping!)
20199 Strip leading whitespace when handling indent-pre inducing tags
20231 Lists: Add space after bullets
20237 * <span> baz</span>
20242 <li><span> baz</span></li>
20247 Lists: Dont insert newlines in a serialized list item.
20254 <ul><li>a<br>b</li><li>c</li></ul>
20258 Headings: Add space before/after == (Bug 51744)
20268 == <span> baz</span> ==
20273 <h2><span> baz</span></h2>
20277 Parsoid: Serialize positional parameters with = in them as named parameter
20283 {{echo|1 = f=oo|2 = bar}}
20285 <!--Orig params with data-parsoid has heuristics for handling = chars-->
20286 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
20287 {{echo|<nowiki>f=oo</nowiki>|bar}}
20289 <p about="#mwt1" typeof="mw:Transclusion"
20290 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}}]}'>foo</p>
20292 <p about="#mwt1" typeof="mw:Transclusion"
20293 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}, "2":{"wt":"bar"}},"i":0}}]}'>foo</p>
20295 <!--Orig params with data-parsoid has heuristics for handling = chars-->
20296 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
20297 <p data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]},{"k":"2","spc":["","","",""]}]]}' about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"},"2":{"wt":"bar"}},"i":0}}]}'>foo</p>
20301 Parsoid: Correctly serialize block-node children when they are a combination of text and p-nodes
20317 <div>a<p>b</p></div>
20325 #-----------------------------
20326 # I/B quote minimization tests
20327 #-----------------------------
20330 1. I/B quote minimization: wikitext-only tags should be combined
20350 <p><i>A</i><i>B</i></p>
20351 <p><b>A</b><b>B</b></p>
20352 <p><i>A</i><b><i>B</i></b></p>
20353 <p><b>A</b><i><b>B</b></i></p>
20354 <p><b>A</b><i><b>B</b><b>C</b></i><b>D</b></p>
20355 <p><i><b>A</b></i><i><b>B</b></i></p>
20356 <p><i><b>A</b></i><b><i>B</i></b></p>
20357 <p><b><i>A</i></b><i><b>B</b></i></p>
20361 2. I/B quote minimization: wikitext and html tags should not be combined
20367 ''A'''''<i>B</i>'''
20369 <p><i>A</i><i data-parsoid='{"stx":"html"}'>B</i></p>
20370 <p><i>A</i><b><i data-parsoid='{"stx":"html"}'>B</i></b></p>
20374 3. I/B quote minimization: templated content stops minimization
20378 ''A''{{echo|''B''}}
20380 ''A''{{echo|'''''B'''''}}
20382 <p><i>A</i><i about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"''B''"}},"i":0}}]}'>B</i>
20383 <p><i>A</i><b about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"'''''B'''''"}},"i":0}}]}'><i>B</i></b>
20387 4. I/B quote minimization: new content should be mimimized with adjacent old content
20397 <p><i>A</i><i data-parsoid='{}'>B</i></p>
20398 <p><b data-parsoid='{}'>A</b><b>B</b></p>
20399 <p><i>A</i><b data-parsoid='{}'><i data-parsoid='{}'>B</i></b></p>
20402 #------------------------------------
20403 # End of I/B quote minimization tests
20404 #------------------------------------
20407 Bug 54262: New entities
20413 <span typeof="mw:Entity">foo</span>
20416 ## Note that there is no wikitext output for 'unknownproperty' ##
20417 ## Unknown magic words are silently dropped ##
20432 __NOCONTENTCONVERT__
20434 <meta property='mw:PageProp/toc' />
20435 <meta property='mw:PageProp/notoc' />
20436 <meta property='mw:PageProp/forcetoc' />
20437 <meta property='mw:PageProp/index' />
20438 <meta property='mw:PageProp/noindex' />
20439 <meta property='mw:PageProp/nogallery' />
20440 <meta property='mw:PageProp/noeditsection' />
20441 <meta property='mw:PageProp/notitleconvert' />
20442 <meta property='mw:PageProp/nocontentconvert' />
20443 <meta property='mw:PageProp/unknownproperty' />
20447 Consecutive <pre>s should not get merged
20449 parsoid=html2wt,html2html
20465 <pre>a</pre><pre>b</pre>
20479 Edited ISBN links not serializable as ISBN links should serialize as wikilinks
20483 [[Special:BookSources/1234567890|ISBN 1234567895]]
20485 <a rel="mw:ExtLink" href="./Special:BookSources/1234567890">ISBN 1234567895</a>
20489 Edited RFC links not serializable as RFC links should serialize as extlinks
20493 [//tools.ietf.org/html/rfc123 New RFC]
20495 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink">New RFC</a>
20499 Edited PMID links not serializable as PMID links should serialize as extlinks
20503 [//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract New PMID]
20505 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink">New PMID</a>
20509 Edited Redirect link should emit a non-piped wikitext link
20515 <link rel="mw:PageProp/redirect" href="Bar" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>
20518 # -----------------------------------------------------------------
20519 # End of section for Parsoid-only html2wt tests for serialization
20521 # -----------------------------------------------------------------
20528 Try for 100% code coverage