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-formedness
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.
73 MediaWiki:bad image list
75 * [[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>
181 Template:EmptyTRWithHTMLAttrTest
184 <tr align="center"></tr>
185 <tr><td>foo</td></tr>
186 <tr align="center"></tr>
187 <tr><td>bar</td></tr>
204 This is a simple paragraph.
206 <p>This is a simple paragraph.
211 Paragraphs with extra newline spacing
234 Paragraphs with newline spacing with comment lines in between
242 <!--foo--><!--More than 1 comment, still stripped-->
246 <!--foo--> <!----> <!-- bar -->
307 Paragraphs with newline spacing with non-empty white-space lines in between
334 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
342 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
381 Extra newlines: More paragraphs with indented comment
396 Extra newlines followed by heading
411 <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>
412 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
415 <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>
420 Extra newlines between heading and content are swallowed
428 <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>
429 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
436 http://fr.wikipedia.org/wiki/🍺
437 <!-- EasterEgg we love beer, better be able be able to link to it -->
439 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
443 # Note that the html+tidy output removes the spaces after the <li>,
444 # which is a bug (http://sourceforge.net/p/tidy/bugs/945/, etc).
445 # This is an issue for all tests with lists. We intentionally do
446 # *not* add html+tidy clauses for these, as we don't want to
447 # document/test the broken behavior. (Parsoid matches the non-tidy
448 # output in these cases.)
457 <li> Item 2</li></ul>
465 * plain''italic''plain
466 * plain''italic''plain''italic''plain
467 * plain'''bold'''plain
468 * plain'''bold'''plain'''bold'''plain
469 * plain''italic''plain'''bold'''plain
470 * plain'''bold'''plain''italic''plain
471 * plain''italic'''bold-italic'''italic''plain
472 * plain'''bold''bold-italic''bold'''plain
473 * plain'''''bold-italic'''italic''plain
474 * plain'''''bold-italic''bold'''plain
475 * plain''italic'''bold-italic'''''plain
476 * plain'''bold''bold-italic'''''plain
477 * plain l'''italic''plain
478 * plain l''''bold''' plain
481 <li> plain<i>italic</i>plain</li>
482 <li> plain<i>italic</i>plain<i>italic</i>plain</li>
483 <li> plain<b>bold</b>plain</li>
484 <li> plain<b>bold</b>plain<b>bold</b>plain</li>
485 <li> plain<i>italic</i>plain<b>bold</b>plain</li>
486 <li> plain<b>bold</b>plain<i>italic</i>plain</li>
487 <li> plain<i>italic<b>bold-italic</b>italic</i>plain</li>
488 <li> plain<b>bold<i>bold-italic</i>bold</b>plain</li>
489 <li> plain<i><b>bold-italic</b>italic</i>plain</li>
490 <li> plain<b><i>bold-italic</i>bold</b>plain</li>
491 <li> plain<i>italic<b>bold-italic</b></i>plain</li>
492 <li> plain<b>bold<i>bold-italic</i></b>plain</li>
493 <li> plain l'<i>italic</i>plain</li>
494 <li> plain l'<b>bold</b> plain</li></ul>
498 # this example taken from the [[simple:Moon]] article (bug 47326)
500 Italics and possessives (1)
502 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
504 <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
508 # this example taken from [[en:Flaming Pie]] (bug 49926)
510 Italics and possessives (2)
512 '''''Flaming Pie''''' is ... released in 1997. In ''Flaming Pie'''s liner notes
514 <p><i><b>Flaming Pie</b></i> is ... released in 1997. In <i>Flaming Pie'</i>s liner notes
518 # this example taken from [[en:Dictionary]] (bug 49926)
520 Italics and possessives (3)
522 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''.
524 <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>.
530 ### 2-quote opening sequence tests
533 Italics and bold: 2-quote opening sequence: (2,2)
542 Italics and bold: 2-quote opening sequence: (2,3)
552 # same html as previous, but wikitext adjusted to match parsoid html2wt
554 Italics and bold: 2-quote opening sequence: (2,3) w/ nowiki
563 Italics and bold: 2-quote opening sequence: (2,4)
573 # same html as previous, but wikitext adjusted to match parsoid html2wt
575 Italics and bold: 2-quote opening sequence: (2,4) w/ nowiki
577 ''foo<nowiki>''</nowiki>''
583 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
585 Italics and bold: 2-quote opening sequence: (2,5)
598 # same html as previous, but wikitext adjusted to match parsoid html2wt
600 Italics and bold: 2-quote opening sequence: (2,5+3) w/ nowiki
602 ''foo'''''<nowiki/>'''
613 ### 3-quote opening sequence tests
617 Italics and bold: 3-quote opening sequence: (3,2)
627 # same html as previous, but wikitext adjusted to match parsoid html2wt
629 Italics and bold: 3-quote opening sequence: (3,2) w/ nowiki
638 Italics and bold: 3-quote opening sequence: (3,3)
647 Italics and bold: 3-quote opening sequence: (3,4)
657 # same html as previous, but wikitext adjusted to match parsoid html2wt
659 Italics and bold: 3-quote opening sequence: (3,4) w/ nowiki
667 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
669 Italics and bold: 3-quote opening sequence: (3,5)
682 # same html as previous, but wikitext adjusted to match parsoid html2wt
684 Italics and bold: 3-quote opening sequence: (3,5+2) w/ nowiki
686 '''foo'''''<nowiki/>''
697 ### 4-quote opening sequence tests
701 Italics and bold: 4-quote opening sequence: (4,2)
711 # same html as previous, but wikitext adjusted to match parsoid html2wt
713 Italics and bold: 4-quote opening sequence: (4,2) w/ nowiki
715 <nowiki>''</nowiki>''foo''
722 Italics and bold: 4-quote opening sequence: (4,3)
732 # same html as previous, but wikitext adjusted to match parsoid html2wt
734 Italics and bold: 4-quote opening sequence: (4,3) w/ nowiki
743 Italics and bold: 4-quote opening sequence: (4,4)
753 # same html as previous, but wikitext adjusted to match parsoid html2wt
755 Italics and bold: 4-quote opening sequence: (4,4) w/ nowiki
757 '<nowiki/>'''foo'<nowiki/>'''
763 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
765 Italics and bold: 4-quote opening sequence: (4,5)
774 <p>'<b>foo</b><i></i>
778 # same html as previous, but wikitext adjusted to match parsoid html2wt
780 Italics and bold: 4-quote opening sequence: (4,5+2) w/ nowiki
782 '<nowiki/>'''foo'''''<nowiki/>''
787 <p>'<b>foo</b><i></i>
793 ### 5-quote opening sequence tests
797 Italics and bold: 5-quote opening sequence: (5,2)
807 # same html as previous, but wikitext adjusted to match parsoid html2wt
808 # skipping wt2html and html2html because it wants to put <i> before <b>
810 Italics and bold: 5-quote opening sequence: (5,2+3)
812 parsoid=wt2wt,html2wt
821 Italics and bold: 5-quote opening sequence: (5,3)
831 # same html as previous, but wikitext adjusted to match parsoid html2wt
833 Italics and bold: 5-quote opening sequence: (5,3+2)
842 Italics and bold: 5-quote opening sequence: (5,4)
848 <p><i><b>foo'</b></i>
852 # same html as previous, but wikitext adjusted to match parsoid html2wt
854 Italics and bold: 5-quote opening sequence: (5,4+2) w/ nowiki
856 '''''foo'<nowiki/>'''''
858 <p><i><b>foo'</b></i>
863 Italics and bold: 5-quote opening sequence: (5,5)
872 ### multiple quote sequences in a line
875 Italics and bold: multiple quote sequences: (2,4,2)
881 <p><i>foo'<b>bar</b></i>
886 # same html as previous, but wikitext adjusted to match parsoid html2wt
888 Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
890 ''foo'<nowiki/>'''bar'''''
892 <p><i>foo'<b>bar</b></i>
898 Italics and bold: multiple quote sequences: (2,4,3)
904 <p><i>foo'<b>bar</b></i>
909 # same html as previous, but wikitext adjusted to match parsoid html2wt
911 Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
913 ''foo'<nowiki/>'''bar'''''
915 <p><i>foo'<b>bar</b></i>
921 Italics and bold: multiple quote sequences: (2,4,4)
927 <p><i>foo'<b>bar'</b></i>
932 # same html as previous, but wikitext adjusted to match parsoid html2wt
934 Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
936 ''foo'<nowiki/>'''bar'<nowiki/>'''''
938 <p><i>foo'<b>bar'</b></i>
943 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
945 Italics and bold: multiple quote sequences: (3,4,2)
954 <p><b>foo'</b>bar<i></i>
958 # same html as previous, but wikitext adjusted to match parsoid html2wt
960 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
964 '''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
969 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
974 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
976 Italics and bold: multiple quote sequences: (3,4,3)
985 <p><b>foo'</b>bar<b></b>
989 # same html as previous, but wikitext adjusted to match parsoid html2wt
991 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
993 '''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
998 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
1003 ### other quote tests
1006 Italics and bold: other quote tests: (2,3,5)
1008 ''this is about '''foo's family'''''
1010 <p><i>this is about <b>foo's family</b></i>
1016 Italics and bold: other quote tests: (2,(3,3),2)
1018 ''this is about '''foo's''' family''
1020 <p><i>this is about <b>foo's</b> family</i>
1026 Italics and bold: other quote tests: (3,2,3,2)
1030 '''this is about ''foo'''s family''
1032 <p><b>this is about <i>foo</i></b><i>s family</i>
1037 # same html as previous, but wikitext adjusted to match parsoid html2wt
1039 Italics and bold: other quote tests: (3,2,3+2+2,2)
1041 '''this is about ''foo'''''<nowiki/>''s family''
1043 <p><b>this is about <i>foo</i></b><i>s family</i>
1049 Italics and bold: other quote tests: (3,2,3,3)
1053 '''this is about ''foo'''s family'''
1055 <p>'<i>this is about </i>foo<b>s family</b>
1060 # same html as previous, but wikitext adjusted to match parsoid html2wt
1062 Italics and bold: other quote tests: (3,2,3,3) w/ nowiki
1064 '<nowiki/>''this is about ''foo'''s family'''
1066 <p>'<i>this is about </i>foo<b>s family</b>
1072 Italics and bold: other quote tests: (3,(2,2),3)
1074 '''this is about ''foo's'' family'''
1076 <p><b>this is about <i>foo's</i> family</b>
1082 Italicized possessive
1084 The ''[[Main Page]]'''s talk page.
1086 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
1091 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
1092 (Requires tidy for PHP parser output to be fixed up)
1094 parsoid=wt2html,wt2wt
1111 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
1112 <td><i>a</i></td><td><i>b</i></td></tr>
1121 Non-html5 tags should be accepted
1123 <center>''foo''</center>
1125 <font>''foo''</font>
1126 <strike>''foo''</strike>
1129 <center><i>foo</i></center>
1130 <p><big><i>foo</i></big>
1131 <font><i>foo</i></font>
1132 <strike><i>foo</i></strike>
1138 <wbr> is valid wikitext (bug 52468)
1146 # <strike> is HTML4, <s> is HTML4/5.
1148 <s> or <strike> for strikethrough
1150 <strike>strike</strike>
1154 <p><strike>strike</strike>
1162 Text-level semantic html elements in wikitext
1165 <strong>text</strong>
1181 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1188 <strong>text</strong>
1204 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1212 # test cases taken from
1213 # http://www.w3.org/TR/html5/text-level-semantics.html#the-ruby-element
1215 Ruby markup (W3C-style)
1217 ; Mono-ruby for individual base characters
1218 : <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby>
1220 : <ruby>今日<rt>きょう</rt></ruby>
1222 : <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby>
1224 : <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby>
1226 : <ruby><rb>旧</rb><rb>金</rb><rb>山</rb><rt>jiù</rt><rt>jīn</rt><rt>shān</rt><rtc>San Francisco</rtc></ruby>
1228 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1229 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1230 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1233 <dl><dt> Mono-ruby for individual base characters</dt>
1234 <dd> <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby></dd>
1235 <dt> Group ruby</dt>
1236 <dd> <ruby>今日<rt>きょう</rt></ruby></dd>
1237 <dt> Jukugo ruby</dt>
1238 <dd> <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby></dd>
1239 <dt> Inline ruby</dt>
1240 <dd> <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby></dd>
1241 <dt> Double-sided ruby</dt>
1242 <dd> <ruby><rb>旧</rb><rb>金</rb><rb>山</rb><rt>jiù</rt><rt>jīn</rt><rt>shān</rt><rtc>San Francisco</rtc></ruby></dd></dl>
1244 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1245 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1246 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1251 # There is a tidy bug here: http://sourceforge.net/p/tidy/bugs/946/
1253 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
1255 <b→> doesn't work! </b→>
1257 <bä> doesn't work! </bä>
1259 <boo> works fine </boo>
1261 <s.foo>s.foo</s.foo>
1265 <p><b→> doesn't work! </b→>
1266 </p><p><bä> doesn't work! </bä>
1267 </p><p><boo> works fine </boo>
1268 </p><p><s.foo>s.foo</s.foo>
1269 </p><p><sub-ID#1>
1274 Isolated close tags should be treated as literal text (bug 52760)
1281 </p><p><s.foo>s</s>
1286 ### Special characters
1290 Bare pipe character (bug 52363)
1299 Bare pipe character from a template (bug 52363)
1308 ### <nowiki> test cases
1312 <nowiki> unordered list
1314 <nowiki>* This is not an unordered list item.</nowiki>
1316 <p>* This is not an unordered list item.
1323 <nowiki>Lorem ipsum dolor
1331 <p>Lorem ipsum dolor
1344 :There is not nowiki.
1345 :There is <nowiki>nowiki</nowiki>.
1347 #There is not nowiki.
1348 #There is <nowiki>nowiki</nowiki>.
1350 *There is not nowiki.
1351 *There is <nowiki>nowiki</nowiki>.
1353 <dl><dd>There is not nowiki.</dd>
1354 <dd>There is nowiki.</dd></dl>
1355 <ol><li>There is not nowiki.</li>
1356 <li>There is nowiki.</li></ol>
1357 <ul><li>There is not nowiki.</li>
1358 <li>There is nowiki.</li></ul>
1363 Entities inside <nowiki>
1365 <nowiki><</nowiki>
1372 Entities inside template parameters
1378 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}}]}'>–</span></p>
1382 Properly escape nowiki when combined with other wiki markup
1386 <nowiki>* </nowiki></nowiki> tag
1388 <p>* </nowiki> tag</p>
1395 Comments and Indent-Pre
1397 <!-- comment 1 --> asdf
1399 <!-- comment 1 --> asdf
1402 <!-- comment 1 --> asdf
1403 <!-- comment 2 -->xyz
1405 <!-- comment 1 --> asdf
1406 <!-- comment 2 --> xyz
1462 asdf<!-- comment 1 -->jkl
1472 <!-- foo --> b <!-- bar -->
1486 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1492 Comment semantics and delimiters
1494 <!-- --><!----><!-----><!------>
1500 Comment semantics and delimiters, redux
1502 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1503 -- foo -- funky huh? ... -->
1509 Comment semantics and delimiters: directors cut
1511 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1512 everything starting with < followed by !-- until the first -- and > we see,
1513 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1521 Comment semantics: nesting
1523 <!--<!-- no, we're not going to do anything fancy here -->-->
1530 Comment semantics: unclosed comment at end
1532 <!--This comment will run out to the end of the document
1537 # Bug 58184: document parsoid's behaviour
1539 Suppress comment closing tag in lenient browsers
1541 parsoid=wt2html,html2html
1543 <!-- Browsers--!> think this is closed -->
1547 <!-- Browsers--¡> think this is closed -->
1551 Comment in template title
1560 Comment on its own line post-expand
1572 Comment on its own line post-expand with non-significant whitespace
1584 Multiple comments should still parse as SOL-transparent
1586 parsoid=wt2html,wt2wt
1589 <!--c2--><!--c3--><!--c4-->*b
1600 ### paragraph wrapping tests
1615 Block tag on one line (<div>)
1631 Block tag on one line (<blockquote>)
1633 a <blockquote>foo</blockquote>
1637 a <blockquote>foo</blockquote>
1649 Block tag on both lines (<div>)
1666 Block tag on both lines (<blockquote>)
1668 a <blockquote>foo</blockquote>
1670 b <blockquote>foo</blockquote>
1672 a <blockquote>foo</blockquote>
1673 b <blockquote>foo</blockquote>
1687 Multiple lines without block tags
1711 # Tidy strips out the empty <div> tags. Parsoid doesn't.
1712 # So, we have a separate section for Parsoid. We don't want
1713 # to mimic this stripping behavior in Parsoid. It affects
1714 # editing experience and also requires us to maintain additional
1717 Empty lines between lines with block tags
1755 <div data-parsoid='{"stx":"html"}'></div>
1758 <div data-parsoid='{"stx":"html"}'></div><p>a</p>
1761 <div data-parsoid='{"stx":"html"}'>a</div><p>b</p>
1763 <div data-parsoid='{"stx":"html"}'>b</div><p>d</p>
1766 <div data-parsoid='{"stx":"html"}'>e</div>
1769 ## PHP parser emits output which is broken
1770 ## XXX The parsoid output doesn't match the tidy output.
1772 Unclosed HTML p-tags should be handled properly
1780 <p>foo</div></p>
1784 <div data-parsoid='{"stx":"html"}'><p data-parsoid='{"stx":"html", "autoInsertedEnd":true}'>foo</p></div>
1789 ## SSS FIXME: I can come up with other scenarios where this doesn't work because
1790 ## of eager output of buffered tokens in the p-wrapper. But, I'm going to ignore
1793 1. P-wrapping should leave sol-transparent tags outside p-tags where possible
1797 a [[Category:A1]] [[Category:A2]]
1802 <link href="Category:A1"/> <link href="Category:A2"/> <link href="Category:A3"/> <link href="Category:A4"/>
1806 2. P-wrapping should leave sol-transparent tags outside p-tags where possible
1812 <link href="Category:A1"/><p>a</p>
1816 ### Preformatted text
1825 And a [[Main Page|link]]
1831 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1836 Tabs don't trigger preformatted text
1840 This is preformatted text.
1846 <pre>This is preformatted text.
1852 Ident preformatting with inline content
1863 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1880 Regression with preformatted in <center>
1894 Bug 52763: Preformatted in <blockquote>
1900 indented cell (no pre-wrapping!)
1910 <p> indented cell (no pre-wrapping!)
1918 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
1935 Bug 15491: <ins>/<del> in blockquote
1938 Foo <del>bar</del> <ins>baz</ins> quux
1942 <p>Foo <del>bar</del> <ins>baz</ins> quux
1948 # Note that the p-wrapping is newline sensitive, which could be
1949 # considered a bug: tidy will wrap only the 'Foo' in the example
1950 # below in a <p> tag. (see comment 23-25 of bug #6200)
1952 Bug 15491: <ins>/<del> in blockquote (2)
1954 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1957 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1963 <del>bar</del> <ins>baz</ins> quux</blockquote>
1967 <pre> with attributes (bug 3202)
1969 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1971 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1976 <pre> with width attribute (bug 3202)
1978 <pre width="8">Narrow screen goodies</pre>
1980 <pre width="8">Narrow screen goodies</pre>
1985 <pre> with forbidden attribute (bug 3202)
1987 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1989 <pre width="8">Narrow screen goodies</pre>
1994 Entities inside <pre>
2003 <pre> with forbidden attribute values (bug 3202)
2005 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
2007 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
2012 <nowiki> inside <pre> (bug 13238)
2020 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
2028 <pre><nowiki>Foo</nowiki></pre>
2033 <nowiki> and <pre> preference (first one wins)
2064 </pre> inside nowiki
2066 <nowiki></pre></nowiki>
2072 # Parsoid doesn't strip empty tags, like Tidy does.
2074 Empty pre; pre inside other HTML tags (bug 54946)
2076 parsoid=wt2html,wt2wt
2107 HTML pre followed by indent-pre
2122 <p><pre>foo</pre></p>
2124 <p data-parsoid='{"stx":"html","autoInsertedEnd":true}'></p><pre data-parsoid='{"stx":"html"}'>foo</pre><p data-parsoid='{"autoInsertedStart":true,"stx":"html"}'></p>
2128 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
2136 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
2146 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
2158 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
2179 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
2183 {{echo| foo}}{{echo| bar}}
2188 {{echo|<!--cmt--> foo}}
2190 <!--cmt-->{{echo| foo}}
2192 {{echo|{{echo| }}bar}}
2210 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
2247 Things that look like <pre> tags aren't treated as such
2249 Barack Obama <President> of the United States
2250 <President></President>
2252 <p>Barack Obama <President> of the United States
2253 <President></President>
2257 ## PHP parser discards the "<pre " string
2259 Handle broken pre-like tags (bug 64025)
2263 {{echo|<pre <pre>x</pre>}}
2265 <table><pre </table>
2268 <table><pre></pre></table>
2271 <pre about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"a":{"<pre":null},"sa":{"<pre":""},"stx":"html","pi":[[{"k":"1","spc":["","","",""]}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<pre <pre>x</pre>"}},"i":0}}]}'>x</pre>
2280 Parsoid: handle pre with space after attribute
2284 <pre style="width:50%;" >{{echo|foo}}</pre>
2286 <pre style="width:50%;">{{echo|foo}}</pre>
2289 # TODO / maybe: fix wt2wt for this
2291 Parsoid: Don't paragraph-wrap fosterable content
2317 Parsoid: Don't paragraph-wrap fosterable content even if table syntax is unbalanced
2345 #--------------------------------------------------------------------
2346 # Transclusion parameter whitespace stripping tests
2347 # Behavior is different for positional and named parameters
2348 #--------------------------------------------------------------------
2350 Templates: Strip leading and trailing whitespace from named-param values
2354 {{echo|1= {{echo|b}} }}
2367 <ul><li> d</li></ul>
2372 Templates: Don't strip whitespace from positional-param values
2376 {{echo|{{echo|b}} }}
2408 <ul><li> f</li></ul>
2416 Templates: Handle empty comment-and-ws-only lines correctly
2419 <!--should be ignored-->
2420 <!--should be ignored as well-->
2429 Templates: Handle comments in the target
2432 <!-- should be ignored -->
2435 {{echo<!-- should be ignored -->
2438 {{echo<!-- should be ignored -->|foo}}
2440 {{<!-- should be ignored -->echo|foo}}
2442 <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>
2444 <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>
2446 <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>
2448 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2452 Templates: Handle comments in parameter names (bug 67657)
2455 <!-- should be ignored -->
2459 <!-- should be ignored -->
2462 {{echo|1<!-- should be ignored --> = foo}}
2464 {{echo|<!-- should be ignored -->1 = foo}}
2466 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"1\n<!-- should be ignored -->"}}},"i":0}}]}'>foo</p>
2468 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"<!-- should be ignored -->\n1"}}},"i":0}}]}'>foo</p>
2470 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"1<!-- should be ignored -->"}}},"i":0}}]}'>foo</p>
2472 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"<!-- should be ignored -->1"}}},"i":0}}]}'>foo</p>
2476 Templates: Other wikitext in parameter names (bug 67657)
2480 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"''1''":{"wt":"foo"}},"i":0}}]}'>{{{1}}}</p>
2486 #--------------------------------------------------------------------
2487 # Transclusion parameter escaping tests
2488 #--------------------------------------------------------------------
2490 Templates: Parsoid parameter escaping test 1
2494 {{echo|[foo]|{{echo|[bar]}}}}
2496 <p about="#mwt1" typeof="mw:Transclusion"
2497 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}}]}'>[foo]</p>
2501 Parsoid: Pipes in external links in template parameter
2505 {{echo|[{{echo|http://example.com}} link]}}
2507 <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>
2511 Parsoid: pipe in transclusion parameter
2515 {{echo|http://foo.com/a|b}}
2517 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2518 typeof="mw:Transclusion"
2519 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>
2523 Parsoid: Pipe in external link target and content in template parameter
2525 parsoid=html2wt,wt2wt
2527 {{echo|[http://foo.com/a|b a|b]}}
2529 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2530 typeof="mw:Transclusion"
2531 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},
2532 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}}]}'>a|b</a></p>
2536 Parsoid: Pipe in template with nested template in external link target in template parameter (seriously)
2540 {{echo|[{{fullurl:{{FULLPAGENAME}}|action=edit}} bar]}}
2542 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[{{fullurl:{{FULLPAGENAME}}|action=edit}} bar]"}},"i":0}}]}'>[Main Page bar]</p>
2546 Templates: Don't escape already nowiki-escaped text in template parameters
2548 parsoid=html2wt,wt2wt
2550 {{echo|foo<nowiki>|</nowiki>bar}}
2551 {{echo|<nowiki><div></nowiki>}}
2552 {{echo|<nowiki></nowiki>}}
2554 <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>
2555 <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>
2556 <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>
2562 Templates: '=' char in nested transclusions should not trigger nowiki escapes or conversion to named param
2564 parsoid=html2wt,wt2wt
2566 {{echo|{{echo|1=bar}}}}
2568 <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>
2573 Templates parameters with special tokenizing behavior dont get modified because of arg escaping
2579 <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>
2583 ### Parsoid-centric tests for testing RT edge cases for pre
2587 1a. Indent-Pre and Comments
2600 1b. Indent-Pre and Comments
2613 1c. Indent-Pre and Comments
2626 1d. Indent-Pre and Comments
2627 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
2640 2a. Indent-Pre and tables
2661 2b. Indent-Pre and tables
2677 2c. Indent-Pre and tables (bug 42252)
2694 2d. Indent-Pre and tables
2711 <tbody><tr><td> b</td></tr>
2716 2e. Indent-Pre and table-line syntax
2729 2f. Indent-pre started by table-line syntax
2748 3a. Indent-Pre and block tags (single-line html)
2752 c <blockquote> foo </blockquote>
2757 c <blockquote> foo </blockquote>
2758 <pre><span> foo </span>
2761 <p>a </p><p data-parsoid='{"stx":"html"}'> foo </p>
2762 <p>b </p><div data-parsoid='{"stx":"html"}'> foo </div>
2763 <p>c </p><blockquote data-parsoid='{"stx":"html"}'> foo </blockquote>
2764 <pre><span> foo </span>
2781 3b. Indent-Pre and block tags (multi-line html)
2786 <pre>a <span>foo</span>
2791 <pre>a <span data-parsoid='{"stx":"html"}'>foo</span></pre>
2792 b <div data-parsoid='{"stx":"html"}'> foo </div>
2802 3c. Indent-Pre and block tags (pre-content on separate line)
2866 4. Indent-Pre and extension tags
2872 a <ul class="gallery mw-gallery-traditional">
2873 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
2874 <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>
2875 <div class="gallerytext">
2882 <ul class="gallery mw-gallery-traditional">
2883 <li class="gallerybox" style="width: 155px">
2884 <div style="width: 155px">
2885 <div class="thumb" style="width: 150px;">
2886 <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>
2888 <div class="gallerytext"></div>
2895 Table wikitext syntax outside wiki-tables
2898 ! not a table heading
2901 | class="foo bar" | baz
2908 ! not a table heading
2911 | class="foo bar" | baz
2920 Render paragraphs when indent-pre is suppressed in blocklevels
2937 4. Multiple spaces at start-of-line
2955 ## NOTE: the leading white-space chars on empty line are significant
2957 5a. White-space in indent-pre
2969 ## NOTE: the leading white-space chars on empty line are significant
2971 5b. White-space in indent-pre
2990 5c. White-space in indent-pre
3003 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
3026 7a. Indent-pre and category links
3028 parsoid=wt2html,wt2wt
3030 [[Category:foo]] <!-- No pre-wrapping -->
3031 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
3033 <link rel="mw:PageProp/Category" href="./Category:Foo"> <!-- No pre-wrapping -->
3034 <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":" [[Category:foo]]"}},"i":0}}]}'> </span><link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1"> <!-- No pre-wrapping -->
3038 7b. Indent-pre and category links
3040 parsoid=wt2html,wt2wt
3043 [[Category:foo]] {{echo|b}}
3046 <link rel="mw:PageProp/Category" href="./Category:Foo"> a
3047 <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>
3051 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
3055 HTML-pre: 1. embedded newlines
3089 <pre data-parsoid='{"stx":"html"}'>foo</pre>
3091 <pre data-parsoid='{"stx":"html","strippedNL":"\n"}'>
3095 <pre data-parsoid='{"stx":"html"}'>
3100 <pre data-parsoid='{"stx":"html"}'>
3108 HTML-pre: big spaces
3145 <pre data-parsoid='{"stx":"html"}'>
3164 HTML-pre: 2: indented text
3177 HTML-pre: 3: other wikitext
3198 ### Definition lists
3205 <dl><dt> name </dt>
3206 <dd> Definition</dd></dl>
3211 Definition list for indentation only
3215 <dl><dd> Indented text</dd></dl>
3220 Definition list with no space
3225 <dd>Definition</dd></dl>
3230 Definition list with URL link
3232 ; http://example.com/ : definition
3234 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt>
3235 <dd> definition</dd></dl>
3240 Definition list with bracketed URL link
3242 ;[http://www.example.com/ Example]:Something about it
3244 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt>
3245 <dd>Something about it</dd></dl>
3250 Definition list with wikilink containing colon
3252 ; [[Help:FAQ]]: The least-read page on Wikipedia
3254 <dl><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>
3255 <dd> The least-read page on Wikipedia</dd></dl>
3259 # At Brion's and JeLuF's insistence... :)
3261 Definition list with news link containing colon
3263 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
3265 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt>
3266 <dd> This isn't even a real newsgroup!</dd></dl>
3271 Malformed definition list with colon
3273 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
3275 <dl><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</dt></dl>
3280 Definition lists: colon in external link text
3282 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
3284 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt>
3285 <dd> OK, I made that up</dd></dl>
3290 Definition lists: colon in HTML attribute
3292 ;<b style="display: inline">bold</b>
3294 <dl><dt><b style="display: inline">bold</b></dt></dl>
3299 Definition lists: self-closed tag
3301 ;one<br/>two : two-line fun
3303 <dl><dt>one<br />two </dt>
3304 <dd> two-line fun</dd></dl>
3309 Bug 11748: Literal closing tags
3313 <dd>test test test test test</dd>
3315 <dd>test test test test test</dd>
3320 <dd>test test test test test</dd>
3322 <dd>test test test test test</dd>
3328 Definition and unordered list using wiki syntax nested in unordered list using html tags.
3331 ; term : description
3336 <dl><dt> term </dt>
3337 <dd> description</dd></dl>
3338 <ul><li> unordered</li></ul>
3345 Definition list with empty definition and following paragraph
3357 Nested definition lists using html syntax
3366 Definition Lists: No nesting: Multiple dd's
3379 Definition Lists: Indentation: Regular
3387 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3392 Definition Lists: Indentation: Missing 1st level
3398 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3403 Definition Lists: Indentation: Multi-level indent
3407 <dl><dd><dl><dd><dl><dd>i3</dd></dl></dd></dl></dd></dl>
3412 Definition Lists: Hacky use to indent tables
3419 should be left alone
3421 <dl><dd><dl><dd><table>
3426 </td></tr></table></dd></dl></dd></dl>
3428 should be left alone
3433 Definition Lists: Hacky use to indent tables, with comments (bug 63979)
3441 should be left alone
3444 <dl><dd><dl><dd><table><tr>
3447 </tr></table><!-- bar --></dd></dl></dd></dl>
3449 should be left alone</p>
3453 Definition Lists: Hacky use to indent tables, with comment before table
3459 <dl><dd><dl><dd><!-- foo --><table><tr>
3461 </tr></table></dd></dl></dd></dl>
3466 Definition Lists: Hacky use to indent tables (WS-insensitive)
3475 <dd> <table><tr><td>a</td></tr></table> </dd>
3478 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
3479 ## as an empty dt item. It also ignores all but the last ";" when followed
3480 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
3481 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
3484 ## Ex: ";;t2 ::d2" is transformed into:
3496 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
3497 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
3508 ## All Parsoid only definition list tests have this difference.
3510 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
3511 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
3514 Table / list interaction: indented table with lists in table contents
3529 <ul><li> b</li></ul>
3533 <ul><li> d</li></ul>
3534 </td></tr></table></dd></dl>
3539 Table / list interaction: lists nested in tables nested in indented lists
3562 </td></tr></table></dd></dl>
3569 Definition Lists: Nesting: Multi-level (Parsoid only)
3599 Definition Lists: Nesting: Test 2 (Parsoid only)
3619 Definition Lists: Nesting: Test 3 (Parsoid only)
3647 Definition Lists: Nesting: Test 4
3652 <dl><dd><dl><dd><dl><dt>t3</dt>
3653 <dd>d3</dd></dl></dd></dl></dd></dl>
3658 ## The Parsoid team believes the following three test exposes a
3659 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
3660 ## wrong to close the <dl> after the <dt> containing the <ul>.)
3661 ## It also exposes a "misfeature" in tidy, which doesn't like
3662 ## <dl> tags with a single <dt> child; it converts the <dt> into
3663 ## a <dd> in that case. (Parsoid leaves the <dt> alone!)
3665 Definition Lists: Mixed Lists: Test 1
3671 <dl><dd><dl><dt><ul><li> foo</li>
3672 <li> bar</li></ul></dt></dl>
3673 <dl><dt> baz</dt></dl></dd></dl>
3708 Definition Lists: Mixed Lists: Test 2
3713 <ul><li><dl><dd> d1</dd>
3714 <dd> d2</dd></dl></li></ul>
3720 Definition Lists: Mixed Lists: Test 3
3725 <ul><li><dl><dd><dl><dd><dl><dd> d1</dd>
3726 <dd> d2</dd></dl></dd></dl></dd></dl></li></ul>
3732 Definition Lists: Mixed Lists: Test 4
3737 <ul><li><dl><dt>d1 </dt>
3740 <dd>d4</dd></dl></li></ul>
3746 Definition Lists: Mixed Lists: Test 5
3752 <dl><dd> d2</dd></dl></dd></dl></li></ul>
3758 Definition Lists: Mixed Lists: Test 6
3763 <ol><li><ul><li><dl><dd>d1
3764 <dl><dd><dl><dd> d3</dd></dl></dd></dl></dd></dl></li></ul></li></ol>
3770 Definition Lists: Mixed Lists: Test 7
3775 <dl><dd><ul><li> d1</li>
3776 <li> d2</li></ul></dd></dl>
3782 Definition Lists: Mixed Lists: Test 8
3787 <dl><dd><ul><li> d1</li></ul>
3788 <dl><dd><ul><li> d2</li></ul></dd></dl></dd></dl>
3794 Definition Lists: Mixed Lists: Test 9
3798 <ul><li><dl><dt>foo </dt>
3799 <dd>bar</dd></dl></li></ul>
3805 Definition Lists: Mixed Lists: Test 10
3809 <ul><li><ol><li><dl><dt>foo </dt>
3810 <dd>bar</dd></dl></li></ol></li></ul>
3814 # The Parsoid team disagrees with the PHP parser's seemingly-random
3815 # rules regarding dd/dt on the next two tests. Parsoid is more
3816 # consistent, and recognizes the shared nesting and keeps the
3817 # still-open tags around until the nesting is complete.
3818 # (And tidy again converts <dt> to <dd> before 'bar'.)
3821 Definition Lists: Mixed Lists: Test 11
3826 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt>
3827 <dd><ul><li><dl><dt><dl><dt>bar</dt></dl></dd></dl></li></ul></dd></dl>
3828 <dl><dt>boo </dt>
3829 <dd>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
3884 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3885 <dd data-parsoid='{"stx":"row"}'>bar</dd>
3889 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3890 <dd data-parsoid='{"stx":"row"}'>baz</dd>
3899 # Another case where tidy converts a <dt> to a <dd> (but Parsoid doesn't).
3901 Definition Lists: Weird Ones: Test 1
3903 *#;*::;; foo : bar (who uses this?)
3905 <ul><li><ol><li><dl><dt> foo </dt>
3906 <dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)</dt></dl></dd></dl></dd></dl></dd></dl></li></ul></dd></dl></li></ol></li></ul>
3925 <dt>bar (who uses this?)</dt>
3957 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3958 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd>
3973 External links: non-bracketed
3975 Non-bracketed: http://example.com
3977 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3981 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3983 External links: numbered
3985 Numbered: [http://example.com]
3986 Numbered: [http://example.net]
3987 Numbered: [http://example.com]
3989 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
3990 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
3991 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
3994 <p>Numbered: <a rel="mw:ExtLink" href="http://example.com"></a>
3995 Numbered: <a rel="mw:ExtLink" href="http://example.net"></a>
3996 Numbered: <a rel="mw:ExtLink" href="http://example.com"></a></p>
4000 External links: specified text
4002 Specified text: [http://example.com link]
4004 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
4009 External links: trail
4011 Linktrails should not work for external links: [http://example.com link]s
4013 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
4018 External links: dollar sign in URL
4020 http://example.com/1$2345
4022 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
4026 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4028 External links: dollar sign in URL (autonumber)
4030 [http://example.com/1$2345]
4032 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
4035 <p><a rel="mw:ExtLink" href="http://example.com/1$2345"></a></p>
4039 External links: open square bracket forbidden in URL (bug 4377)
4041 parsoid=wt2html,wt2wt,html2html
4043 http://example.com/1[2345
4045 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
4048 <p><a rel="mw:ExtLink" href="http://example.com/1">http://example.com/1</a>[2345</p>
4052 External links: open square bracket forbidden in URL (named) (bug 4377)
4054 parsoid=wt2html,html2html
4056 [http://example.com/1[2345]
4058 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
4061 <p><a rel="mw:ExtLink" href="http://example.com/1">[2345</a></p>
4064 # parsoid adds a space before the link name
4066 External links: open square bracket forbidden in URL (named) (bug 4377)
4069 [http://example.com/1 [2345]
4071 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
4076 External links: nowiki in URL link text (bug 6230)
4078 [http://example.com/ <nowiki>''example site''</nowiki>]
4080 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
4085 External links: newline forbidden in text (bug 6230 regression check)
4087 [http://example.com/ first
4090 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
4096 External links: Pipe char between url and text
4098 [http://example.com | link]
4100 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
4105 External links: protocol-relative URL in brackets
4107 [//example.com/ Test]
4109 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
4113 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4115 External links: protocol-relative URL in brackets without text
4119 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
4122 <p><a rel="mw:ExtLink" href="//example.com"></a></p>
4126 External links: protocol-relative URL in free text is left alone
4130 <p>//example.com/Foo
4135 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
4137 foo//example.com/Foo
4139 <p>foo//example.com/Foo
4144 External links: with no contents
4146 [http://en.wikipedia.org/wiki/Foo]
4148 [[wikipedia:Foo|Bar]]
4150 [[wikipedia:Foo|<span>Bar</span>]]
4152 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/wiki/Foo">[1]</a>
4153 </p><p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo">Bar</a>
4154 </p><p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo"><span>Bar</span></a>
4157 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo"></a></p>
4158 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="wikipedia:Foo">Bar</a></p>
4159 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="wikipedia:Foo"><span>Bar</span></a></p>
4163 External links: Free with trailing punctuation
4173 http://example.com/url_with_(brackets)
4174 (http://example.com/url_without_brackets)
4175 http://example.com/url_with_entity
4176 http://example.com/url_with_entity 
4177 http://example.com/url_with_entity 
4178 http://example.com/url_with_entity<
4179 http://example.com/url_with_entity<
4180 http://example.com/url_with_entity<
4182 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>,
4183 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>;
4184 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>\
4185 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>.
4186 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>:
4187 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>!
4188 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>?
4189 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4190 <a rel="nofollow" class="external free" href="http://example.com/url_with_(brackets)">http://example.com/url_with_(brackets)</a>
4191 (<a rel="nofollow" class="external free" href="http://example.com/url_without_brackets">http://example.com/url_without_brackets</a>)
4192 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity ">http://example.com/url_with_entity </a>
4193 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity ">http://example.com/url_with_entity </a>
4194 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity ">http://example.com/url_with_entity </a>
4195 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><
4196 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity%3C">http://example.com/url_with_entity%3C</a>
4197 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity%3C">http://example.com/url_with_entity%3C</a>
4202 External links: No preceding word characters allowed (bug 65278)
4204 NOPEhttp://example.com
4205 N0http://example.com
4206 ok:http://example.com
4207 ok-http://example.com
4209 <p>NOPEhttp://example.com
4210 N0http://example.com
4211 ok:<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4212 ok-<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4219 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4221 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
4226 External image from https
4228 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4230 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
4235 External image (when not allowed)
4237 wgAllowExternalImages=0
4239 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4241 <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>
4246 Link to non-http image, no img tag
4248 Link to non-http image, no img tag: ftp://example.com/test.jpg
4250 <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>
4255 External links: terminating separator
4257 Terminating separator: http://example.com/thing,
4259 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
4264 External links: intervening separator
4266 Intervening separator: http://example.com/1,2,3
4268 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
4273 External links: old bug with URL in query
4275 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
4277 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
4282 External links: old URL-in-URL bug, mixed protocols
4284 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
4286 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
4291 External links: URL in text
4293 URL in text: [http://example.com http://example.com]
4295 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4300 External links: Clickable images
4302 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
4304 <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>
4309 External links: raw ampersand
4311 Old & use: http://x&y
4313 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
4318 External links: encoded ampersand
4320 Old & use: http://x&y
4322 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
4325 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y">http://x&y</a></p>
4329 External links: encoded equals (bug 6102)
4331 http://example.com/?foo=bar
4333 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
4336 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a></p>
4340 ## Note that parsoid doesn't explicit mark autonumbered links, nor
4341 ## does it number them. As discussed in bug 53505, we can identify
4342 ## autonumbered links via CSS.
4346 External links: [raw ampersand]
4348 Old & use: [http://x&y]
4350 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
4353 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
4356 # note that parsoid html is identical to [raw ampersand] case; so html2wt
4357 # mode will return the [raw ampersand] wikitext
4359 External links: [encoded ampersand]
4361 parsoid=wt2html,wt2wt,html2html
4363 Old & use: [http://x&y]
4365 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
4368 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
4372 External links: [raw equals]
4374 [http://example.com/?foo=bar]
4376 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
4379 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
4382 # note that parsoid html is identical to [raw equals] case; so html2wt
4383 # mode will return the [raw equals] wikitext
4385 External links: [encoded equals] (bug 6102)
4387 parsoid=wt2html,wt2wt,html2html
4389 [http://example.com/?foo=bar]
4391 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
4394 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
4397 # xxx parsoid strips the IDN character, so the round-trip tests will
4398 # obviously fail and are disabled. --cscott
4400 External links: [IDN ignored character reference in hostname; strip it right off]
4402 parsoid=wt2html,wt2wt,html2html
4404 [http://e‌xample.com/]
4406 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
4409 <p><a rel="mw:ExtLink" href="http://example.com/"></a></p>
4412 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
4413 # Where an external link could easily circumvent the sanitization of the text of
4414 # a link like this (where an IDN-ignore character is in the URL somewhere), this
4415 # test demands a higher standard. That's a bit strange.
4419 # http://example.com -> [http://example.com|http://example.com]
4420 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
4422 # The first example is sanitized, but the second is not. Any security benefits
4423 # from this production are trivial to circumvent. Either remove this test and
4424 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
4425 # the test accordingly.
4429 # xxx parsoid strips the IDN character, so the round-trip tests will
4430 # obviously fail and are disabled. --cscott
4432 External links: IDN ignored character reference in hostname; strip it right off
4434 parsoid=wt2html,html2html
4436 http://e‌xample.com/
4438 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
4441 <p><a rel="mw:ExtLink" href="http://example.com/">http://example.com/</a></p>
4445 External links: www.jpeg.org (bug 554)
4449 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
4453 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4455 External links: URL within URL (original bug 2)
4457 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
4459 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
4462 <p><a rel="mw:ExtLink" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp"></a></p>
4466 BUG 361: URL inside bracketed URL
4468 [http://www.example.com/foo http://www.example.com/bar]
4470 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
4475 BUG 361: URL within URL, not bracketed
4477 http://www.example.com/foo?=http://www.example.com/bar
4479 <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>
4484 BUG 289: ">"-token in URL-tail
4486 http://www.example.com/<hello>
4488 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
4493 BUG 289: literal ">"-token in URL-tail
4495 http://www.example.com/<b>html</b>
4497 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
4502 BUG 289: ">"-token in bracketed URL
4504 [http://www.example.com/<hello> stuff]
4506 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
4511 BUG 289: literal ">"-token in bracketed URL
4513 [http://www.example.com/<b>html</b> stuff]
4515 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
4520 BUG 289: literal double quote at end of URL
4522 http://www.example.com/"hello"
4524 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
4529 BUG 289: literal double quote in bracketed URL
4531 [http://www.example.com/"hello" stuff]
4533 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
4538 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
4540 [http://www.example.com test]
4542 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
4547 External links: link text with spaces
4549 [http://www.example.com a b c]
4550 [http://www.example.com ''a'' ''b'']
4552 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
4553 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
4558 External links: wiki links within external link (Bug 3695)
4560 [http://example.com [[wikilink]] embedded in ext link]
4562 <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>
4565 <p><a rel="mw:ExtLink" href="http://example.com"></a><a rel="mw:WikiLink" href="./Wikilink" title="Wikilink">wikilink</a><span> embedded in ext link</span></p>
4569 BUG 787: Links with one slash after the url protocol are invalid
4573 [http:/example.com title]
4575 <p>http:/example.com
4576 </p><p>[http:/example.com title]
4581 Bracketed external links with template-generated invalid target
4583 [{{echo|http:/example.com}} title]
4585 <p>[http:/example.com title]
4590 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
4592 ''[http://example.com text'']
4593 [http://example.com '''text]'''
4594 ''Something [http://example.com in italic'']
4595 ''Something [http://example.com mixed''''', even bold]'''
4596 '''''Now [http://example.com both''''']
4598 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
4599 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
4600 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
4601 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
4602 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
4608 Bug 4781: %26 in URL
4610 http://www.example.com/?title=AT%26T
4612 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
4615 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a></p>
4618 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
4619 # % is actually legal in HTML5. Any change in output would need testing though.
4621 Bug 4781, 5267: %25 in URL
4623 http://www.example.com/?title=100%25_Bran
4625 <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>
4628 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a></p>
4632 Bug 4781, 5267: %28, %29 in URL
4634 http://www.example.com/?title=Ben-Hur_%281959_film%29
4636 <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>
4639 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">http://www.example.com/?title=Ben-Hur_%281959_film%29</a></p>
4644 Bug 4781: %26 in autonumber URL
4646 [http://www.example.com/?title=AT%26T]
4648 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
4651 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T"></a></p>
4655 Bug 4781, 5267: %26 in autonumber URL
4657 [http://www.example.com/?title=100%25_Bran]
4659 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
4662 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran"></a></p>
4666 Bug 4781, 5267: %28, %29 in autonumber URL
4668 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
4670 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
4673 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29"></a></p>
4678 Bug 4781: %26 in bracketed URL
4680 [http://www.example.com/?title=AT%26T link]
4682 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
4685 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">link</a></p>
4689 Bug 4781, 5267: %25 in bracketed URL
4691 [http://www.example.com/?title=100%25_Bran link]
4693 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
4698 Bug 4781, 5267: %28, %29 in bracketed URL
4700 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
4702 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
4705 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a></p>
4709 External link containing a period in the anchor. (bug 63947)
4711 [//foo.org/bar#baz. bang]
4713 [//foo.org/bar. bang]
4715 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4716 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4719 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4720 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4724 External link containing a single quote. (bug 63947)
4728 [//foo.org/bar'baz bang]
4730 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4731 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4734 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4735 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4740 External link containing a period in the anchor. (bug 63947)
4742 [//foo.org/bar#baz. bang]
4744 [//foo.org/bar. bang]
4746 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4747 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4750 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4751 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4755 External link containing a single quote. (bug 63947)
4759 [//foo.org/bar'baz bang]
4761 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4762 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4765 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4766 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4771 External link containing double-single-quotes in text '' (bug 4598 sanity check)
4773 Some [http://example.com/ pretty ''italics'' and stuff]!
4775 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
4780 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
4782 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
4784 <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>
4789 External link containing double-single-quotes with no space separating the url from text in italics
4791 [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]].]
4793 <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>
4796 <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> <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>.</p>
4798 <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)" title="Museo Picasso (París)">Museo Picasso</a><span>.</span></p>
4802 External link with comments in link text
4804 [http://www.google.com Google <!-- comment -->]
4806 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
4811 URL-encoding in URL functions (single parameter)
4813 {{localurl:Some page|amp=&}}
4815 <p>/index.php?title=Some_page&amp=&
4820 URL-encoding in URL functions (multiple parameters)
4822 {{localurl:Some page|q=?&=&}}
4824 <p>/index.php?title=Some_page&q=?&amp=&
4831 http://example.com/index.php?foozoid%5B%5D=bar
4833 http://example.com/index.php?foozoid[]=bar
4835 <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>
4836 </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>
4839 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a></p>
4841 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid[]=bar">http://example.com/index.php?foozoid[]=bar</a></p>
4845 IPv6 urls (bug 21261)
4849 http://[2404:130:0:1000::187:2]/index.php
4851 <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>
4856 Non-extlinks in brackets
4865 [{{echo|foo}} ''bar'']
4866 [{{echo|foo}}l's] errand
4867 [{{echo|foo}}l's errand]
4869 [url=http://example.com]
4882 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
4887 Percent encoding in external links
4889 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
4891 <p><a rel="nofollow" class="external text" href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a>
4894 <p><a rel="mw:ExtLink"
4895 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
4899 Use url link syntax for links where the content is equal the link target
4903 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4906 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
4910 Parenthesis in external links, especially URL links
4914 http://example.com/test)
4916 http://example.com/(test)
4918 http://example.com/((test)
4920 (http://example.com/(test))
4922 (http://example.com/(test)))))
4924 http://example.com/a)b
4926 [http://example.com) foo]
4928 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4929 </p><p><a rel="nofollow" class="external free" href="http://example.com/test">http://example.com/test</a>)
4930 </p><p><a rel="nofollow" class="external free" href="http://example.com/(test)">http://example.com/(test)</a>
4931 </p><p><a rel="nofollow" class="external free" href="http://example.com/((test)">http://example.com/((test)</a>
4932 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test))">http://example.com/(test))</a>
4933 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test)))))">http://example.com/(test)))))</a>
4934 </p><p><a rel="nofollow" class="external free" href="http://example.com/a)b">http://example.com/a)b</a>
4935 </p><p><a rel="nofollow" class="external text" href="http://example.com)">foo</a>
4938 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)</p>
4939 <p><a rel="mw:ExtLink" href="http://example.com/test">http://example.com/test</a>)</p>
4940 <p><a rel="mw:ExtLink" href="http://example.com/(test)">http://example.com/(test)</a></p>
4941 <p><a rel="mw:ExtLink" href="http://example.com/((test)">http://example.com/((test)</a></p>
4942 <p>(<a rel="mw:ExtLink" href="http://example.com/(test))">http://example.com/(test))</a></p>
4943 <p>(<a rel="mw:ExtLink" href="http://example.com/(test)))))">http://example.com/(test)))))</a></p>
4944 <p><a rel="mw:ExtLink" href="http://example.com/a)b">http://example.com/a)b</a></p>
4945 <p><a rel="mw:ExtLink" href="http://example.com)">foo</a></p>
4949 Parenthesis in external links, w/ transclusion or comment
4951 (http://example.com/{{echo|hi}})
4953 (http://example.com<!-- hi -->)
4955 <p>(<a rel="nofollow" class="external free" href="http://example.com/hi">http://example.com/hi</a>)
4956 </p><p>(<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4959 <p>(<a 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}}"}}' data-mw='{"attribs":[[{"txt":"href"},{"html":"http://example.com/<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=\"{&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]],&quot;dsr&quot;:[20,31,null,null]}\" 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}}]}\">hi</span>"}]]}'>http://example.com/hi</a>)</p>
4961 <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>
4965 Replace invalid link targets when serializing
4969 <a rel="mw:WikiLink" href="./]] foo [[bar">Manual</a>
4971 [[MediaWiki:Badtitletext|Manual]]
4981 Normal text. '''Bold text.''' Normal text. ''Italic text.''
4983 Normal text. '''''Bold italic text.''''' Normal text.
4985 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
4986 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
4991 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
4992 # parser strips. The wikitext contains just the first half of the bold
4995 Unclosed and unmatched quotes
4997 '''''Bold italic text '''with bold deactivated''' in between.'''''
4999 '''''Bold italic text ''with italic deactivated'' in between.'''''
5003 ..spanning two paragraphs (should not work).'''
5005 '''Bold tag left open
5007 ''Italic tag left open
5011 <!-- Unmatching number of opening, closing tags: -->
5012 '''This year''''s election ''should'' beat '''last year''''s.
5014 ''Tom'''s car is bigger than ''Susan'''s.
5016 Plain ''italic'''s plain
5018 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
5019 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
5020 </p><p><b>Bold text..</b>
5021 </p><p>..spanning two paragraphs (should not work).
5022 </p><p><b>Bold tag left open</b>
5023 </p><p><i>Italic tag left open</i>
5025 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
5026 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
5027 </p><p>Plain <i>italic'</i>s plain
5030 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
5031 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
5032 </p><p><b>Bold text..</b>
5033 </p><p>..spanning two paragraphs (should not work).<b></b>
5034 </p><p><b>Bold tag left open</b>
5035 </p><p><i>Italic tag left open</i>
5037 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
5038 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
5039 </p><p>Plain <i>italic'</i>s plain
5046 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
5049 # This should not produce <table></table> as <table><tr><td></td></tr></table>
5050 # is the bare minimum required by the spec, see:
5051 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
5052 # Parsoid team replies: empty table tags are legal in HTML5
5054 A table with no data.
5067 A table with stray table end tags on start tag line (wt2html)
5071 {|style="color: red;"|}
5073 {|style="color: red;" |}
5077 {|style="color: red;"|} id="foo"
5081 {|style="color: red;" |} id="foo"
5085 <table style="color: red;"></table>
5087 <table style="color: red;">
5093 <table style="color: red;" id="foo">
5099 <table style="color: red;" id="foo">
5108 A table with no data (take 2)
5116 # A table with nothing but a caption is invalid XHTML, we might want to render
5117 # this as <p>caption</p>
5118 # Parsoid team replies: table with only a caption is legal in HTML5
5120 A table with nothing but a caption
5128 </caption><tr><td></td></tr></table>
5131 <table><caption> caption</caption></table>
5135 A table with caption with default-spaced attributes and a table row
5138 |+ style="color: red;" | caption1
5144 <caption style="color: red;"> caption1
5153 A table with captions with non-default spaced attributes and a table row
5156 |+style="color: red;"|caption2
5157 |+ style="color: red;"| caption3
5163 <caption style="color: red;">caption2
5165 <caption style="color: red;"> caption3
5174 Table td-cell syntax variations
5178 | foo bar foo || baz
5179 | style='color:red;' | baz
5180 | style='color:red;' || baz
5187 <td> foo bar foo </td>
5190 <td style="color:red;"> baz
5192 <td> style='color:red;' </td>
5220 Simple table but with multiple dashes for row wikitext
5238 Multiplication table
5240 {| border="1" cellpadding="2"
5241 |+Multiplication table
5243 ! × !! 1 !! 2 !! 3
5261 <table border="1" cellpadding="2">
5262 <caption>Multiplication table
5309 Accept "||" in table headings
5324 Accept "!!" in table data
5338 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'> Foo!! </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'></td></tr>
5343 Accept "||" in indented table headings
5353 </th></tr></table></dd></dl>
5358 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
5375 Accept "| !" at start of line in tables (ignore !-attribute)
5379 | !style="color:red" | bar
5391 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 +/-
5395 |style='color:red;'|+1
5396 |style='color:blue;'|-1
5408 <td style="color:red;">+1
5410 <td style="color:blue;">-1
5434 |rowspan=2| Cell 2, row 1 (and 2)
5445 <td rowspan="2"> Cell 2, row 1 (and 2)
5463 {| bgcolor=#ABCDEF border=2
5468 |the original table again
5476 <table bgcolor="#ABCDEF" border="2">
5484 <td>the original table again
5490 Invalid attributes in table cell (bug 1830)
5504 # The "|}" to close the table is missing from the input, so parsoid's
5505 # *2wt modes will fail.
5507 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
5509 parsoid=wt2html,html2html
5512 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
5516 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
5517 <td>]" onmouseover="alert(document.cookie)">test
5525 <td><a rel="mw:ExtLink" href="ftp://|x||"></a>" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
5530 Indented table markup mixed with indented pre content (proposed in bug 6200)
5535 Text that should be rendered preformatted
5543 <pre>Text that should be rendered preformatted
5552 Template-generated table cell attributes and cell content
5557 | <!--foo--> <!--bar--> <!--baz--> {{table_attribs}}
5558 |align=center {{table_attribs}}
5559 | <!--foo--> align=center <!--bar--> {{table_attribs}}
5564 <td style="color: red"> Foo
5566 <td style="color: red"> Foo
5568 <td style="color: red"> Foo
5570 <td align="center" style="color: red"> Foo
5572 <td align="center" style="color: red"> Foo
5578 Template-generated table cell attributes and cell content (2)
5581 |align=center {{table_cells}}
5586 <td align="center" style="color: red"> Foo </td>
5594 Table with row followed by newlines and table heading
5612 Table with empty line following the start tag
5629 # FIXME: Preserve the attribute properly (with an empty string as value) in
5630 # the PHP parser. Parsoid implements the behavior below.
5632 Table attributes with empty value
5642 </td></tr></tbody></table>
5647 Wikitext table with a lot of comments
5670 Wikitext table with double-line table cell
5687 Table cell with a single comment
5704 Table-cell after a comment-only-empty-line
5721 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>a</td>
5723 <!--c2--><td data-parsoid='{"autoInsertedEnd":true}'> b</td></tr>
5729 Build table with {{!}}
5731 {{{!}} class="wikitable"
5734 {{!}}- style="color:red;"
5735 {{!}} data {{!}}{{!}} style="color:red;" {{!}} second data
5738 <table class="wikitable">
5744 <tr style="color:red;">
5746 <td style="color:red;"> second data
5752 Build table with pipe as data
5754 {| class="wikitable"
5757 |- style="color:red;"
5758 | data || style="color:red;" | second data
5760 | style="color:red;" | data with | || style="color:red;" | second data with |
5762 || data with | ||| second data with |
5765 <table class="wikitable">
5771 <tr style="color:red;">
5773 <td style="color:red;"> second data
5776 <td style="color:red;"> data with | </td>
5777 <td style="color:red;"> second data with |
5780 <td> data with | </td>
5781 <td> second data with |
5787 Build table with wikilink
5789 {| class="wikitable"
5790 ! header || second header
5791 |- style="color:red;"
5792 | data [[Main Page|linktext]] || second data [[Main Page|linktext]]
5794 | data || second data [[Main Page|link|text with pipe]]
5797 <table class="wikitable">
5802 <tr style="color:red;">
5803 <td> data <a href="/wiki/Main_Page" title="Main Page">linktext</a> </td>
5804 <td> second data <a href="/wiki/Main_Page" title="Main Page">linktext</a>
5808 <td> second data <a href="/wiki/Main_Page" title="Main Page">link|text with pipe</a>
5813 # The expected HTML structure in this test is debatable. The PHP parser does
5814 # not parse this kind of table at all. The main focus for Parsoid is on
5815 # round-tripping, so this output is ok for now. TODO: revisit!
5817 Wikitext table with html-syntax row
5827 <td>foo</td></tr></tbody></table>
5830 ## Note that Parsoid output differs from PHP and PHP+tidy here.
5831 ## The lack of <tr> tags in the PHP output is arguably a bug in the
5832 ## PHP parser, which tidy then compounds by fostering the content
5833 ## entirely out of the table. Parsoid recognizes the table context
5834 ## and generates <tr> and <td> wrappers as needed. Hopefully nobody
5835 ## depends on PHP's treatment of broken table markup!
5837 Implicit <td> after a |-
5839 parsoid=wt2html,html2html
5859 # Again, Parsoid adds implicit <td>s here, PHP and Tidy strip the b out.
5861 <pre> tags should be recognized in an explicit <td> context, but not in an implicit <td> context
5863 parsoid=wt2html,html2html
5896 <tr><td><pre>a</pre></td></tr>
5897 <tr><td> b</td></tr>
5902 # PHP + Tidy strips the list out of the table; Parsoid wraps it.
5903 # Parsoid generates the missing <td>, so wt2wt won't succeed.
5905 Lists should be recognized in an implicit <td> context
5907 parsoid=wt2html,html2html
5934 Parsoid: Round-trip tables directly followed by content (bug 51219)
5936 parsoid=wt2html,wt2wt
5961 Parsoid: Default to a newline after tables in new content (bug 51219)
5968 <nowiki> </nowiki>bar
5975 <tr><td>foo</td></tr></tbody></table> bar
5977 <tr><td>baz</td></tr></tbody></table><b>quux</b>
5981 Parsoid: newline inducing block nodes don't suppress <nowiki>
5993 Parsoid: Row-syntax table headings followed by comment & table cells
5995 parsoid=wt2html,wt2wt
5999 <!-- foo --> || baz || quux
6013 <tbody><tr><th> foo </th><th> bar
6014 <!-- foo --> </th><td> baz </td><td> quux</td></tr>
6019 # PHP throws away the (semi-broken) "foo" class here; Parsoid
6022 Parsoid: Recover better from broken table attributes
6042 <p>foo</p></td></tr>
6047 Strip unsupported table tags
6098 Plain link, capitalized
6102 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6107 Plain link, uncapitalized
6111 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
6118 [[Main Page|The Main Page]]
6120 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
6125 Piped link with comment in link text
6127 [[Main Page|The Main<!--front--> Page]]
6129 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
6134 Piped link with multiple pipe characters in link text
6136 [[Main Page||The|Main|Page|]]
6138 <p><a href="/wiki/Main_Page" title="Main Page">|The|Main|Page|</a>
6141 <p><a rel="mw:WikiLink" href="Main_Page" title="Main Page">|The|Main|Page|</a></p>
6149 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
6154 Broken link with fragment
6156 [[Zigzagzogzagzig#zug]]
6158 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
6163 Special page link with fragment
6165 [[Special:Version#anchor]]
6167 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
6172 Nonexistent special page link with fragment
6174 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
6176 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
6183 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
6185 <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>
6192 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
6194 <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>!!!
6205 Bug 43661: Piped links with identical prefixes
6207 [[prefixed article|prefixed articles with spaces]]
6209 [[prefixed article|prefixed articlesaoeu]]
6211 [[Main Page|Main Page test]]
6213 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
6214 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
6215 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
6221 Link with HTML entity in suffix / tail
6223 [[Main Page]]", [[Main Page]]a
6225 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
6230 Link with 3 brackets
6239 Link with 4 brackets
6243 <p>[[<a href="/wiki/Main_Page" title="Main Page">Main Page</a>]]
6248 Piped link with 3 brackets
6250 [[[main page|the main page]]]
6252 <p>[[[main page|the main page]]]
6257 Piped link with extlink-like text
6260 [[Main Page|This is a [bar]]]
6262 <p><a href="/wiki/Main_Page" title="Main Page">[bar]</a>
6263 <a href="/wiki/Main_Page" title="Main Page">This is a [bar]</a>
6268 Link with multiple pipes
6270 [[Main Page|The|Main|Page]]
6272 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
6276 # Note that parsoid does not munge anchor text; all non-space
6277 # characters are valid in HTML5 ids.
6279 Anchor containing a #. (bug 63430)
6281 [[Main Page#And#Link]]
6283 <p><a href="/wiki/Main_Page#And.23Link" title="Main Page">Main Page#And#Link</a>
6286 <p><a rel="mw:WikiLink" href="./Main_Page#And%23Link" title="Main Page">Main Page#And#Link</a></p>
6292 [[Talk:Parser testing]], [[Meta:Disclaimers]]
6294 <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>
6299 Link with space in namespace
6301 [[User talk:Foo bar]]
6303 <p><a href="/index.php?title=User_talk:Foo_bar&action=edit&redlink=1" class="new" title="User talk:Foo bar (page does not exist)">User talk:Foo bar</a>
6308 MemoryAlpha:AlphaTest
6310 This is an article in the MemoryAlpha namespace
6311 (which shadows the memoryalpha interwiki link).
6315 Namespace takes precedence over interwiki link (bug 51680)
6317 [[MemoryAlpha:AlphaTest]]
6319 <p><a href="/wiki/MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
6323 # The previous test doesn't work correctly in html2*, due to not recognizing the
6324 # link as an internal one. This one checks for the correct behavior.
6326 Link to namespace preferred over interwiki with correct rel attribute
6328 parsoid=html2wt,html2html
6330 [[MemoryAlpha:AlphaTest]]
6332 <p><a rel="mw:WikiLink" href="./MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
6337 Piped link to namespace
6339 [[Meta:Disclaimers|The disclaimers]]
6341 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
6348 [[Usually caused by a typo (oops}]]
6350 <p>[[Usually caused by a typo (oops}]]
6357 Just a test of an article title containing a percent.
6361 Link containing % (not as a hex sequence)
6365 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
6368 <p><a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7% Solution</a></p>
6371 # note that the parsoid HTML is identical to the previous test output,
6372 # so the previous test ensures that the html2wt mode will generate the
6373 # "not as a hex sequence" wikitext.
6375 Link containing % as a single hex sequence interpreted to char
6377 parsoid=wt2wt,wt2html,html2html
6381 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
6384 <p><a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7% Solution</a></p>
6388 Link containing % as a double hex sequence interpreted to hex sequence
6392 <p>[[7%2525 Solution]]
6396 # note that parsoid does not munge anchor text; all non-space
6397 # characters are valid in HTML5 anchors.
6399 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
6400 Example for such a section: == < ==
6402 [[%23%3c]][[%23%3e]]
6404 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
6407 <p><a rel="mw:WikiLink" href="./Main%20Page#%3C" title="Main Page">#<</a><a rel="mw:WikiLink" href="./Main%20Page#%3E" title="Main Page">#></a></p>
6411 Link containing "<#" and ">#" as a hex sequences
6413 [[%3c%23]][[%3e%23]]
6415 <p>[[%3c%23]][[%3e%23]]
6420 Link containing an equals sign
6422 [[Special:BookSources/isbn=4-00-026157-6]]
6424 <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>
6427 <p><a rel="mw:WikiLink" href="./Special:BookSources/isbn=4-00-026157-6" title="Special:BookSources/isbn=4-00-026157-6">Special:BookSources/isbn=4-00-026157-6</a></p>
6433 Just a test of an article title containing a tilde.
6436 # note that links containing signatures, like [[Foo~~~~]], are
6437 # massaged by the pre-save transform (PST) and so the tildes are never
6438 # seen by the parser.
6440 Link containing a tilde
6444 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
6447 <p><a rel="mw:WikiLink" href="./Foo~bar" title="Foo~bar">Foo~bar</a></p>
6451 Link containing double-single-quotes '' (bug 4598)
6453 [[Lista d''e paise d''o munno]]
6455 <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>
6458 <p><a rel="mw:WikiLink" href="./Lista_d''e_paise_d''o_munno" title="Lista d''e paise d''o munno">Lista d''e paise d''o munno</a></p>
6462 Link containing double-single-quotes '' in text (bug 4598 sanity check)
6464 Some [[Link|pretty ''italics'' and stuff]]!
6466 <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>!
6469 <p>Some <a rel="mw:WikiLink" href="Link" title="Link">pretty <i>italics</i> and stuff</a>!</p>
6473 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
6475 ''Some [[Link|pretty ''italics'' and stuff]]!''
6477 <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>
6482 Link with double quotes in title part (literal) and alternate part (interpreted)
6484 [[File:Denys_Savchenko_''Pentecoste''.jpg]]
6488 [[''Pentecoste''|Pentecoste]]
6490 [[''Pentecoste''|''Pentecoste'']]
6492 <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>
6493 </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>
6494 </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>
6495 </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>
6498 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Denys_Savchenko_''Pentecoste''.jpg"><img resource="./File:Denys_Savchenko_''Pentecoste''.jpg" src="./Special:FilePath/Denys_Savchenko_''Pentecoste''.jpg" height="220" width="220"/></a></span></p>
6499 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">''Pentecoste''</a></p>
6500 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">Pentecoste</a></p>
6501 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''"><i>Pentecoste</i></a></p>
6505 Broken image links with HTML captions (bug 39700)
6507 [[File:Nonexistent|<script></script>]]
6508 [[File:Nonexistent|100x100px|<script></script>]]
6509 [[File:Nonexistent|<]]
6510 [[File:Nonexistent|a<i>b</i>c]]
6512 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
6513 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
6514 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
6515 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
6518 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"<script></script>"}'><a href="./File:Nonexistent"><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="220" width="220"/></a></span>
6519 <span typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"<script></script>"}'><a href="./File:Nonexistent" data-parsoid='{"a":{"href":"./File:Nonexistent"},"sa":{}}'><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="100" width="100"/></a></span>
6520 <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"&lt;"}'><a href="./File:Nonexistent"><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="220" width="220"/></a></span>
6521 <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"a<i>b</i>c"}'><a href="./File:Nonexistent"><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="220" width="220"/></a></span></p>
6527 [[http://www.example.com]]
6529 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
6532 <p>[<a rel="mw:ExtLink" href="http://www.example.com"></a>]</p>
6536 Plain link to URL with link text
6538 [[http://www.example.com Link text]]
6540 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
6545 Plain link to protocol-relative URL
6547 [[//www.example.com]]
6549 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
6552 <p>[<a rel="mw:ExtLink" href="//www.example.com"></a>]</p>
6556 Plain link to protocol-relative URL with link text
6558 [[//www.example.com Link text]]
6560 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
6565 Plain link to page with question mark in title
6571 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
6572 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
6577 # I'm fairly sure the expected result here is wrong.
6578 # We want these to be URL links, not pseudo-pages with URLs for titles....
6579 # However the current output is also pretty screwy.
6582 # I'm changing it to match the current output--it arguably makes more
6583 # sense in the light of the test above. Old expected result was:
6584 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
6586 # But I think this test is bordering on "garbage in, garbage out" anyway.
6591 Piped link to URL: [[http://www.example.com|an example URL]]
6593 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
6596 <p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com|an">example URL</a>]</p>
6600 BUG 2: [[page|http://url/]] should link to page, not http://url/
6602 [[Main Page|http://url/]]
6604 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
6607 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">http://url/</a></p>
6610 # Parsoid does not mark self-links, by design.
6612 BUG 337: Escaped self-links should be bold
6616 [[Bug462]] [[Bug462]]
6618 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
6621 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong></p>
6623 <p><a rel="mw:WikiLink" href="./Bug462" title="Bug462">Bug462</a> <a rel="mw:WikiLink" href="./Bug462" title="Bug462">Bug462</a></p>
6627 Self-link to section should not be bold
6631 [[Main Page#section]]
6633 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
6644 Self-link to numeric title
6650 <p><strong class="selflink">0</strong>
6655 Link to numeric-equivalent title
6661 <p><a href="/wiki/00" title="00">00</a>
6666 <nowiki> inside a link
6668 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
6670 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
6675 Non-breaking spaces in title
6677 [[ Main Page ]]
6679 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
6684 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
6690 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
6695 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
6701 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
6706 Internal link with en linktrail: no apostrophes (bug 27473)
6712 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
6717 Internal link with ca linktrail with apostrophes (bug 27473)
6723 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
6728 Internal link with kaa linktrail with apostrophes (bug 27473)
6734 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
6739 Link with multiple ":" in a subpage-supporting namespace (bug 63636)
6741 [[User:Foo/Test/63636:Bar|Test]]
6743 <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>
6746 <p><a rel="mw:WikiLink" href="./User:Foo/Test/63636:Bar" title="User:Foo/Test/63636:Bar">Test</a></p>
6750 Purely hash wikilink
6752 title=[[User:test/123]]
6756 <p><a href="#a">b</a>
6759 <p><a rel="mw:WikiLink" href="../User:Test/123#a" data-parsoid='{"stx":"piped","a":{"href":"../User:Test/123#a"},"sa":{"href":"#a"}}'>b</a></p>
6763 1. Interaction of linktrail and template encapsulation
6769 <p><a rel="mw:WikiLink" href="Foo" title="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
6773 2. Interaction of linktrail and template encapsulation
6777 {{echo|Some [[Fool]]}}s
6779 <p><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" title="Fool" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a></p>
6783 3. Interaction of linktrail and template encapsulation
6787 {{echo|Some [[Fool]]s are '''bold and foolish'''}}
6789 <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" title="Fool" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a> are <b>bold and foolish</b></p>
6799 Internal link with is link prefix
6803 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
6805 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
6816 Internal link with is link trail and link prefix
6820 [[mótmælendatrú|xxx]]ar
6822 mótmælenda[[söfnuður]]
6823 mótmælenda[[söfnuður|söfnuðir]]
6824 mótmælenda[[söfnuður|söfnuðir]]xxx
6826 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
6827 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
6828 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
6829 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
6830 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
6835 Parsoid link trail escaping
6837 parsoid=html2wt,html2html
6841 <p><a rel="mw:WikiLink" href="Apple" title="Apple">apple</a>s</p>
6845 Parsoid link prefix escaping
6848 parsoid=html2wt,html2html
6850 Aðrir mótmælenda<nowiki/>[[söfnuður]]
6852 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður" title="Söfnuður">söfnuður</a></p>
6856 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
6864 [http://wp.org ''foo'']
6866 <p><a href="/wiki/Foo" title="Foo"> bar</a>
6867 </p><p><a href="/wiki/Foo" title="Foo"> <i>bar</i></a>
6868 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
6869 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
6874 Parsoid: Scoped parsing should handle mixed transclusions and plain text
6878 [[Foo|{{echo|a}} b {{echo|c}}]]
6880 <p><a rel="mw:WikiLink" href="Foo" title="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>
6884 Link with angle bracket after anchor
6888 <p><a href="/wiki/Foo#.3Cbar.3E" title="Foo">Foo#<bar></a>
6891 <p><a rel="mw:WikiLink" href="./Foo#%3Cbar%3E" title="Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo#%3Cbar%3E"},"sa":{"href":"Foo#<bar>"}}'>Foo#<bar></a></p>
6895 ### Interwiki links (see maintenance/interwiki.sql)
6899 Inline interwiki link
6901 parsoid=wt2html,wt2wt,html2html
6903 [[MeatBall:SoftSecurity]]
6905 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
6908 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a></p>
6912 Inline interwiki link with empty title (bug 2372)
6914 parsoid=wt2html,wt2wt,html2html
6918 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
6921 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?" title="meatball:">MeatBall:</a></p>
6925 Interwiki link encoding conversion (bug 1636)
6927 *[[Wikipedia:ro:Olteniţa]]
6928 *[[Wikipedia:ro:Olteniţa]]
6930 <ul><li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a></li>
6931 <li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a></li></ul>
6935 <li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a></li>
6936 <li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a></li>
6941 Interwiki link with fragment (bug 2130)
6943 [[MeatBall:SoftSecurity#foo]]
6945 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
6949 # Ideally the wikipedia: prefix here should be proto-relative too
6950 # [CSA]: this is kind of a bogus test, as the PHP parser test doesn't
6951 # define the 'en' prefix, and originally the test used 'wikipedia',
6952 # which isn't a localinterwiki prefix hence the links to the 'en:Foo'
6955 Different interwiki prefixes mapping to the same URL
6963 [[:wikipedia:Foo|Foo]]
6965 [[wikipedia:en:Foo]]
6967 [[:wikipedia:en:Foo]]
6971 <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}' title="en:Foo">en:Foo</a></p>
6973 <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}' title="en:Foo">Foo</a></p>
6975 <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}' title="wikipedia:Foo">wikipedia:Foo</a></p>
6977 <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}' title="wikipedia:Foo">Foo</a></p>
6979 <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}' title="wikipedia:en:Foo">wikipedia:en:Foo</a></p>
6981 <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}' title="wikipedia:en:Foo">wikipedia:en:Foo</a></p>
6983 <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}' title="wikipedia:Foo"> wikiPEdia :Foo</a></p>
6987 Interwiki links that cannot be represented in wiki syntax
6990 [[meatball:ok#foo|ok with fragment]]
6991 [[meatball:ok_as_well?|ok ending with ? mark]]
6992 [http://de.wikipedia.org/wiki/Foo?action=history has query]
6993 [http://de.wikipedia.org/wiki/#foo is just fragment]
6996 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?ok" class="extiw" title="meatball:ok">meatball:ok</a>
6997 <a href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo" class="extiw" title="meatball:ok">ok with fragment</a>
6998 <a href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well%3F" class="extiw" title="meatball:ok as well?">ok ending with ? mark</a>
6999 <a rel="nofollow" class="external text" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
7000 <a rel="nofollow" class="external text" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a>
7003 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok" title="meatball:ok">meatball:ok</a>
7004 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo" title="meatball:ok">ok with fragment</a>
7005 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well?" title="meatball:ok as well?">ok ending with ? mark</a>
7006 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
7007 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a></p>
7011 Interwiki links: trail
7013 [[wikipedia:Foo|Ba]]r
7015 <p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo">Bar</a>
7018 <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,"tail":"r"}' title="wikipedia:Foo">Bar</a></p>
7022 Local interwiki link
7024 parsoid=wt2html,wt2wt,html2html
7026 [[local:Template:Foo]]
7028 <p><a href="/wiki/Template:Foo" title="Template:Foo">local:Template:Foo</a>
7031 <p><a rel="mw:WikiLink" href="./Template:Foo" title="Template:Foo">local:Template:Foo</a></p>
7034 # Parsoid does not mark self-links, by design.
7036 Local interwiki link: self-link to current page
7039 parsoid=wt2html,wt2wt,html2html
7043 <p><strong class="selflink">local:Main Page</strong>
7046 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">local:Main Page</a></p>
7050 Local interwiki link: prefix only (bug 64167)
7052 parsoid=wt2html,wt2wt,html2html
7056 <p><a href="/wiki/Main_Page" title="Main Page">local:</a>
7059 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">local:</a></p>
7063 Local interwiki link: with additional interwiki prefix (bug 61357)
7065 parsoid=wt2html,wt2wt,html2html
7067 [[local:meatball:Hello]]
7069 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?Hello" class="extiw" title="meatball:Hello">local:meatball:Hello</a>
7072 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?Hello" title="meatball:Hello">local:meatball:Hello</a></p>
7076 Multiple local interwiki link prefixes
7078 [[local:local:local:local:mi:local:Foo]]
7080 parsoid=wt2html,wt2wt,html2html
7082 <p><a href="/wiki/Foo" title="Foo">local:local:local:local:mi:local:Foo</a>
7085 <p><a rel="mw:WikiLink" href="./Foo" title="Foo">local:local:local:local:mi:local:Foo</a></p>
7089 ### Interlanguage links
7090 ### Language links (so that searching for '### language' matches..)
7096 parsoid=wt2html,wt2wt,html2html
7104 <p>Blah blah blah</p>
7105 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7109 Interlanguage link with spacing
7111 parsoid=wt2html,wt2wt,html2html
7119 <p>Blah blah blah</p>
7120 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7124 Double interlanguage link
7126 parsoid=wt2html,wt2wt,html2html
7135 <p>Blah blah blah</p>
7136 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish"/>
7137 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7141 Interlanguage link variations
7143 parsoid=wt2html,wt2wt,html2html
7154 <p>Blah blah blah</p>
7155 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish" />
7156 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese" />
7157 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Foo_bar" />
7158 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Foo_bar" />
7162 Interlanguage link, with prefix links
7172 <p>Blah blah blah</p>
7173 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7177 Double interlanguage link, with prefix links (bug 8897)
7188 <p>Blah blah blah</p>
7189 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish"/>
7190 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7194 "Extra" interlanguage links (bug 32189 / gerrit 111390)
7202 <p>Blah blah blah</p>
7203 <link rel="mw:PageProp/Language" title="Multilingual" href="http://wikisource.org/wiki/Article"/>
7207 Parsoid-specific test: Wikilinks with should RT properly
7213 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
7218 Parsoid bug 53221: Wikilinks should be properly entity-escaped
7222 He&nbsp;llo [[Foo|He&nbsp;llo]]
7224 He&nbsp;llo [[He&nbsp;llo]]
7226 <p>He&nbsp;llo <a href="Foo" rel="mw:WikiLink">He&nbsp;llo</a></p>
7227 <p>He&nbsp;llo <a href="He&nbsp;llo" rel="mw:WikiLink">He&nbsp;llo</a></p>
7231 Parsoid: handle constructor well
7237 <p><a href="/index.php?title=Constructor&action=edit&redlink=1" class="new" title="Constructor (page does not exist)">constructor</a>
7238 </p><p><a href="/index.php?title=Constructor:foo&action=edit&redlink=1" class="new" title="Constructor:foo (page does not exist)">constructor:foo</a>
7241 <p><a rel="mw:WikiLink" href="./Constructor" title="Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"}}">constructor</a></p>
7243 <p><a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"}}">constructor:foo</a></p>
7252 # Note that `ko` isn't a known interlanguage prefix
7254 Parsoid: recognize interlanguage links without a target page
7264 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/"/>
7266 <p><a rel="mw:WikiLink" href="./Ko:" title="Ko:">ko:</a></p>
7269 # Note that `ko` isn't a known interwiki prefix
7271 Parsoid: recognize interwiki links without a target page
7273 parsoid=wt2html,wt2wt,html2html
7279 <p><a href="http://es.wikipedia.org/wiki/" class="extiw" title="es:">es:</a>
7280 </p><p><a href="/wiki/Ko:" title="Ko:">ko:</a>
7283 <p><a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/" title="es:">es:</a></p>
7284 <p><a rel="mw:WikiLink" href="./Ko:" title="Ko:">ko:</a></p>
7288 Handle interwiki links pointing to the current wiki as plain wiki links (bug 45209)
7292 <p><a href="/wiki/Foo" title="Foo">mi:Foo</a>
7295 <p><a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"mi:Foo"}}'>mi:Foo</a></p>
7299 Interlanguage link with preceding local interwiki link (bug 68085)
7301 parsoid=wt2html,wt2wt,html2html
7304 [[local:es:Spanish]]
7307 <a href="http://es.wikipedia.org/wiki/Spanish" class="extiw" title="es:Spanish">local:es:Spanish</a>
7311 <a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/Spanish" title="es:Spanish">local:es:Spanish</a></p>
7315 Looks like an interlanguage link, but is actually a local interwiki
7317 parsoid=wt2html,wt2wt,html2html
7323 <a href="/wiki/Template:Foo" title="Template:Foo">mi:Template:Foo</a>
7327 <a rel="mw:WikiLink" href="Template:Foo" title="Template:Foo">mi:Template:Foo</a></p>
7331 ### Redirects, Parsoid-only
7334 1. Simple redirect to page
7338 #REDIRECT [[Main Page]]
7340 <link rel="mw:PageProp/redirect" href="./Main_Page">
7343 # Only wt2html and html2html since "Main_Page" will serialize to "Main Page"
7345 2. Other redirect variants
7347 parsoid=wt2html,wt2wt
7349 #REDIRECT [[Main_Page]]
7350 #REDIRECT [[<nowiki>[[Bar]]</nowiki>]]
7352 <link rel="mw:PageProp/redirect" href="./Main_Page"><link rel="mw:PageProp/redirect" href="./%5B%5BBar%5D%5D">
7358 parsoid=wt2html,wt2wt
7363 <li>REDIRECT [[]]</li></ol>
7367 Optional colon in #REDIRECT
7369 # the colon is archaic syntax. we support it for wt2html, but we
7370 # don't care that it roundtrips back to the modern syntax.
7371 parsoid=wt2html,html2html
7373 #REDIRECT:[[Main Page]]
7375 <link rel="mw:PageProp/redirect" href="./Main_Page">
7379 Whitespace in #REDIRECT with optional colon
7381 # the colon and gratuitous whitespace is archaic syntax. we support
7382 # it for wt2html, but we don't care that it roundtrips back to the
7383 # modern syntax (without extra whitespace)
7384 parsoid=wt2html,html2html
7391 <link rel="mw:PageProp/redirect" href="./Main_Page">
7395 Piped link in #REDIRECT
7397 # content after piped link is ignored. we support this syntax,
7398 # but don't care that the piped link is lost when we roundtrip this.
7401 #REDIRECT [[Main Page|bar]]
7403 <link rel="mw:PageProp/redirect" href="./Main_Page">
7407 Redirect to category
7411 #REDIRECT [[Category:Foo]]
7413 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
7417 Redirect to category with URL encoding
7421 #REDIRECT [[Category%3AFoo]]
7423 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
7427 Redirect to category page
7429 parsoid=wt2html,html2html
7431 #REDIRECT [[:Category:Foo]]
7433 <p><a rel="mw:WikiLink" href="Category:Foo" title="Category:Foo">Category:Foo</a></p>
7437 Redirect to image page (1)
7441 #REDIRECT [[File:Wiki.png]]
7443 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
7447 Redirect to image page (2)
7451 #REDIRECT [[Image:Wiki.png]]
7453 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
7457 Redirect to language
7461 #REDIRECT [[en:File:Wiki.png]]
7463 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
7467 Redirect to interwiki
7471 #REDIRECT [[meatball:File:Wiki.png]]
7473 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
7477 Non-English #REDIRECT
7482 #TILVÍSUN [[Main Page]]
7484 <link rel="mw:PageProp/redirect" href="./Main_Page">
7495 <p>Foo<link rel="mw:PageProp/redirect" href="./Foo"></p>
7512 Broken br tag sanitization
7520 # TODO: Fix html2html mode (bug 51055)!
7521 # This </br> handling was added as part of bug 50831; but it
7522 # differs from how PHP+tidy handles this. We should investigate
7525 Parsoid: Broken br tag recognition
7541 Incorrecly removing closing slashes from correctly formed XHTML
7543 <br style="clear:both;" />
7545 <p><br style="clear:both;" />
7550 Failing to transform badly formed HTML into correct XHTML
7552 <br style="clear: left;">
7553 <br style="clear: right;">
7554 <br style="clear: both;">
7556 <p><br style="clear: left;" />
7557 <br style="clear: right;" />
7558 <br style="clear: both;" />
7562 ## FIXME: Is Parsoid's acceptance of self-closing html-tags
7563 ## a feature or a bug? See https://phabricator.wikimedia.org/T76962
7565 Handling html with a div self-closing tag
7574 <p><div title />
7578 <p><div title=bar />
7579 <div title=bar/>
7581 <div title="bar/"></div>
7585 <div title="" data-parsoid='{"stx":"html","selfClose":true}'></div>
7586 <div title="" data-parsoid='{"stx":"html","selfClose":true}'></div>
7587 <div title="" data-parsoid='{"stx":"html","selfClose":true,"brokenHTMLTag":true}'></div>
7588 <div title="bar" data-parsoid='{"stx":"html","selfClose":true}'></div>
7589 <div title="bar" data-parsoid='{"stx":"html","selfClose":true}'></div>
7590 <div title="bar/" data-parsoid='{"stx":"html","autoInsertedEnd":true}'></div>
7594 Handling html with a br self-closing tag
7603 <p><br title="title" />
7604 <br title="title" />
7621 Horizontal ruler (should it add that extra space?)
7636 Horizontal ruler -- 4+ dashes render hr
7645 Horizontal ruler -- eats additional dashes on the same line
7654 Horizontal ruler -- does not collapse dashes on consecutive lines
7665 Horizontal ruler -- <4 dashes render as plain text
7674 Horizontal ruler -- Supports content following dashes on same line
7686 ### Block-level elements
7695 <ul><li>Common list</li>
7697 <li>item 3</li></ul>
7708 <ol><li>Numbered list</li>
7710 <li> item 3</li></ol>
7724 ***#Number on level 4
7726 **#Number on level 3
7727 **#Number on level 3
7731 #** Level 3, but ordered
7734 <ol><li> with numbers</li></ol>
7735 <ul><li> and bullets</li></ul>
7736 <ol><li> and numbers</li></ol></li>
7738 <ul><li>bullet level 2
7739 <ul><li>bullet level 3
7740 <ol><li>Number on level 4</li></ol></li></ul></li>
7742 <ol><li>Number on level 3</li>
7743 <li>Number on level 3</li></ol></li></ul>
7744 <ol><li>number level 2</li></ol></li>
7746 <ul><li><ul><li> Level 3</li></ul></li></ul></li></ul>
7747 <ol><li><ul><li><ul><li> Level 3, but ordered</li></ul></li></ul></li></ol>
7758 <ul><li>bar</li></ul></li></ul>
7768 <ul><li><ul><li>foo</li></ul></li>
7774 Nested lists 3 (first element empty)
7780 <ul><li>bar</li></ul></li></ul>
7785 Nested lists 4 (first element empty)
7790 <ul><li><ul><li></li></ul></li>
7796 Nested lists 5 (both elements empty)
7801 <ul><li><ul><li></li></ul></li>
7807 Nested lists 6 (both elements empty)
7813 <ul><li></li></ul></li></ul>
7818 Nested lists 7 (skip initial nesting levels)
7822 <ul><li><ul><li><ul><li> foo</li></ul></li></ul></li></ul>
7827 Nested lists 8 (multiple nesting transitions)
7835 <ul><li><ul><li> bar</li></ul></li>
7836 <li> baz</li></ul></li>
7842 1. Lists with start-of-line-transparent tokens before bullets: Comments
7855 2. Lists with start-of-line-transparent tokens before bullets: Template close
7860 <ul><li>foo bar</li>
7866 List items are not parsed correctly following a <pre> block (bug 785)
7872 <ul><li> <pre>foo</pre></li>
7873 <li> <pre>bar</pre></li>
7879 List items from template
7890 * notSOL{{inner list}}
7893 <ul><li> item 1</li>
7894 <li> item 2</li></ul>
7895 <ul><li> item 0</li>
7897 <li> item 2</li></ul>
7898 <ul><li> item 0</li>
7901 <li> item 2</li></ul>
7906 List interrupted by empty line or heading
7914 <ul><li> foo</li></ul>
7915 <ul><li><ul><li> bar</li></ul></li></ul>
7916 <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>
7917 <ul><li> Another list item</li></ul>
7922 Multiple list tags generated by templates
7943 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
7946 <!--This line will NOT split the list-->
7948 <!--This line will NOT split the list either-->
7950 <!--foo--> <!----> <!--This line NOT split the list either-->
7961 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
7964 <!--This line will NOT split the list-->
7966 <!--This line will NOT split the list either-->
7968 <!--foo--> <!----> <!--This line NOT split the list
7981 (The PHP parser relies on Tidy for the hack)
7983 parsoid=wt2html,wt2wt
7987 * {{echo|<li>templated li-hack}}
7988 * <!--foo--> <li> unsupported li-hack with preceding comments
7991 <li><li>not a li-hack
7998 <li>templated li-hack</li>
7999 <li>unsupported li-hack with preceding comments</li>
8002 <li>not a li-hack</li>
8007 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
8034 Parsoid: Test of whitespace serialization with Templated bullets
8041 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}}]}'> Bar</li>
8045 # ------------------------------------------------------------------------
8046 # The next set of tests are about Parsoid's ability to handle badly nested
8047 # tags (parse, minimize scope of fixup, and roundtrip back)
8048 # ------------------------------------------------------------------------
8051 Unbalanced closing block tags break a list
8052 (php parser relies on Tidy to fix up)
8070 # Parsoid fails this test, but it might be tricky to support properly.
8073 Unbalanced closing non-block tags don't break a list
8074 (php parser relies on Tidy to fix up)
8081 <li><span>a</span></li>
8082 <li><span>b</span></li>
8096 Unclosed formatting tags that straddle lists are closed and reopened
8097 (php parser relies on Tidy to fix up)
8099 parsoid=wt2html,wt2wt,html2html
8109 <ol><li> <s> a</s></li>
8110 <li><s> b </s></li></ol>
8113 # Parsoid fails this test, but it might be tricky to support properly.
8116 List embedded in a non-block tag
8117 (Ugly Parsoid output -- worth fixing; PHP parser relies on Tidy)
8124 <li><small>foo</small></li>
8134 # This is a bug in the PHP parser + tidy combination.
8135 # (The </tr> tag gets parsed as text and html-escaped by PHP,
8136 # and then fostered out of the table by tidy.)
8137 # We believe the Parsoid output to be correct.
8139 Table with missing opening <tr> tag
8141 parsoid=wt2html,wt2wt
8166 # Note that the current date is hard-coded as
8167 # 1970-01-01T00:02:03Z (a Thursday)
8168 # when running parser tests. The timezone is also fixed to GMT, so
8169 # local date will be identical to current date.
8172 Magic Word: {{CURRENTDAY}}
8181 Magic Word: {{CURRENTDAY2}}
8190 Magic Word: {{CURRENTDAYNAME}}
8199 Magic Word: {{CURRENTDOW}}
8208 Magic Word: {{CURRENTMONTH}}
8217 Magic Word: {{CURRENTMONTH1}}
8226 Magic Word: {{CURRENTMONTHABBREV}}
8228 {{CURRENTMONTHABBREV}}
8235 Magic Word: {{CURRENTMONTHNAME}}
8237 {{CURRENTMONTHNAME}}
8244 Magic Word: {{CURRENTMONTHNAMEGEN}}
8246 {{CURRENTMONTHNAMEGEN}}
8253 Magic Word: {{CURRENTTIME}}
8262 Magic Word: {{CURRENTHOUR}}
8271 Magic Word: {{CURRENTWEEK}} (@bug 4594)
8280 Magic Word: {{CURRENTYEAR}}
8289 Magic Word: {{CURRENTTIMESTAMP}}
8291 {{CURRENTTIMESTAMP}}
8298 Magic Words LOCAL (UTC)
8302 * {{LOCALMONTHNAME}}
8303 * {{LOCALMONTHNAMEGEN}}
8304 * {{LOCALMONTHABBREV}}
8313 * {{LOCALTIMESTAMP}}
8328 <li> 19700101000203</li></ul>
8333 Magic Word: {{FULLPAGENAME}}
8335 title=[[User:Ævar Arnfjörð Bjarmason]]
8339 <p>User:Ævar Arnfjörð Bjarmason
8344 Magic Word: {{FULLPAGENAMEE}}
8346 title=[[User:Ævar Arnfjörð Bjarmason]]
8350 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8355 Magic Word: {{TALKSPACE}}
8357 title=[[User:Ævar Arnfjörð Bjarmason]]
8366 Magic Word: {{TALKSPACE}}, same namespace
8368 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8377 Magic Word: {{TALKSPACE}}, main namespace
8379 title=[[Parser Test]]
8388 Magic Word: {{TALKSPACEE}}
8390 title=[[User:Ævar Arnfjörð Bjarmason]]
8399 Magic Word: {{SUBJECTSPACE}}
8401 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8410 Magic Word: {{SUBJECTSPACE}}, same namespace
8412 title=[[User:Ævar Arnfjörð Bjarmason]]
8421 Magic Word: {{SUBJECTSPACE}}, main namespace
8423 title=[[Parser Test]]
8431 Magic Word: {{SUBJECTSPACEE}}
8433 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8442 Magic Word: {{NAMESPACE}}
8444 title=[[User:Ævar Arnfjörð Bjarmason]]
8453 Magic Word: {{NAMESPACEE}}
8455 title=[[User:Ævar Arnfjörð Bjarmason]]
8464 Magic Word: {{NAMESPACENUMBER}}
8466 title=[[User:Ævar Arnfjörð Bjarmason]]
8475 Magic Word: {{SUBPAGENAME}}
8477 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
8486 Magic Word: {{SUBPAGENAMEE}}
8488 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
8497 Magic Word: {{ROOTPAGENAME}}
8499 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
8503 <p>Ævar Arnfjörð Bjarmason
8508 Magic Word: {{ROOTPAGENAMEE}}
8510 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
8514 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8519 Magic Word: {{BASEPAGENAME}}
8521 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
8525 <p>Ævar Arnfjörð Bjarmason
8530 Magic Word: {{BASEPAGENAMEE}}
8532 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
8536 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8541 Magic Word: {{TALKPAGENAME}}
8543 title=[[User:Ævar Arnfjörð Bjarmason]]
8547 <p>User talk:Ævar Arnfjörð Bjarmason
8552 Magic Word: {{TALKPAGENAMEE}}
8554 title=[[User:Ævar Arnfjörð Bjarmason]]
8558 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8563 Magic Word: {{SUBJECTPAGENAME}}
8565 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8569 <p>User:Ævar Arnfjörð Bjarmason
8574 Magic Word: {{SUBJECTPAGENAMEE}}
8576 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8578 {{SUBJECTPAGENAMEE}}
8580 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8585 Magic Word: {{NUMBEROFFILES}}
8594 Magic Word: {{PAGENAME}}
8596 title=[[User:Ævar Arnfjörð Bjarmason]]
8600 <p>Ævar Arnfjörð Bjarmason
8605 Magic Word: {{PAGENAME}} with metacharacters
8607 title=[['foo & bar = baz']]
8611 <p><i>'foo & bar = baz'</i>
8614 <p><i>'foo & bar = baz'</i></p>
8618 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
8620 title=[[*RFC 1234 http://example.com/]]
8624 <p>*RFC 1234 http://example.com/
8627 <p>*RFC 1234 http://example.com/</p>
8631 Magic Word: {{PAGENAMEE}}
8633 title=[[User:Ævar Arnfjörð Bjarmason]]
8637 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8642 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
8644 title=[[*RFC 1234 http://example.com/]]
8648 <p>*RFC_1234_http://example.com/
8651 <p>*RFC_1234_http://example.com/</p>
8655 Magic Word: {{REVISIONID}}
8664 Magic Word: {{SCRIPTPATH}}
8673 Magic Word: {{STYLEPATH}}
8682 Magic Word: {{SERVER}}
8686 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
8691 Magic Word: {{SERVERNAME}}
8700 Magic Word: {{SITENAME}}
8709 Case-sensitive magic words, when cased differently, should just be template transclusions
8716 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
8717 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
8718 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
8719 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
8724 Case-insensitive magic words should still work with weird casing.
8734 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
8739 Namespace 1 {{ns:1}}
8748 Namespace 1 {{ns:01}}
8757 Namespace 0 {{ns:0}} (bug 4783)
8765 Namespace 0 {{ns:00}} (bug 4783)
8773 Namespace -1 {{ns:-1}}
8782 Namespace User {{ns:User}}
8791 Namespace User talk {{ns:User_talk}}
8800 Namespace User talk {{ns:uSeR tAlK}}
8809 Namespace File {{ns:File}}
8818 Namespace File {{ns:Image}}
8827 Namespace (lang=de) Benutzer {{ns:User}}
8838 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
8844 <p>Benutzer Diskussion
8852 {{urlencode:hi world?!}}
8853 {{urlencode:hi world?!|WIKI}}
8854 {{urlencode:hi world?!|PATH}}
8855 {{urlencode:hi world?!|QUERY}}
8865 Magic Word: prioritize type info over data-parsoid
8871 <meta property="mw:PageProp/forcetoc" data-parsoid='{"src":"__NOTOC__","magicSrc":"__NOTOC__"}'/>
8875 Magic Word: serialize on separate line (parsoid)
8877 parsoid=wt2wt,html2wt
8883 foo<meta property="mw:PageProp/notoc"/>bar
8887 Magic Word: rt non-english wikis
8894 <meta property="mw:PageProp/noeditsection" data-parsoid='{"src":"__NOEDITSECTION__","magicSrc":"__NOEDITSECTION__"}'/>
8901 Magic links: internal link to RFC (bug 479)
8905 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
8910 Magic links: RFC (bug 479)
8914 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
8919 Magic links: RFC (bug 65278)
8921 This is RFC 822 but thisRFC 822 is not RFC 822linked.
8923 <p>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a> but thisRFC 822 is not RFC 822linked.
8928 Magic links: ISBN (bug 1937)
8932 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
8937 Magic links: ISBN (bug 65278)
8939 This is ISBN 978-0-316-09811-3 but thisISBN 978-0-316-09811-3 is not ISBN 978-0-316-09811-3linked.
8941 <p>This is <a href="/wiki/Special:BookSources/9780316098113" class="internal mw-magiclink-isbn">ISBN 978-0-316-09811-3</a> but thisISBN 978-0-316-09811-3 is not ISBN 978-0-316-09811-3linked.
8946 Magic links: PMID incorrectly converts space to underscore
8950 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
8955 Magic links: PMID (bug 65278)
8957 This is PMID 1234 but thisPMID 1234 is not PMID 1234linked.
8959 <p>This is <a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a> but thisPMID 1234 is not PMID 1234linked.
8968 Nonexistent template
8970 {{thistemplatedoesnotexist}}
8972 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
8977 Template with invalid target containing tags
8979 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
8981 <p>{{a<b>b</b>|foo|a=b|a = b}}
8986 Template with invalid target containing unclosed tag
8988 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
8990 <p>{{a<b>|foo|a=b|a = b}}</b>
8995 Template with invalid target containing wikilink
8999 <p>{{<a href="/wiki/Main_Page" title="Main Page">Main Page</a>}}
9002 <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>
9006 Template with just whitespace in it, bug #68421
9010 <p><span typeof="mw:Transclusion mw:Nowiki" about="#mwt1" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{ }}"}},"i":0}}]}'>{{ }}</span></p>
9016 This is a test template
9024 <p>This is a test template
9029 Template with explicit namespace
9033 <p>This is a test template
9041 This is a test template with parameter {{{param}}}
9047 {{paramtest|param=foo}}
9049 <p>This is a test template with parameter foo
9054 Template:paramtestnum
9060 Template unnamed parameter
9062 {{paramtestnum|Main Page|the main page}}
9064 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
9069 Template:templatesimple
9075 Template:templateredirect
9077 #redirect [[Template:templatesimple]]
9081 Template:templateasargtestnum
9087 Template:templateasargtest
9089 {{template{{{templ}}}}}
9093 Template:templateasargtest2
9099 Template with template name as unnamed argument
9101 {{templateasargtestnum|templatesimple}}
9108 Template with template name as argument
9110 {{templateasargtest|templ=simple}}
9117 Template with template name as argument (2)
9119 {{templateasargtest2|templ=templatesimple}}
9126 Template:templateasargtestdefault
9128 {{{{{templ|templatesimple}}}}}
9138 Template with default value
9140 {{templateasargtestdefault}}
9147 Template with default value (value set)
9149 {{templateasargtestdefault|templ=templa}}
9158 {{templateredirect}}
9165 Template with argument in separate line
9167 {{ templateasargtest |
9175 Template with complex template as argument
9178 param ={{ templateasargtest |
9181 <p>This is a test template with parameter (test)
9186 Template with thumb image (with link in description)
9188 {{paramtest|param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
9190 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>
9193 <p>This is a test template with parameter</p>
9194 <div class="thumb tright">
9195 <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>
9196 <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>
9200 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"paramtest","href":"./Template:Paramtest"},"params":{"param":{"wt":"[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]"}},"i":0}}]}'>This is a test template with parameter </p><figure class="mw-default-size" typeof="mw:Error mw:Image/Thumb" about="#mwt1" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Noimage.png" ><img resource="./File:Noimage.png" src="./Special:FilePath/Noimage.png" height="220" width="220"/></a><figcaption><a rel="mw:WikiLink" href="./No_link" title="No link">link</a> <a rel="mw:WikiLink" href="./No_link" title="No link">caption</a></figcaption></figure>
9204 Template:complextemplate
9206 {{{1}}} {{paramtest|
9207 param ={{{param}}}}}
9211 Template with complex arguments
9214 param ={{ templateasargtest |
9215 templ = simple }}|[[Template:complextemplate|link]]}}
9217 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
9222 BUG 553: link with two variables in a piped link
9225 |[[{{{1}}}|{{{2}}}]]
9230 <td>[[{{{1}}}|{{{2}}}]]
9236 Magic variable as template parameter
9238 {{paramtest|param={{SITENAME}}}}
9240 <p>This is a test template with parameter MediaWiki
9247 [[{{{param}}}|link]]
9251 Template parameter as link source
9253 {{linktest|param=Main Page}}
9255 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
9260 Template-generated attribute string (k='v')
9262 <span {{attr_str|id|v1}}>bar</span>
9264 <p><span id="v1">bar</span>
9271 including another template, {{paramtest|param={{{arg}}}}}
9275 Template passing argument to another template
9277 {{paramtest2|arg='hmm'}}
9279 <p>including another template, This is a test template with parameter 'hmm'
9290 Template as link source
9294 [[{{linktest2}}|Main Page]]
9296 [[{{linktest2}}]]Page
9298 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
9299 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
9300 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
9318 Template infinite loop
9322 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
9327 Template from main namespace
9346 BUG 529: Template with table, not included at beginning of line
9365 BUG 523: Template shouldn't eat newline (or add an extra one before table)
9385 BUG 41: Template parameters shown as broken links
9394 Template with targets containing wikilinks
9398 {{[[{{echo|foo}}]]}}
9400 {{{{echo|[[foo}}]]}}
9402 <p>{{<a href="/wiki/Foo" title="Foo">foo</a>}}
9403 </p><p>{{<a href="/wiki/Foo" title="Foo">foo</a>}}
9411 ''None'' of '''this''' should be
9413 but rather passed unmodified
9420 # hmm, fix this or just deprecate msgnw and document its behavior?
9424 {{msgnw:MSGNW test}}
9426 <p>''None'' of '''this''' should be
9428  but rather passed unmodified
9429 {{test}}
9439 {{int:youhavenewmessages|lots of money|not!}}
9441 <p>You have lots of money (not!).
9448 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
9452 <includeonly> and <noinclude> being included
9463 <onlyinclude>Foo</onlyinclude>bar
9467 <onlyinclude> being included
9479 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
9483 <onlyinclude> and <includeonly> being included
9492 <includeonly> and <noinclude> on a page
9494 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
9501 Un-closed <noinclude>
9508 <onlyinclude> on a page
9510 <onlyinclude>Foo</onlyinclude>bar
9517 Un-closed <onlyinclude>
9524 Self-closed noinclude, includeonly, onlyinclude tags
9535 Unbalanced includeonly and noinclude tags
9539 |b</noinclude></noinclude>
9540 |c</noinclude></includeonly>
9541 |d</includeonly></includeonly>
9550 <td>c</includeonly>
9552 <td>d</includeonly></includeonly>
9558 Template:Includeonly section
9561 ==Includeonly section==
9567 Bug 6563: Edit link generation for section shown by <includeonly>
9569 {{includeonly section}}
9571 <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>
9572 <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>
9576 # Uses same input as the contents of [[Template:Includeonly section]]
9578 Bug 6563: Section extraction for section shown by <includeonly>
9583 ==Includeonly section==
9591 Bug 6563: Edit link generation for section suppressed by <includeonly>
9594 ==Includeonly section==
9598 <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>
9603 Bug 6563: Section extraction for section suppressed by <includeonly>
9608 ==Includeonly section==
9616 Un-closed <includeonly>
9623 Includes and comments at SOL
9625 <!-- comment --><noinclude><!-- comment --></noinclude><!-- comment -->== hu ==
9632 <includeonly>can have stuff</includeonly>=== here ===
9635 <h2><span class="mw-headline" id="hu">hu</span></h2>
9640 <h3><span class="mw-headline" id="here">here</span></h3>
9643 <!-- comment --><meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/><!-- comment --><meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/><!-- comment --><h2> hu </h2>
9645 <meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/>
9647 <meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/><ul><li> stuff</li>
9650 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>can have stuff</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><h3> here </h3>
9654 # TODO: test with DOM fragment reuse!
9656 Parsoid: DOM fragment reuse
9658 parsoid=wt2wt,wt2html
9660 a{{echo|b<table></table>c}}d
9672 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["a",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b<table></table>c"}},"i":0}},"d"]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>ab</p><table about="#mwt1" data-parsoid='{"stx":"html"}'></table><p about="#mwt1">cd</p>
9674 <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"]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>ab</p><span about="#mwt2">
9675 </span><table about="#mwt2" data-parsoid='{"stx":"html"}'></table><span about="#mwt2">
9676 </span><p about="#mwt2">cd</p>
9678 <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}}]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>a</p><span about="#mwt3">
9680 </span><table about="#mwt3" data-parsoid='{"stx":"html"}'></table><span about="#mwt3">
9682 </span><p about="#mwt3">b</p>
9686 Parsoid: Merge double tds (bug 50603)
9695 <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>
9700 Parsoid: Merge double tds in nested transclusion content (bug 50603)
9710 <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}}]}'>
9712 <tr><td data-mw='{"parts":["|"]}'> foo</td></tr>
9718 ### <includeonly> and <noinclude> in attributes
9721 0. includeonly around the entire attribute
9723 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
9725 <p><span id="v2">bar</span>
9730 1. includeonly in html attr key
9732 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
9734 <p><span id="foo">bar</span>
9739 2. includeonly in html attr value
9741 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
9742 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
9744 <p><span id="v1">bar</span>
9745 <span id="v1">bar</span>
9750 3. includeonly in part of an attr value
9752 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
9754 <p><span style="color:red;">bar</span>
9759 4. includeonly in table attributes
9783 ### Token Stream Patcher tests
9785 ### These tests won't always pass wt2wt and other modes because
9786 ### on serialization, the table will be output on a new line.
9787 ### For now, we are blacklisting them, and using this to test selser.
9791 1. Table tag in SOL posn. should get reparsed correctly with valid TSR
9793 parsoid=wt2html,wt2wt
9795 {{echo|}}{| width = '100%'
9799 <span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":""}},"i":0}}]}'></span><table width="100%">
9800 <tbody><tr><td>foo</td></tr>
9805 2. Table tag in SOL posn. should get reparsed correctly with valid TSR
9807 parsoid=wt2html,wt2wt
9809 <includeonly>a</includeonly>{| {{{b}}}
9813 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>a</includeonly>"'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><table about="#mwt2" typeof="mw:ExpandedAttrs" data-mw='{"attribs":[[{"txt":"{{{b}}}","html":"<span about=\"#mwt1\" typeof=\"mw:Param\" data-parsoid=\"{&quot;dsr&quot;:[31,38,null,null],&quot;src&quot;:&quot;{{{b}}}&quot;}\">{{{b}}}</span>"},{"html":""}]]}' data-parsoid='{"a":{"{{{b}}}":null},"sa":{"{{{b}}}":""}}'>
9814 <tbody><tr><td>c</td></tr>
9820 ### Testing parsing of templates where a template arg
9821 ### has the same name as the template itself.
9831 Templates: Template Name/Arg clash: 1. Use of positional param
9840 Templates: Template Name/Arg clash: 2. Use of named param
9849 Templates: Template Name/Arg clash: 3. Use of named param with empty input
9858 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
9862 Templates: 1. Simple use
9871 Templates: 2. Inside a block tag
9873 <div>{{echo|Foo}}</div>
9874 <blockquote>{{echo|Foo}}</blockquote>
9877 <blockquote>Foo</blockquote>
9887 Templates: P-wrapping: 1a. Templates on consecutive lines
9898 Templates: P-wrapping: 1b. Templates on consecutive lines
9912 Templates: P-wrapping: 1c. Templates on consecutive lines
9915 {{echo|bar}} <div>baz</div>
9928 Templates: P-wrapping: 1d. Template preceded by comment-only line
9937 <p about="#mwt223" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Bar"}},"i":0}}]}'>Bar</p>
9941 Templates: Inline Text: 1. Multiple template uses
9943 {{echo|Foo}}bar{{echo|baz}}
9950 Templates: Inline Text: 2. Back-to-back template uses
9952 {{echo|Foo}}{{echo|bar}}
9959 Templates: Block Tags: 1. Multiple template uses
9961 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
9963 <div>Foo</div><div>bar</div><div>baz</div>
9968 Templates: Block Tags: 2. Back-to-back template uses
9970 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
9972 <div>Foo</div><div>bar</div>
9976 # This is an edge case relating to paragraph wrapping.
9978 Templates: Correctly encapsulate templates producing </p> tag without a corresponding <p> tag
9983 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\nb</p>"}},"i":0}}]}'>a
9988 Templates: Links: 1. Simple example
9990 {{echo|[[Foo|bar]]}}
9992 <p><a href="/wiki/Foo" title="Foo">bar</a>
9997 Templates: Links: 2. Generation of link href
9999 [[{{echo|Foo}}|bar]]
10001 <p><a href="/wiki/Foo" title="Foo">bar</a>
10006 Templates: Links: 3. Generation of part of a link href
10008 [[Fo{{echo|o}}|bar]]
10010 [[Foo{{echo|bar}}]]
10012 [[Foo{{echo|bar}}baz]]
10014 [[Foo{{echo|bar}}|bar]]
10016 [[:Foo{{echo|bar}}]]
10018 [[:Foo{{echo|bar}}|bar]]
10020 <p><a href="/wiki/Foo" title="Foo">bar</a>
10021 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
10022 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
10023 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
10024 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
10025 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
10030 Templates: Links: 4. Multiple templates generating link href
10032 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
10034 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
10039 Templates: Links: 5. Generation of link text
10041 [[Foo|{{echo|bar}}]]
10043 <p><a href="/wiki/Foo" title="Foo">bar</a>
10048 Templates: Links: 5. Nested templates (only outermost template should be marked)
10050 {{echo|[[{{echo|Foo}}|bar]]}}
10052 <p><a href="/wiki/Foo" title="Foo">bar</a>
10057 Templates: HTML Tag: 1. Generation of HTML attr. key
10059 <div {{echo|style}}="color:red;">foo</div>
10061 <div style="color:red;">foo</div>
10066 Templates: HTML Tag: 2. Generation of HTML attr. value
10068 <div style={{echo|'color:red;'}}>foo</div>
10070 <div style="color:red;">foo</div>
10075 Templates: HTML Tag: 3. Generation of HTML attr key and value
10077 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
10079 <div style="color:red;">foo</div>
10084 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
10086 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
10088 <div title="This is a long title with just one piece templated">foo</div>
10093 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
10095 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
10097 <div title="This is a long title with just one piece templated">foo</div>
10102 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
10104 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
10106 <div title="This is a long title with just one piece templated">foo</div>
10111 Templates: HTML Tag: 7. Generation of partial attribute key string
10113 <div st{{echo|yle}}="color:red;">foo</div>
10115 <div style="color:red;">foo</div>
10120 Templates: HTML Tables: 1. Generating start of a HTML table
10122 {{echo|<table><tr><td>foo</td>}}</tr></table>
10124 <table><tr><td>foo</td></tr></table>
10129 Templates: HTML Tables: 2a. Generating middle of a HTML table
10131 <table><tr>{{echo|<td>foo</td>}}</tr></table>
10133 <table><tr><td>foo</td></tr></table>
10138 Templates: HTML Tables: 2b. Generating middle of a HTML table
10140 <table>{{echo|<tr><td>foo</td></tr>}}</table>
10142 <table><tr><td>foo</td></tr></table>
10147 Templates: HTML Tables: 3. Generating end of a HTML table
10149 <table><tr>{{echo|<td>foo</td></tr></table>}}
10151 <table><tr><td>foo</td></tr></table>
10156 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
10158 {{echo|<table>}}<tr><td>foo</td></tr></table>
10160 <table><tr><td>foo</td></tr></table>
10165 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
10167 <table>{{echo|<tr>}}<td>foo</td></tr></table>
10169 <table><tr><td>foo</td></tr></table>
10174 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
10176 <table><tr>{{echo|<td>}}foo</td></tr></table>
10178 <table><tr><td>foo</td></tr></table>
10183 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
10185 <table><tr><td>foo{{echo|</td>}}</tr></table>
10187 <table><tr><td>foo</td></tr></table>
10192 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
10194 <table><tr><td>foo</td>{{echo|</tr>}}</table>
10196 <table><tr><td>foo</td></tr></table>
10201 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
10203 <table><tr><td>foo</td></tr>{{echo|</table>}}
10205 <table><tr><td>foo</td></tr></table>
10210 Templates: HTML Tables: 5. Proper fostering of categories from inside
10212 parsoid=wt2html,wt2wt
10214 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
10215 <!--Two categories (Bug 50330)-->
10216 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
10218 <link rel="mw:PageProp/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
10219 <!--Two categories (Bug 50330)-->
10220 <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>
10224 Templates: Wiki Tables: 1a. Fostering of entire template content
10232 <tr><td></td></tr></table>
10244 Templates: Wiki Tables: 1b. Fostering of entire template content
10257 <tr><td></td></tr></table>
10271 Templates: Wiki Tables: 2. Fostering of partial template content
10281 <tr><td></td></tr></table>
10294 Templates: Wiki Tables: 3. td-content via multiple templates
10297 {{echo|{{pipe}}a}}{{echo|b}}
10308 Templates: Wiki Tables: 4. Templated tags, no content
10314 <tr><td></td></tr></table>
10319 Templates: Wiki Tables: 5. Templated tags, regular td-tags
10333 Templates: Wiki Tables: 6. Templated tags, templated td-tags
10347 Templates: Lists: Multi-line list-items via templates
10349 *{{echo|a {{nonexistent|
10351 *{{echo|b {{nonexistent|
10354 <ul><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></li>
10355 <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></li></ul>
10360 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
10362 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
10364 <p><i>ab</i>c<i>d</i>e
10369 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
10370 (PHP parser generates misnested html)
10372 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
10374 <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>
10378 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
10379 (PHP parser generates misnested html; Parsoid html2wt mode adds newlines between {{echo}}s)
10381 parsoid=wt2html,wt2wt
10383 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
10385 <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>
10386 <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>
10387 <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>
10391 Templates: Ugly nesting: 4. Divs opened/closed across templates
10393 a<div>b{{echo|c</div>d}}e
10404 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
10410 |{{echo|foo</table>}}
10414 <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|}"]}'>
10418 <td>foo</td></tr></tbody></table><span about="#mwt1">
10419 </span><span about="#mwt1">|bar</span><span about="#mwt1">
10424 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
10434 <td>1. {{echo|foo </table>}}</td>
10436 <td>2. {{echo|baz </table>}}</td>
10449 <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>"]}'>
10454 <td>1. foo </td></tr></tbody></table></td>
10456 <td>2. baz </td></tr></tbody></table><span about="#mwt2">
10457 </span><span about="#mwt2">
10458 </span><span about="#mwt2">
10459 </span><span about="#mwt2">abc</span><span about="#mwt2">
10460 </span><span about="#mwt2">
10461 </span><span about="#mwt2">
10462 </span><span about="#mwt2">
10463 </span><span about="#mwt2">
10464 </span><span about="#mwt2">
10465 </span><span about="#mwt2">xyz</span><span about="#mwt2">
10466 </span><span about="#mwt2">
10471 Templates: Ugly templates: 3. newline-only template parameter
10480 # This looks like a bug: a single newline triggers p/br for some reason.
10482 Templates: Ugly templates: 4. newline-only template parameter inconsistency
10491 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges that
10492 # have a true overlap (T1-start - T2-start - T1-end - T2-end).
10494 Templates: Ugly templates: 5. Template encapsulation test: Non-trivial overlap of template ranges is properly handled
10500 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table>"}},"i":0}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div>foo"}},"i":1}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"</table>"}},"i":2}}]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}]]}'>foo
10501 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
10505 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges
10506 # that are "identical" and generate nesting cycles in the algorithm
10508 Templates: Ugly templates: 6. Template encapsulation test: Cyclical nesting of template ranges is properly handled
10510 {{echo|<table><tr><td><table>}}
10514 <table about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table><tr><td><table>"}},"i":0}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div>"}},"i":1}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"</div>"}},"i":2}}]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}]]}'><tbody><tr data-parsoid='{"stx":"html"}'><td data-parsoid='{"stx":"html"}'><div data-parsoid='{"stx":"html"}'>
10515 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
10516 </table></td></tr></tbody></table>
10520 Parser Functions: 1. Simple example
10529 Parser Functions: 2. Nested use (only outermost should be marked up)
10538 ### Pre-save transform tests
10541 pre-save transform: subst:
10547 This is a test template
10551 pre-save transform: normal template
10561 pre-save transform: nonexistent template
10565 {{thistemplatedoesnotexist}}
10567 {{thistemplatedoesnotexist}}
10572 pre-save transform: subst magic variables
10581 # This is bug 89, which I fixed. -- wtm
10583 pre-save transform: subst: templates with parameters
10587 {{subst:paramtest|param="something else"}}
10589 This is a test template with parameter "something else"
10593 Template:nowikitest
10595 <nowiki>'''not wiki'''</nowiki>
10599 pre-save transform: nowiki in subst (bug 1188)
10603 {{subst:nowikitest}}
10605 <nowiki>'''not wiki'''</nowiki>
10610 Template:commenttest
10612 This template has <!-- a comment --> in it.
10616 pre-save transform: comment in subst (bug 1936)
10620 {{subst:commenttest}}
10622 This template has <!-- a comment --> in it.
10626 pre-save transform: unclosed tag
10630 <nowiki>'''not wiki'''
10632 <nowiki>'''not wiki'''
10636 pre-save transform: mixed tag case
10640 <NOwiki>'''not wiki'''</noWIKI>
10642 <NOwiki>'''not wiki'''</noWIKI>
10646 pre-save transform: unclosed comment in <nowiki>
10650 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
10652 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
10655 # Leading @ in this template definition works around a limitation
10656 # in parsoid's parserTests which otherwise strips the <span> from the
10657 # result (confusing it for a template wrapper)
10661 @<span onmouseover="alert('crap')">Oh no</span>
10665 (confirming safety of fix for subst bug 1936)
10667 {{Template:dangerous}}
10669 <p>@<span>Oh no</span>
10674 pre-save transform: comment containing gallery (bug 5024)
10678 <!-- <gallery>data</gallery> -->
10680 <!-- <gallery>data</gallery> -->
10684 pre-save transform: comment containing extension
10688 <!-- <tag>data</tag> -->
10690 <!-- <tag>data</tag> -->
10694 pre-save transform: comment containing nowiki
10698 <!-- <nowiki>data</nowiki> -->
10700 <!-- <nowiki>data</nowiki> -->
10704 pre-save transform: <noinclude> in subst (bug 3298)
10714 pre-save transform: <onlyinclude> in subst (bug 3298)
10718 {{subst:Includes2}}
10726 {{<includeonly>subst:</includeonly>Includes}}
10730 Template:SafeSubstTest
10732 {{<includeonly>safesubst:</includeonly>Includes}}
10736 bug 22297: safesubst: works during PST
10740 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
10746 bug 22297: safesubst: works during normal parse
10755 subst: does not work during normal parse
10759 <p>{{subst:Includes}}
10764 pre-save transform: context links ("pipe trick")
10768 [[Article (context)|]]
10771 [[Bar:Article (context)|]]
10772 [[:Bar:Article (context)|]]
10774 [[|Article (context)]]
10778 [[Article (context)|Article]]
10779 [[Bar:Article|Article]]
10780 [[:Bar:Article|Article]]
10781 [[Bar:Article (context)|Article]]
10782 [[:Bar:Article (context)|Article]]
10784 [[Article (context)]]
10785 [[Bar:X (Y) Z|X (Y) Z]]
10786 [[:Bar:X (Y) Z|X (Y) Z]]
10790 pre-save transform: context links ("pipe trick") with interwiki prefix
10794 [[interwiki:Article|]]
10795 [[:interwiki:Article|]]
10796 [[interwiki:Bar:Article|]]
10797 [[:interwiki:Bar:Article|]]
10799 [[interwiki:Article|Article]]
10800 [[:interwiki:Article|Article]]
10801 [[interwiki:Bar:Article|Bar:Article]]
10802 [[:interwiki:Bar:Article|Bar:Article]]
10806 pre-save transform: context links ("pipe trick") with parens in title
10808 pst title=[[Somearticle (context)]]
10812 [[Article (context)|Article]]
10816 pre-save transform: context links ("pipe trick") with comma in title
10818 pst title=[[Someplace, Somewhere]]
10821 [[Otherplace, Elsewhere|]]
10822 [[Otherplace, Elsewhere, Anywhere|]]
10824 [[Otherplace, Somewhere|Otherplace]]
10825 [[Otherplace, Elsewhere|Otherplace]]
10826 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
10830 pre-save transform: context links ("pipe trick") with parens and comma
10832 pst title=[[Someplace (IGNORED), Somewhere]]
10835 [[Otherplace (place), Elsewhere|]]
10837 [[Otherplace, Somewhere|Otherplace]]
10838 [[Otherplace (place), Elsewhere|Otherplace]]
10842 pre-save transform: context links ("pipe trick") with comma and parens
10844 pst title=[[Who, me? (context)]]
10847 [[Me, Myself, and I (1937 song)|]]
10849 [[Yes, you. (context)|Yes, you.]]
10850 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
10854 pre-save transform: context links ("pipe trick") with namespace
10856 pst title=[[Ns:Somearticle]]
10860 [[Ns:Article|Article]]
10864 pre-save transform: context links ("pipe trick") with namespace and parens
10866 pst title=[[Ns:Somearticle (context)]]
10870 [[Ns:Article (context)|Article]]
10874 pre-save transform: context links ("pipe trick") with namespace and comma
10876 pst title=[[Ns:Somearticle, Context, Whatever]]
10880 [[Ns:Article, Context, Whatever|Article]]
10884 pre-save transform: context links ("pipe trick") with namespace, comma and parens
10886 pst title=[[Ns:Somearticle, Context (context)]]
10890 [[Ns:Article (context)|Article]]
10894 pre-save transform: context links ("pipe trick") with namespace, parens and comma
10896 pst title=[[Ns:Somearticle (IGNORED), Context]]
10900 [[Ns:Article, Context|Article]]
10904 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
10908 [[Article(context)|]]
10909 [[Bar:Article(context)|]]
10910 [[:Bar:Article(context)|]]
10911 [[|Article(context)]]
10915 [[Article(context)|Article]]
10916 [[Bar:Article(context)|Article]]
10917 [[:Bar:Article(context)|Article]]
10918 [[Article(context)]]
10919 [[Bar:X(Y)Z|X(Y)Z]]
10920 [[:Bar:X(Y)Z|X(Y)Z]]
10924 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
10928 [[Article (context)|]]
10929 [[Bar:Article (context)|]]
10930 [[:Bar:Article (context)|]]
10931 [[|Article (context)]]
10935 [[Article (context)|Article]]
10936 [[Bar:Article (context)|Article]]
10937 [[:Bar:Article (context)|Article]]
10938 [[Article (context)]]
10939 [[Bar:X (Y) Z|X (Y) Z]]
10940 [[:Bar:X (Y) Z|X (Y) Z]]
10944 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
10948 [[Article(context)|]]
10949 [[Bar:Article(context)|]]
10950 [[:Bar:Article(context)|]]
10951 [[|Article(context)]]
10955 [[Article(context)|Article]]
10956 [[Bar:Article(context)|Article]]
10957 [[:Bar:Article(context)|Article]]
10958 [[Article(context)]]
10959 [[Bar:X(Y)Z|X(Y)Z]]
10960 [[:Bar:X(Y)Z|X(Y)Z]]
10964 pre-save transform: context links ("pipe trick") with commas (bug 21660)
10968 [[Article (context), context|]]
10969 [[Article (context),context|]]
10970 [[Bar:Article (context), context|]]
10971 [[Bar:Article (context),context|]]
10972 [[:Bar:Article (context), context|]]
10973 [[:Bar:Article (context),context|]]
10975 [[Article (context), context|Article]]
10976 [[Article (context),context|Article]]
10977 [[Bar:Article (context), context|Article]]
10978 [[Bar:Article (context),context|Article]]
10979 [[:Bar:Article (context), context|Article]]
10980 [[:Bar:Article (context),context|Article]]
10984 pre-save transform: trim trailing empty lines
10988 Empty lines are trimmed
10994 Empty lines are trimmed
10998 pre-save transform: Signature expansion
11003 * <noinclude>~~~</noinclude>
11004 * <includeonly>~~~</includeonly>
11005 * <onlyinclude>~~~</onlyinclude>
11007 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
11008 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
11009 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
11010 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
11015 pre-save transform: Signature expansion in nowiki tags (bug 93)
11021 <nowiki>~~~~</nowiki>
11023 <includeonly><nowiki>~~~~</nowiki></includeonly>
11025 <noinclude><nowiki>~~~~</nowiki></noinclude>
11027 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
11029 {{subst:Foo}} shall be converted to FOO
11031 As well as inside noinclude/onlyinclude
11032 <noinclude>{{subst:Foo}}</noinclude>
11033 <onlyinclude>{{subst:Foo}}</onlyinclude>
11035 But not inside includeonly
11036 <includeonly>{{subst:Foo}}</includeonly>
11040 <nowiki>~~~~</nowiki>
11042 <includeonly><nowiki>~~~~</nowiki></includeonly>
11044 <noinclude><nowiki>~~~~</nowiki></noinclude>
11046 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
11048 FOO shall be converted to FOO
11050 As well as inside noinclude/onlyinclude
11051 <noinclude>FOO</noinclude>
11052 <onlyinclude>FOO</onlyinclude>
11054 But not inside includeonly
11055 <includeonly>{{subst:Foo}}</includeonly>
11059 Parsoid: Recognize nowiki with trailing space in tags
11063 <nowiki ><div>[[foo]]</nowiki >
11071 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
11078 Parsoid: Recognize nowiki with odd capitalization
11082 <noWikI ><div>[[foo]]</Nowiki >
11084 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
11089 Parsoid: Escape nowiki with trailing space in tags
11093 <nowiki > foo </nowiki >
11099 <p><nowiki > foo </nowiki ></p>
11100 <p>a<nowiki />b</p>
11101 <p>c<nowiki/ >d</p>
11105 Parsoid: Escape weird noWikI capitalizations
11109 <noWikI > foo </NoWikI >
11111 <p><noWikI > foo </NoWikI ></p>
11115 ### Message transform tests
11118 message transform: magic variables
11128 message transform: should not transform wiki markup
11138 message transform: <noinclude> in transcluded template (bug 4926)
11148 message transform: <onlyinclude> in transcluded template (bug 4926)
11158 {{#special:}} page name, known
11162 {{#special:Recentchanges}}
11164 Special:RecentChanges
11168 {{#special:}} page name with subpage, known
11172 {{#special:Recentchanges/param}}
11174 Special:RecentChanges/param
11178 {{#special:}} page name, unknown
11182 {{#special:foobar nonexistent}}
11184 Special:Foobar nonexistent
11188 {{#speciale:}} page name, known
11192 {{#speciale:Recentchanges}}
11194 Special:RecentChanges
11198 {{#speciale:}} page name with subpage, known
11202 {{#speciale:Recentchanges/param}}
11204 Special:RecentChanges/param
11208 {{#speciale:}} page name, unknown
11212 {{#speciale:foobar nonexistent}}
11214 Special:Foobar_nonexistent
11220 ### For Parsoid-specific tests, see
11221 #### https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
11226 parsoid=wt2html,wt2wt,html2html
11228 [[Image:foobar.jpg]]
11230 <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>
11233 <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></p>
11237 Simple image (using File: namespace, now canonical)
11239 [[File:Foobar.jpg]]
11241 <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>
11244 <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></p>
11248 Right-aligned image
11250 [[File:Foobar.jpg|right]]
11252 <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>
11255 <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>
11261 [[File:Foobar.jpg|right|Caption text]]
11263 <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>
11266 <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>
11270 Image with caption, bug 53312 #1
11272 [[File:Foobar.jpg|right|Caption page stuff]]
11274 <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>
11277 <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>
11281 Image with caption, bug 53312 #2
11283 [[File:Foobar.jpg|right|Caption page=]]
11285 <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>
11288 <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>
11292 Image with caption, bug 53312 #3
11294 [[File:Foobar.jpg|right|Caption page=stuff]]
11296 <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>
11299 <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>
11303 Allow empty links in image captions (Bug 60753)
11307 [[File:Foobar.jpg|thumb|Caption [[Link1]]
11312 <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"></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>
11315 <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"}]}'><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/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>Caption <a rel="mw:WikiLink" href="./Link1" title="Link1" data-parsoid='{"stx":"simple","a":{"href":"./Link1"},"sa":{"href":"Link1"}}'>Link1</a>
11317 <a rel="mw:WikiLink" href="./Link2" title="Link2" data-parsoid='{"stx":"simple","a":{"href":"./Link2"},"sa":{"href":"Link2"}}'>Link2</a>
11318 </figcaption></figure>
11322 Titles in unlinked images (T23454)
11324 [[File:Foobar.jpg|link=|stuff]]
11326 <p><img alt="stuff" src="http://example.com/images/3/3a/Foobar.jpg" title="stuff" width="1941" height="220" />
11331 Link with empty target
11340 Image with empty attribute
11342 parsoid=wt2html,wt2wt,html2html
11344 [[File:Foobar.jpg|right||Caption text]]
11346 <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>
11349 <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>
11353 1. Block image with individual attributes from templates
11355 [[File:Foobar.jpg|thumb|{{echo|137px}}|This is a caption]]
11357 <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"></a></div>This is a caption</div></div></div>
11360 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" about="#mwt2" data-mw='{"attribs":[["thumbnail",{"html":"thumb"}],["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=\"{&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]],&quot;dsr&quot;:[24,38,null,null]}\" 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}}]}\">137px</span>"}]]}'><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
11364 2. Block Image with individual attributes from templates
11366 [[File:Foobar.jpg|{{echo|thumb}}|{{echo|137px}}|This is a caption]]
11368 <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"></a></div>This is a caption</div></div></div>
11371 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" about="#mwt3" data-mw='{"attribs":[["thumbnail",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=\"{&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]],&quot;dsr&quot;:[18,32,null,null]}\" 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}}]}\">thumb</span>"}],["width",{"html":"<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid=\"{&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]],&quot;dsr&quot;:[33,47,null,null]}\" 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}}]}\">137px</span>"}]]}'><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
11375 3. Inline image with individual attributes from templates
11377 [[File:Foobar.jpg|{{echo|50px}}]]
11379 <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>
11382 <p><span typeof="mw:Image mw:ExpandedAttrs" about="#mwt2" data-parsoid='{"optList":[{"ck":"width","ak":"{{echo|50px}}"}]}' data-mw='{"attribs":[["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=\"{&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]],&quot;dsr&quot;:[18,31,null,null]}\" 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}}]}\">50px</span>"}]]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50"/></a></span></p>
11385 ## Parsoid does not provide editing support for images where templates produce multiple image attributes.
11386 ## To signal this, we add a 'mw:Placeholder' type to such images. This could change in the future.
11388 Image with multiple attributes from the same template
11390 [[File:Foobar.jpg|{{image_attribs}}]]
11392 <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>
11395 <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>
11399 Image with link tails
11403 123[[File:Foobar.jpg]]456
11404 123[[File:Foobar.jpg|right]]456
11405 123[[File:Foobar.jpg|thumb]]456
11407 <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
11409 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
11410 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"></a></div></div></div></div>456
11413 <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</p>
11415 <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>
11417 <div class="thumb tright">
11418 <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>
11419 <div class="thumbcaption">
11420 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
11426 <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>
11427 <p>123</p><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><p>456</p>
11428 <p>123</p><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><p>456</p>
11432 Image with multiple captions -- only last one is accepted
11434 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
11436 <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>
11439 <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>
11443 Image with multiple widths -- use last
11445 [[File:Foobar.jpg|200px|300px|caption]]
11447 <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>
11450 <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>
11454 Image with multiple alignments -- use first (bug 48664)
11458 [[File:Foobar.jpg|thumb|left|right|center|caption]]
11460 [[File:Foobar.jpg|middle|text-top|caption]]
11462 <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"></a></div>caption</div></div></div>
11463 <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>
11466 <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>
11467 <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>
11471 Image with width attribute at different positions
11473 [[File:Foobar.jpg|200px|right|Caption]]
11474 [[File:Foobar.jpg|right|200px|Caption]]
11475 [[File:Foobar.jpg|right|Caption|200px]]
11477 <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>
11478 <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>
11479 <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>
11482 <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>
11483 <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>
11484 <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>
11487 # a sad bit of backward-compatibility
11489 Image with size specified with pxpx (bug 13500, 51628)
11491 parsoid=wt2html,wt2wt,html2html
11493 [[File:Foobar.jpg|20pxpx]]
11494 [[File:Foobar.jpg|200x20pxpx]]
11496 <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>
11497 <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>
11500 <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>
11504 Image with link parameter, wiki target
11506 [[File:Foobar.jpg|link=Main Page]]
11508 <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>
11511 <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>
11514 # parsoid bug 49293 (part 1)
11516 Image with link parameter, URL target
11518 [[File:Foobar.jpg|link=http://example.com/]]
11520 <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>
11523 <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>
11526 # parsoid bug 49293 (part 2)
11528 Image with link parameter, protocol-less URL target
11530 [[File:Foobar.jpg|link=//example.com/]]
11532 <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>
11535 <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>
11539 Image with link parameter, wgExternalLinkTarget
11541 [[Image:foobar.jpg|link=http://example.com/]]
11543 wgExternalLinkTarget='foobar'
11545 <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>
11550 Image with link parameter, wgNoFollowLinks set to false
11552 [[Image:foobar.jpg|link=http://example.com/]]
11554 wgNoFollowLinks=false
11556 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11561 Image with link parameter, wgNoFollowDomainExceptions
11563 [[Image:foobar.jpg|link=http://example.com/]]
11565 wgNoFollowDomainExceptions='example.com'
11567 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11572 Image with link parameter, wgExternalLinkTarget, unnamed parameter
11574 [[Image:foobar.jpg|link=http://example.com/|Title]]
11576 wgExternalLinkTarget='foobar'
11578 <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>
11583 Image with empty link parameter
11585 [[File:Foobar.jpg|link=]]
11587 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
11590 <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>
11594 Image with link parameter (wiki target) and unnamed parameter
11596 [[File:Foobar.jpg|link=Main_Page|Title]]
11598 <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>
11601 <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>
11605 Image with link parameter (URL target) and unnamed parameter
11607 [[File:Foobar.jpg|link=http://example.com/|Title]]
11609 <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>
11612 <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>
11616 Thumbnail image with link parameter
11619 parsoid=wt2html,wt2wt,html2html
11621 [[File:Foobar.jpg|thumb|link=http://example.com/|Title]]
11623 <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"></a></div>Title</div></div></div>
11626 <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>
11630 Manually-specified thumbnail image
11634 [[File:Foobar.jpg|thumb=Thumb.png|Title]]
11636 <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"></a></div>Title</div></div></div>
11639 <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>
11643 Manually-specified thumbnail image with explicit link to wiki page
11646 parsoid=wt2html,wt2wt,html2html
11648 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|Title]]
11650 <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"></a></div>Title</div></div></div>
11653 <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>
11657 Manually-specified thumbnail image with explicit link to url
11660 parsoid=wt2html,wt2wt,html2html
11662 [[File:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
11664 <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"></a></div>Title</div></div></div>
11667 <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>
11671 Manually-specified thumbnail image with explicit no link
11674 parsoid=wt2html,wt2wt,html2html
11676 [[File:Foobar.jpg|thumb=Thumb.png|link=|Title]]
11678 <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"></a></div>Title</div></div></div>
11681 <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>
11685 Manually-specified thumbnail image with explicit link and alt text
11688 parsoid=wt2html,wt2wt,html2html
11690 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|alt=alttext|Title]]
11692 <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"></a></div>Title</div></div></div>
11695 <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>
11699 Image with frame and link
11701 parsoid=wt2html,wt2wt,html2html
11703 [[File:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
11705 <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>
11708 <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" title="Main Page">Main Page</a></figcaption></figure>
11712 Image with frame and link and explicit alt
11714 parsoid=wt2html,wt2wt,html2html
11716 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
11718 <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>
11721 <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" title="Main Page">Main Page</a></figcaption></figure>
11725 Image with wiki markup in implicit alt
11727 parsoid=wt2html,wt2wt,html2html
11729 [[Image:Foobar.jpg|testing '''bold''' in alt]]
11731 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
11733 <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>
11734 </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>
11737 <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>
11738 <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>
11741 ###################
11742 # Conflicting image format options.
11743 # First option specified should 'win'.
11744 # All three cases in each test should be identical.
11747 Image with 'frameless' first.
11749 parsoid=wt2html,wt2wt,html2html
11751 [[File:Foobar.jpg|frameless|caption]]
11753 [[File:Foobar.jpg|frameless|frame|caption]]
11755 [[File:Foobar.jpg|frameless|thumb|caption]]
11757 <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>
11758 </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>
11759 </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>
11762 <p><span class="mw-default-size" 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>
11763 <p><span class="mw-default-size" 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>
11764 <p><span class="mw-default-size" 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>
11768 Image with 'frame' first.
11770 parsoid=wt2html,wt2wt,html2html
11772 [[File:Foobar.jpg|frame|caption]]
11773 [[File:Foobar.jpg|frame|frameless|caption]]
11774 [[File:Foobar.jpg|frame|thumb|caption]]
11776 <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>
11777 <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>
11778 <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>
11781 <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><figcaption>caption</figcaption></figure>
11782 <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><figcaption>caption</figcaption></figure>
11783 <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><figcaption>caption</figcaption></figure>
11787 Image with 'thumb' first.
11789 parsoid=wt2html,wt2wt,html2html
11791 [[File:Foobar.jpg|thumb|caption]]
11792 [[File:Foobar.jpg|thumb|frameless|caption]]
11793 [[File:Foobar.jpg|thumb|frame|caption]]
11795 <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"></a></div>caption</div></div></div>
11796 <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"></a></div>caption</div></div></div>
11797 <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"></a></div>caption</div></div></div>
11800 <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>
11801 <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>
11802 <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>
11805 ###################
11807 # See https://www.mediawiki.org/wiki/Help:Images#Size_and_frame
11808 # and https://bugzilla.wikimedia.org/show_bug.cgi?id=62258
11809 # Foobar has actual size of 1941x220
11810 # 1. Thumbs & frameless always reduce, can't be enlarged unless it's
11811 # a scalable format.
11812 # 2. Framed images always ignore size options; always render at default size.
11813 # 3. "Unspecified format" and border are the only types which can be
11817 Image: "unspecified format" and border enlarge
11819 parsoid=wt2html,wt2wt,html2html
11821 [[File:Foobar.jpg|2000px]]
11823 [[File:Foobar.jpg|border|2000px]]
11825 <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>
11826 </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>
11829 <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>
11830 <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>
11834 Image: "unspecified format" and border reduce
11836 parsoid=wt2html,wt2wt,html2html
11838 [[File:Foobar.jpg|1000px]]
11840 [[File:Foobar.jpg|border|1000px]]
11842 <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>
11843 </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>
11846 <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>
11847 <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>
11851 Image: thumbs reduce
11853 parsoid=wt2html,wt2wt,html2html
11855 [[File:Foobar.jpg|thumb|50px]]
11857 <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"></a></div></div></div></div>
11860 <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>
11864 Image: bitmap thumbs can't be enlarged past original size, but vector can.
11866 parsoid=wt2html,wt2wt,html2html
11868 [[File:Foobar.jpg|thumb|2000px]]
11870 [[File:Foobar.svg|thumb|2000px]]
11872 <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"></a></div></div></div></div>
11873 <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"></a></div></div></div></div>
11876 <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>
11877 <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>
11881 Image: frameless can reduce in size
11883 parsoid=wt2html,wt2wt,html2html
11885 [[File:Foobar.jpg|frameless|50px]]
11887 <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>
11890 <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>
11894 Image: bitmap frameless can't be enlarged past original size, but vector can
11896 parsoid=wt2html,wt2wt,html2html
11898 [[File:Foobar.jpg|frameless|2000px]]
11900 [[File:Foobar.svg|frameless|2000px]]
11902 <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>
11903 </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>
11906 <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>
11907 <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>
11911 Image: framed images are always unscaled.
11913 parsoid=wt2html,wt2wt,html2html
11915 [[File:Foobar.jpg|frame]]
11917 [[File:Foobar.jpg|frame|50px]]
11919 [[File:Foobar.jpg|frame|50x50px]]
11921 [[File:Foobar.jpg|frame|2000px]]
11923 <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>
11924 <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>
11925 <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>
11926 <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>
11929 <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>
11930 <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>
11931 <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>
11932 <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>
11935 ###################
11938 Link to image page- image page normally doesn't exists, hence edit link
11939 Add test with existing image page
11940 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
11944 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
11949 bug 18784 Link to non-existent image page with caption should use caption as link text
11951 [[:Image:test|caption]]
11953 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
11958 Frameless image caption with a free URL
11960 [[File:Foobar.jpg|http://example.com]]
11962 <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>
11965 <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>
11969 Thumbnail image caption with a free URL
11973 [[File:Foobar.jpg|thumb|http://example.com]]
11975 <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"></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
11978 <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>
11982 Thumbnail image caption with a free URL and explicit alt
11985 parsoid=wt2html,wt2wt,html2html
11987 [[File:Foobar.jpg|thumb|http://example.com|alt=Alteration]]
11989 <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"></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
11992 <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>
11996 SVG thumbnails with no language set
11999 [[File:Foobar.svg|thumb|caption]]
12001 <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"></a></div>caption</div></div></div>
12004 <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>
12008 SVG thumbnails with language de
12010 parsoid=wt2html,wt2wt,html2html
12012 [[File:Foobar.svg|thumb|caption|lang=de]]
12014 <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"></a></div>caption</div></div></div>
12017 <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>
12021 SVG thumbnails with invalid language code
12023 parsoid=wt2html,wt2wt,html2html
12025 [[File:Foobar.svg|thumb|caption|lang=invalid.language.code]]
12027 <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"></a></div>lang=invalid.language.code</div></div></div>
12030 <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>
12034 BUG 1887: A ISBN with a thumbnail
12036 [[File:Foobar.jpg|thumb|ISBN 1235467890]]
12038 <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"></a></div><a href="/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div>
12041 <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>
12045 BUG 1887: A RFC with a thumbnail
12047 [[File:Foobar.jpg|thumb|This is RFC 12354]]
12049 <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"></a></div>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
12052 <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>
12056 BUG 1887: A mailto link with a thumbnail
12058 [[File:Foobar.jpg|thumb|Please mailto:nobody@example.com]]
12060 <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"></a></div>Please <a rel="nofollow" class="external free" href="mailto:nobody@example.com">mailto:nobody@example.com</a></div></div></div>
12063 <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>
12066 # Pending resolution to bug 368
12068 BUG 648: Frameless image caption with a link
12070 [[File:Foobar.jpg|text with a [[link]] in it]]
12072 <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>
12075 <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>
12079 BUG 648: Frameless image caption with a link (suffix)
12081 [[File:Foobar.jpg|text with a [[link]]foo in it]]
12083 <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>
12086 <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>
12090 BUG 648: Frameless image caption with an interwiki link
12092 [[File:Foobar.jpg|text with a [[MeatBall:Link]] in it]]
12094 <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>
12097 <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>
12101 BUG 648: Frameless image caption with a piped interwiki link
12103 [[File:Foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
12105 <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>
12108 <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>
12112 Escape HTML special chars in image alt text
12114 [[File:Foobar.jpg|& < > "]]
12116 <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>
12119 <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>
12123 BUG 499: Alt text should have Ӓ, not &1234;
12125 [[File:Foobar.jpg|♀]]
12127 <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>
12130 <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>
12134 Broken image caption with link
12136 parsoid=wt2html,wt2wt,html2html
12138 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
12140 <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.
12143 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="Main_Page" title="Main Page">this</a> is just an ordinary link.</p>
12147 Image caption containing another image
12149 [[File:Foobar.jpg|thumb|This is a caption with another [[File:Thumb.png|image]] inside it!]]
12151 <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"></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>
12154 <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>
12158 Image: caption containing a newline
12160 [[File:Foobar.jpg|This
12163 <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>
12166 <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>
12170 Image: caption containing leading space
12171 (The leading space should not trigger nowiki escaping in wt2wt mode)
12173 [[File:Foobar.jpg|thumb| bar]]
12175 <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"></a></div>bar</div></div></div>
12178 <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>
12182 Image: caption containing a table
12184 parsoid=wt2html,wt2wt,html2html
12186 [[Image:Foobar.jpg|thumb|200px|This is an example image thumbnail caption with a table
12192 and some more text.]]
12194 <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"></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>
12197 <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
12200 <tr><th>Foo </th><th>Bar</th></tr>
12203 <td>Bar1</td></tr></tbody></table>and some more text.</figcaption></figure>
12207 Bug 3090: External links other than http: in image captions
12209 [[File:Foobar.jpg|thumb|200x200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
12211 <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"></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>
12214 <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>
12220 parsoid=wt2html,wt2wt,html2html
12222 [[Image:foobar.jpg|a|class=b]]
12224 <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>
12227 <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>
12231 Localized image handling (1).
12233 parsoid=wt2html,wt2wt,html2html
12236 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
12238 <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>
12241 <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>
12245 Localized image handling (2).
12248 parsoid=wt2html,wt2wt,html2html
12251 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
12253 <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"></a></div>caption</div></div></div>
12256 <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>
12260 "border", "frameless" and "class" attributes on an image.
12263 parsoid=wt2html,wt2wt,html2html
12265 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
12267 <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>
12270 <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>
12273 # Note that 'right' is the default alignment, despite the misspelled 'righ' below
12275 Invalid image attributes (bug 62500)
12278 parsoid=wt2html,wt2wt,html2html
12280 [[File:Foobar.jpg|thumb|float|left|caption]]
12282 [[File:Foobar.jpg|thumb|righ|caption]]
12284 [[File:Foobar.jpg|bogus1|thumb|bogus2|left|bogus3|caption]]
12286 <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"></a></div>caption</div></div></div>
12287 <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"></a></div>caption</div></div></div>
12288 <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"></a></div>caption</div></div></div>
12291 <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>
12292 <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>
12293 <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>
12299 #REDIRECT [[File:Barfoo.jpg]]
12302 # FIXME: Parsoid should run this test -- but we'd need to teach the
12303 # mockAPI about the redirected Barfoo.jpg image.
12307 [[Image:Barfoo.jpg]]
12309 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
12314 Missing image with uploads disabled
12318 [[File:Foobaz.jpg]]
12320 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
12323 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="File:Foobaz.jpg"><img resource="./File:Foobaz.jpg" src="./Special:FilePath/Foobaz.jpg" height="220" width="220"/></a></span></p>
12326 # Parsoid-specific testing for images
12327 # https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
12328 # Currently imperfect due to a flaw in the Parsoid testrunner
12330 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
12334 Parsoid-specific image handling - simple image with size and middle alignment
12336 [[File:Foobar.jpg|middle|50px]]
12338 <p><span class="mw-valign-middle" typeof="mw:Image"><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"></a></span></p>
12342 Parsoid-specific image handling - simple image with size, middle alignment,
12343 non-standard namespace alias
12345 parsoid=wt2wt,wt2html,html2html
12347 [[Image:Foobar.jpg|middle|50px]]
12349 <p><span class="mw-valign-middle" typeof="mw:Image"><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"></a></span></p>
12353 Parsoid-specific image handling - simple image with size and middle alignment
12356 [[File:Foobar.jpg|50px|middle]]
12358 <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>
12362 Parsoid-specific image handling - simple image with size and middle alignment
12363 and non-standard namespace name
12365 parsoid=wt2html,wt2wt,html2html
12367 [[Image:Foobar.jpg|50px|middle]]
12369 <p><span class="mw-valign-middle" typeof="mw:Image"><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"></a></span></p>
12373 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
12375 [[File:Foobar.jpg|500x10px|baseline|caption]]
12377 <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>
12381 Parsoid-specific image handling - simple image with border and size spec
12383 [[File:Foobar.jpg|50px|border|caption]]
12385 <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>
12389 Parsoid-specific image handling - thumbnail with halign, valign, and caption
12391 [[File:Foobar.jpg|left|baseline|thumb|caption content]]
12393 <figure class="mw-default-size mw-halign-left mw-valign-baseline" 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><figcaption>caption content</figcaption></figure>
12397 Parsoid-specific image handling - thumbnail with halign, valign, and caption
12400 [[File:Foobar.jpg|thumb|left|baseline|caption content]]
12402 <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>
12406 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
12408 [[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
12410 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb"><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" /></a><figcaption>caption</figcaption></figure>
12414 Parsoid-specific image handling - thumbnail with specific size, halign,
12415 valign, and caption (existing content)
12417 [[File:Foobar.jpg|thumb|50x50px|right|middle|caption]]
12419 <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>
12423 Parsoid-specific image handling - framed image with specific size and caption
12426 parsoid=wt2html,wt2wt,html2html
12428 [[File:Foobar.jpg|frame|500x50px|caption]]
12430 <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><figcaption>caption</figcaption></figure>
12434 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
12437 parsoid=wt2html,wt2wt,html2html
12439 [[File:Foobar.jpg|left|baseline|frame|500x50px|caption]]
12441 <figure class="mw-halign-left mw-valign-baseline" 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>caption</figcaption></figure>
12445 Parsoid-specific image handling - frameless image with specific size, border, and caption
12447 [[File:Foobar.jpg|frameless|442x50px|border|caption]]
12449 <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>
12453 Parsoid-specific image handling - simple image with a formatted caption
12455 [[File:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
12457 <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>"}'><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>
12461 Parsoid-specific image handling - caption with a template in it
12463 [[File:Foobar.jpg|thumb|200x23px|This caption has a {{echo|transclusion}} in it.]]
12465 <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>
12469 Parsoid-specific image handling - caption with unbalanced tags in it
12471 parsoid=wt2html,wt2wt,html2html
12474 [[File:Foobar.jpg|thumb|200x200px|This caption has a <center>unbalanced tag in it.]]
12478 <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>
12483 Parsoid-specific image handling - empty caption (1)
12485 parsoid=wt2html,wt2wt
12487 [[File:Foobar.jpg|thumb|]]
12489 <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>
12492 # empty captions don't get serialized unless we're in the "round trip" case
12494 Parsoid-specific image handling - empty caption (2)
12498 <figure class="mw-default-size" typeof="mw:Image/Thumb">
12499 <a href="File:Foobar.jpg">
12500 <img resource="./File:Foobar.jpg"
12501 src="//example.com/images/3/3a/Foobar.jpg"
12502 height="25" width="220"/>
12504 <figcaption></figcaption>
12507 [[File:Foobar.jpg|thumb]]
12511 Parsoid-specific image handling - whitespace caption
12513 [[File:Foobar.jpg|thumb| ]]
12515 <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>
12519 Parsoid-specific image handling - lang option
12522 [[File:Foobar.svg|lang=de|caption]]
12526 <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>
12535 Subpage test/subpage
12543 subpage title=[[Subpage test]]
12547 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
12552 Subpage noslash link
12554 subpage title=[[Subpage test]]
12558 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
12563 Subpage test/1/2/subpage
12569 Relative subpage noslash link
12571 parsoid=wt2wt,wt2html,html2html
12572 subpage title=[[Subpage test/1/2/3/4]]
12578 <p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a>
12579 </p><p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage test/1/2/subpage</a>
12582 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a></p>
12583 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
12587 Parsoid: dot-slash prefixed wikilinks
12597 </p><p>[[././baz/]]
12602 </p><p>[[././baz/]]
12607 Render invalid page names as plain text (bug 51090)
12620 [[{{echo|./../foo}}|bar]]
12621 [[{{echo|foo/.}}|bar]]
12622 [[{{echo|foo/..}}|bar]]
12623 [[{{echo|foo~~~~bar}}]]
12624 [[{{echo|foo>bar}}]]
12625 [[{{echo|foo././bar}}]]
12626 [[{{echo|foo{bar}}]]
12627 [[{{echo|foo}bar}}]]
12628 [[{{echo|foo[bar}}]]
12629 [[{{echo|foo]bar}}]]
12630 [[{{echo|foo<bar}}]]
12632 <p>[[./../foo|bar]]
12642 </p><p>[[./../foo|bar]]
12655 <p>[[./../foo|bar]]
12666 <p>[[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"./../foo"}},"i":0}}]}'>./../foo</span>|bar]]
12667 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/."}},"i":0}}]}'>foo/.</span>|bar]]
12668 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/.."}},"i":0}}]}'>foo/..</span>|bar]]
12669 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo~~~~bar"}},"i":0}}]}'>foo~~~~bar</span>]]
12670 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo>bar"}},"i":0}}]}'>foo>bar</span>]]
12671 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo././bar"}},"i":0}}]}'>foo././bar</span>]]
12672 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo{bar"}},"i":0}}]}'>foo{bar</span>]]
12673 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo}bar"}},"i":0}}]}'>foo}bar</span>]]
12674 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo[bar"}},"i":0}}]}'>foo[bar</span>]]
12675 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo]bar"}},"i":0}}]}'>foo]bar</span>]]
12676 [[<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>
12684 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
12689 BUG 561: {{/Subpage}}
12691 subpage title=[[Page]]
12695 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
12703 Category:MediaWiki User's Guide
12711 [[:Category:MediaWiki User's Guide]]
12713 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
12722 [[Category:MediaWiki User's Guide]]
12724 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
12728 PAGESINCATEGORY invalid title fatal (r33546 fix)
12730 {{PAGESINCATEGORY:<bogus>}}
12737 Category with different sort key
12741 [[Category:MediaWiki User's Guide|Foo]]
12743 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
12747 Category with identical sort key
12751 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
12753 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
12757 Category with empty sort key
12762 [[Category:MediaWiki User's Guide|]]
12764 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
12768 Category with empty sort key and parentheses
12773 [[Category:Foo (bar)|]]
12775 [[Category:Foo (bar)|Foo]]
12779 Category with link tail
12784 123[[Category:Foo]]456
12786 123[[Category:Foo]]456
12790 Category with template
12795 [[Category:{{echo|Foo}}]]
12797 [[Category:{{echo|Foo}}]]
12801 Category with template in sort key
12806 [[Category:Foo|{{echo|Bar}}]]
12808 [[Category:Foo|{{echo|Bar}}]]
12812 Category with template in sort key and title
12817 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
12819 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
12823 Category / paragraph interactions
12825 Foo [[Category:Baz]] Bar
12827 Foo [[Category:Baz]]
12835 [[Category:Baz]] Bar
12848 {{echo|[[Category:Baz]]}}
12863 Parsoid: Serialize link to category page with colon escape
12869 [[:Category:Foo|Bar]]
12872 <a rel="mw:WikiLink" href="Category:Foo" title="Category:Foo">Category:Foo</a>
12873 <a rel="mw:WikiLink" href="Category:Foo" title="Category:Foo">Bar</a>
12878 Parsoid: Link prefix/suffixes aren't applied to category links
12880 parsoid=wt2html,wt2wt,html2html
12885 <p>x<link rel="mw:PageProp/Category" href="Category:Foo">y</p>
12889 Parsoid: Serialize link to file page with colon escape
12895 [[:File:Foo.png|Bar]]
12898 <a rel="mw:WikiLink" href="File:Foo.png" title="File:Foo.png">File:Foo.png</a>
12899 <a rel="mw:WikiLink" href="File:Foo.png" title="File:Foo.png">Bar</a>
12904 Parsoid: Serialize a genuine category link without colon escape
12909 [[Category:Foo|Bar]]
12911 <link rel="mw:PageProp/Category" href="Category:Foo">
12912 <link rel="mw:PageProp/Category" href="Category:Foo#Bar">
12916 Normalize hrefs properly before testing for invalid link targets (bug 70894)
12920 <link rel="mw:PageProp/Category" href="./Category:Toxine_bactérienne"/>
12922 [[Category:Toxine bactérienne]]
12926 Parsoid: Defaultsort
12930 {{DEFAULTSORT:Foo}}
12932 <meta property="mw:PageProp/categorydefaultsort" content="Foo"/>
12936 ### Inter-language links
12939 Interlanguage links
12947 es:Alimento fr:Nourriture zh:食品
12949 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Alimento"/>
12950 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/Nourriture"/>
12951 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/食品"/>
12955 Duplicate interlanguage links (bug 24502)
12966 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/1"/>
12967 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/2"/>
12968 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/1"/>
12969 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/2"/>
12976 Basic section headings
12983 ===Smaller headline===
12986 <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>
12989 <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>
12992 <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>
12998 Section headings with TOC
13001 === Subheadline 1 ===
13002 ===== Skipping a level =====
13003 ====== Skipping a level ======
13007 ===Another headline===
13009 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13011 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
13013 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
13015 <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>
13017 <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>
13024 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
13026 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
13032 <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>
13033 <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>
13034 <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>
13035 <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>
13036 <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>
13039 <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>
13043 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
13045 Handling of sections up to level 6 and beyond
13048 == Level 2 Heading==
13049 === Level 3 Heading===
13050 ==== Level 4 Heading====
13051 ===== Level 5 Heading=====
13052 ====== Level 6 Heading======
13053 ======= Level 7 Heading=======
13054 ======== Level 8 Heading========
13055 ========= Level 9 Heading=========
13056 ========== Level 10 Heading==========
13058 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13060 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
13062 <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>
13064 <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>
13066 <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>
13068 <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>
13070 <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>
13071 <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>
13072 <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>
13073 <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>
13074 <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>
13088 <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>
13089 <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>
13090 <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>
13091 <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>
13092 <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>
13093 <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>
13094 <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>
13095 <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>
13096 <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>
13097 <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>
13102 TOC regression (bug 9764)
13106 ==== title 1.1.1 ====
13111 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13113 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
13115 <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>
13117 <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>
13120 <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>
13123 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
13125 <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>
13131 <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>
13132 <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>
13133 <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>
13134 <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>
13135 <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>
13136 <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>
13141 TOC with wgMaxTocLevel=3 (bug 6204)
13147 ==== title 1.1.1 ====
13152 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13154 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
13156 <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>
13157 <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>
13160 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
13162 <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>
13168 <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>
13169 <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>
13170 <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>
13171 <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>
13172 <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>
13173 <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>
13178 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
13184 ====Section 1.1.1====
13185 ====Section 1.1.1.1====
13188 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13190 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
13192 <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>
13195 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
13199 <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>
13200 <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>
13201 <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>
13202 <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>
13203 <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>
13209 Resolving duplicate section names
13214 <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>
13215 <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>
13220 Resolving duplicate section names with differing case (bug 10721)
13225 <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>
13226 <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>
13238 Template with sections, __NOTOC__
13245 <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>
13246 <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>
13247 <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>
13248 <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>
13253 __NOEDITSECTION__ keyword
13259 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
13260 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
13265 Link inside a section heading
13267 ==Section with a [[Main Page|link]] in it==
13269 <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>
13274 TOC regression (bug 12077)
13281 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13283 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
13285 <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>
13288 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
13292 <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>
13293 <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>
13294 <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>
13299 BUG 1219 URL next to image (good)
13301 http://example.com [[Image:foobar.jpg]]
13303 <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>
13308 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
13311 The line above must have a trailing space!
13314 But just in case it doesn't...
13316 <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>
13317 <p>The line above must have a trailing space!
13319 <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>
13320 <p>But just in case it doesn't...
13325 Header with special characters (bug 25462)
13327 The tooltips shall not show entities to the user (ie. be double escaped)
13344 <p>The tooltips shall not show entities to the user (ie. be double escaped)
13346 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13348 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
13349 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
13350 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
13351 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
13352 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
13356 <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>
13359 <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>
13362 <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>
13365 <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>
13368 <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>
13374 Header with space, plus and underscore as entity
13376 Id should not contain + for spaces
13378 == Space between Text ==
13381 == Space-Entity between Text ==
13384 == Plus+between+Text ==
13387 == Plus-Entity+between+Text ==
13390 == Underscore_between_Text ==
13393 == Underscore-Entity_between_Text ==
13396 [[#Space between Text]]
13397 [[#Space-Entity between Text]]
13398 [[#Plus+between+Text]]
13399 [[#Plus-Entity+between+Text]]
13400 [[#Underscore_between_Text]]
13401 [[#Underscore-Entity_between_Text]]
13403 <p>Id should not contain + for spaces
13405 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13407 <li class="toclevel-1 tocsection-1"><a href="#Space_between_Text"><span class="tocnumber">1</span> <span class="toctext">Space between Text</span></a></li>
13408 <li class="toclevel-1 tocsection-2"><a href="#Space-Entity_between_Text"><span class="tocnumber">2</span> <span class="toctext">Space-Entity between Text</span></a></li>
13409 <li class="toclevel-1 tocsection-3"><a href="#Plus.2Bbetween.2BText"><span class="tocnumber">3</span> <span class="toctext">Plus+between+Text</span></a></li>
13410 <li class="toclevel-1 tocsection-4"><a href="#Plus-Entity.2Bbetween.2BText"><span class="tocnumber">4</span> <span class="toctext">Plus-Entity+between+Text</span></a></li>
13411 <li class="toclevel-1 tocsection-5"><a href="#Underscore_between_Text"><span class="tocnumber">5</span> <span class="toctext">Underscore_between_Text</span></a></li>
13412 <li class="toclevel-1 tocsection-6"><a href="#Underscore-Entity_between_Text"><span class="tocnumber">6</span> <span class="toctext">Underscore-Entity_between_Text</span></a></li>
13416 <h2><span class="mw-headline" id="Space_between_Text">Space between 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: Space between Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13419 <h2><span class="mw-headline" id="Space-Entity_between_Text">Space-Entity between 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: Space-Entity between Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13422 <h2><span class="mw-headline" id="Plus.2Bbetween.2BText">Plus+between+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: Plus+between+Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13425 <h2><span class="mw-headline" id="Plus-Entity.2Bbetween.2BText">Plus-Entity+between+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: Plus-Entity+between+Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13428 <h2><span class="mw-headline" id="Underscore_between_Text">Underscore_between_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: Underscore between Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13431 <h2><span class="mw-headline" id="Underscore-Entity_between_Text">Underscore-Entity_between_Text</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: Underscore-Entity_between_Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13433 </p><p><a href="#Space_between_Text">#Space between Text</a>
13434 <a href="#Space-Entity_between_Text">#Space-Entity between Text</a>
13435 <a href="#Plus.2Bbetween.2BText">#Plus+between+Text</a>
13436 <a href="#Plus-Entity.2Bbetween.2BText">#Plus-Entity+between+Text</a>
13437 <a href="#Underscore_between_Text">#Underscore_between_Text</a>
13438 <a href="#Underscore-Entity_between_Text">#Underscore-Entity_between_Text</a>
13443 Headers with excess '=' characters
13444 (Are similar tests necessary beyond the 1st level?)
13448 =''italic'' heading==
13449 ==''italic'' heading=
13451 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13453 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
13454 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
13455 <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>
13456 <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>
13460 <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>
13461 <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>
13462 <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>
13463 <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>
13468 HTML headers vs TOC (bug 23393)
13469 (__NOEDITSECTION__ for clearer output, doesn't matter here)
13481 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13483 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
13485 <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>
13486 <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>
13489 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
13491 <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>
13492 <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>
13498 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
13499 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
13500 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
13501 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
13502 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
13503 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
13508 Single-line or multiline-comments can follow headings
13510 parsoid=wt2html,wt2wt
13518 <h2><span class="mw-headline" id="foo">foo</span></h2>
13519 <h2><span class="mw-headline" id="bar">bar</span></h2>
13520 <h2><span class="mw-headline" id="baz">baz</span></h2>
13525 BUG 1219 URL next to image (broken)
13527 http://example.com[[Image:foobar.jpg]]
13529 <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>
13534 Bug 1186 news: in the middle of text
13536 http://en.wikinews.org/wiki/Wikinews:Workplace
13538 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
13544 Namespaced link must have a title
13553 Namespaced link must have a title (bad fragment version)
13555 [[Project:#fragment]]
13557 <p>[[Project:#fragment]]
13563 ### HTML tags and HTML attributes
13567 div with no attributes
13569 <div>HTML rocks</div>
13571 <div>HTML rocks</div>
13576 div with double-quoted attribute
13578 <div id="rock">HTML rocks</div>
13580 <div id="rock">HTML rocks</div>
13585 div with single-quoted attribute
13587 <div id='rock'>HTML rocks</div>
13589 <div id="rock">HTML rocks</div>
13594 div with unquoted attribute
13596 <div id=rock>HTML rocks</div>
13598 <div id="rock">HTML rocks</div>
13603 div with illegal double attributes
13605 <div id="a" id="b">HTML rocks</div>
13607 <div id="b">HTML rocks</div>
13611 # FIXME: produce empty string instead of "class" in the PHP parser, following
13614 div with empty attribute value, space before equals
13618 <div class =>HTML rocks</div>
13620 <div class="">HTML rocks</div>
13625 div with multiple empty attribute values
13629 <div id= title=>HTML rocks</div>
13631 <div id="" title="">HTML rocks</div>
13636 table with multiple empty attribute values
13644 <table title="" id="">
13645 <tbody><tr><td> hi</td></tr>
13650 div with braces in attribute value
13652 <div title="{}">Foo</div>
13654 <div title="{}">Foo</div>
13657 <div title="{}">Foo</div>
13660 # This it very inconsistent in the PHP parser: it returns
13661 # class="class" if there is a space between the name and the equal sign (see
13662 # 'div with empty attribute value, space before equals'), but strips the
13663 # attribute completely if the space is missing. We hope that not much content
13664 # depends on this, so are implementing the behavior below in Parsoid for
13665 # consistencies' sake.
13666 # FIXME: fix this behavior in the PHP parser?
13668 div with empty attribute value, no space before equals
13670 parsoid=wt2html,html2html
13672 <div class=>HTML rocks</div>
13674 <div>HTML rocks</div>
13677 <div class="">HTML rocks</div>
13681 HTML multiple attributes correction
13683 <p class="error" class="awesome">Awesome!</p>
13685 <p class="awesome">Awesome!</p>
13690 Table multiple attributes correction
13693 !+ class="error" class="awesome"| status
13698 <th class="awesome"> status
13706 <DIV ID="x">HTML ROCKS</DIV>
13708 <div id="x">HTML ROCKS</div>
13713 Non-ASCII pseudo-tags are rendered as text
13722 Pseudo-tag with URL 'name' renders as url link
13724 <http://example.com/>
13726 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
13731 text with amp in the middle of nowhere
13735 <p>Remember AT&T?
13740 text with character entity: eacute
13742 I always thought é was a cute letter.
13744 <p>I always thought é was a cute letter.
13747 <p>I always thought é was a cute letter.</p>
13751 text with entity-escaped character entity-like string: eacute
13753 I always thought &eacute; was a cute letter.
13755 <p>I always thought &eacute; was a cute letter.
13760 text with undefined character entity: xacute
13762 I always thought &xacute; was a cute letter.
13764 <p>I always thought &xacute; was a cute letter.
13768 # TODO: generalize to PHP parser?
13774 <data value="5">five</data>
13775 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
13776 <mark>This highlighted text</mark>
13778 <p><data value="5">five</data>
13779 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
13780 <mark>This highlighted text</mark></p>
13784 HTML tag with leading space is parsed as text
13788 <p>< div>foo< /div>
13793 ### Nesting tests (see bug 41545, 50604, 51081)
13796 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
13797 # Note that html2wt is considerably more difficult if we use <b> in
13798 # the test case, instead of <big>
13800 Ensure that HTML adoption agency algorithm is properly implemented.
13802 <big>X<big>Y</big>Z</big>
13804 <p><big>X<big>Y</big>Z</big>
13808 # This was bug 41545 in the PHP parser.
13809 # Note that tidy doesn't handle this correctly.
13813 <kbd>X<kbd>Y</kbd>Z</kbd>
13815 <p><kbd>X<kbd>Y</kbd>Z</kbd>
13819 # The following cases were bug 51081 in the PHP parser.
13820 # Note that there are some other nestable tags (b, i, etc) which are
13821 # not covered; see bug 51081 for discussion.
13823 # Note that tidy doesn't handle this correctly.
13827 <em>X<em>Y</em>Z</em>
13829 <p><em>X<em>Y</em>Z</em>
13833 # Note that tidy doesn't handle this correctly.
13835 Nesting of <strong>
13837 <strong>X<strong>Y</strong>Z</strong>
13839 <p><strong>X<strong>Y</strong>Z</strong>
13848 <p><q>X<q>Y</q>Z</q></p>
13851 # Note that tidy doesn't handle this correctly.
13855 <ruby>X<ruby>Y</ruby>Z</ruby>
13857 <p><ruby>X<ruby>Y</ruby>Z</ruby>
13861 # Note that tidy doesn't handle this correctly.
13865 <bdo>X<bdo>Y</bdo>Z</bdo>
13867 <p><bdo>X<bdo>Y</bdo>Z</bdo>
13879 [[Media:Foobar.jpg]]
13881 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
13886 Media link with text
13888 [[Media:Foobar.jpg|A neat file to look at]]
13890 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
13894 # FIXME: this is still bad HTML tag nesting
13896 Media link with nasty text
13897 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
13899 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
13901 <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>
13904 <p><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></p>
13908 Media link to nonexistent file (bug 1702)
13910 [[Media:No such.jpg]]
13912 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
13917 Image link to nonexistent file (bug 1850 - good)
13919 [[File:No_such.jpg]]
13921 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
13924 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="File:No_such.jpg"><img resource="./File:No_such.jpg" src="./Special:FilePath/No_such.jpg" height="220" width="220"/></a></span></p>
13928 :Image link to nonexistent file (bug 1850 - bad)
13930 [[:Image:No such.jpg]]
13932 <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>
13935 <p><a rel="mw:WikiLink" href="./File:No_such.jpg" title="File:No such.jpg">Image:No such.jpg</a></p>
13941 Character reference normalization in link text (bug 1938)
13943 [[Main Page|this&that]]
13945 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
13952 Test for unicode normalization
13954 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
13958 (bug 19451) Links should refer to the normalized form.
13966 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13967 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13968 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13969 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13970 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13975 Empty attribute crash test (bug 2067)
13977 <font color="">foo</font>
13979 <p><font color="">foo</font>
13984 Empty attribute crash test single-quotes (bug 2067)
13986 <font color=''>foo</font>
13988 <p><font color="">foo</font>
13993 Attribute test: equals, then nothing
13995 <font color=>foo</font>
13997 <p><font>foo</font>
14002 Attribute test: unquoted value
14004 <font color=x>foo</font>
14006 <p><font color="x">foo</font>
14011 Attribute test: unquoted but illegal value (hash)
14013 <font color=#x>foo</font>
14015 <p><font color="#x">foo</font>
14020 Attribute test: no value
14022 <font color>foo</font>
14024 <p><font color="color">foo</font>
14029 Bug 2095: link with three closing brackets
14033 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
14036 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a>]</p>
14040 Bug 2095: link with pipe and three closing brackets
14042 [[Main Page|link]]]
14044 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
14047 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">link</a>]</p>
14051 Bug 2095: link with pipe and three closing brackets, version 2
14053 [[Main Page|[http://example.com/]]]
14055 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
14058 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">[http://example.com/]</a></p>
14067 Template:Dangerous attribute
14069 " onmouseover="alert(document.cookie)
14073 Template:Dangerous style attribute
14075 border-size: expression(alert(document.cookie))
14081 <div style="float: right; {{{1}}}">Magic div</div>
14085 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
14087 <div title="{{test}}"></div>
14089 <div title="This is a test template"></div>
14093 # Parsoid has enough context to handle this case
14095 Bug 2304: HTML attribute safety (dangerous template; 2309)
14097 <div title="{{dangerous attribute}}"></div>
14099 <div title=""></div>
14102 <div title='" onmouseover="alert(document.cookie)' about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html","a":{"title":"\" onmouseover=\"alert(document.cookie)"},"sa":{"title":"{{dangerous attribute}}"}}' data-mw='{"attribs":[[{"txt":"title"},{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid=\"{&quot;pi&quot;:[[]],&quot;dsr&quot;:[12,35,null,null]}\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;dangerous attribute&quot;,&quot;href&quot;:&quot;./Template:Dangerous_attribute&quot;},&quot;params&quot;:{},&quot;i&quot;:0}}]}\">\" onmouseover=\"alert(document.cookie)</span>"}]]}'></div>
14106 Bug 2304: HTML attribute safety (dangerous style template; 2309)
14108 <div style="{{dangerous style attribute}}"></div>
14110 <div style="/* insecure input */"></div>
14115 Bug 2304: HTML attribute safety (safe parameter; 2309)
14117 {{div style|width: 200px}}
14119 <div style="float: right; width: 200px">Magic div</div>
14124 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
14126 {{div style|width: expression(alert(document.cookie))}}
14128 <div style="/* insecure input */">Magic div</div>
14133 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
14135 {{div style|"><script>alert(document.cookie)</script>}}
14137 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
14142 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
14144 {{div style|" ><script>alert(document.cookie)</script>}}
14146 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
14151 Bug 2304: HTML attribute safety (link)
14153 <div title="[[Main Page]]"></div>
14155 <div title="[[Main Page]]"></div>
14160 Bug 2304: HTML attribute safety (italics)
14162 <div title="''foobar''"></div>
14164 <div title="''foobar''"></div>
14169 Bug 2304: HTML attribute safety (bold)
14171 <div title="'''foobar'''"></div>
14173 <div title="'''foobar'''"></div>
14179 Bug 2304: HTML attribute safety (ISBN)
14181 <div title="ISBN 1234567890"></div>
14183 <div title="ISBN 1234567890"></div>
14188 Bug 2304: HTML attribute safety (RFC)
14190 <div title="RFC 1234"></div>
14192 <div title="RFC 1234"></div>
14197 Bug 2304: HTML attribute safety (PMID)
14199 <div title="PMID 1234567890"></div>
14201 <div title="PMID 1234567890"></div>
14206 Bug 2304: HTML attribute safety (web link)
14208 <div title="http://example.com/"></div>
14210 <div title="http://example.com/"></div>
14215 Bug 2304: HTML attribute safety (named web link)
14217 <div title="[http://example.com/ link]"></div>
14219 <div title="[http://example.com/ link]"></div>
14224 Bug 3244: HTML attribute safety (extension; safe)
14226 <div style="<nowiki>background:blue</nowiki>"></div>
14228 <div style="background:blue"></div>
14233 Bug 3244: HTML attribute safety (extension; unsafe)
14235 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
14237 <div style="/* insecure input */"></div>
14241 # More MSIE fun discovered by Tom Gilder
14244 MSIE CSS safety test: spurious slash
14246 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
14248 <div style="/* insecure input */">evil</div>
14253 MSIE CSS safety test: hex code
14255 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
14257 <div style="/* insecure input */">evil</div>
14262 MSIE CSS safety test: comment in url
14264 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
14266 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
14271 MSIE CSS safety test: comment in expression
14273 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
14275 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
14280 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
14282 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
14284 <p style="/* invalid control char */">A</p>
14289 MSIE 6 CSS safety test: Fullwidth (bug 55332)
14291 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
14292 <div style="top:EXPRESSION(alert())">B</div>
14294 <p style="/* insecure input */">A</p>
14295 <div style="/* insecure input */">B</div>
14300 MSIE 6 CSS safety test: IPA extensions (bug 55332)
14302 <div style="background-image:uʀʟ(javascript:alert())">A</div>
14303 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
14305 <div style="/* insecure input */">A</div>
14306 <p style="/* insecure input */">B</p>
14311 MSIE 6 CSS safety test: sup/sub script (bug 55332)
14313 <div style="background-image:url⁽javascript:alert())">A</div>
14314 <div style="background-image:url₍javascript:alert())">B</div>
14315 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
14317 <div style="/* insecure input */">A</div>
14318 <div style="/* insecure input */">B</div>
14319 <p style="/* insecure input */">C</p>
14327 title="data:text/html,<img src=1 onerror=alert(1)>"
14328 style="-o-link:attr(title);-o-link-source:current">X</div>
14330 <div title="data:text/html,<img src=1 onerror=alert(1)>" style="/* insecure input */">X</div>
14335 MSIE 6 CSS safety test: Repetition markers (bug 55332)
14337 <p style="font-size: 100px; color: expres〱ion((title='XSSed'),'red')">A</p>
14338 <p style="font-size: 100px; color: expresゝion((title='XSSed'),'red')">B</p>
14339 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">C</p>
14340 <p style="font-size: 100px; color: expresヽion((title='XSSed'),'red')">D</p>
14341 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
14342 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
14343 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
14345 <p style="/* insecure input */">A</p>
14346 <p style="/* insecure input */">B</p>
14347 <p style="/* insecure input */">C</p>
14348 <p style="/* insecure input */">D</p>
14349 <p style="/* insecure input */">E</p>
14350 <p style="/* insecure input */">F</p>
14351 <p style="/* insecure input */">G</p>
14356 Table attribute legitimate extension
14359 !+ style="<nowiki>color:blue</nowiki>"| status
14364 <th style="color:blue"> status
14370 Table attribute safety
14373 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
14378 <th style="/* insecure input */"> status
14384 CSS line continuation 1
14386 <div style="background-image: u\ rl(test.jpg);"></div>
14388 <div style="/* insecure input */"></div>
14393 CSS line continuation 2
14395 <div style="background-image: u\ rl(test.jpg); "></div>
14397 <div style="/* insecure input */"></div>
14408 Expansion of multi-line templates in attribute values (bug 6255)
14410 <div style="background: {{identity|#00FF00}}">-</div>
14412 <div style="background: #00FF00">-</div>
14418 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
14420 <div style="background:
14423 <div style="background: #00FF00">-</div>
14426 <div style="background:
14431 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
14433 <div style="background: #00FF00">-</div>
14435 <div style="background: #00FF00">-</div>
14440 evil <math>-wiki-tags without Extension:Math enabled
14442 <math><img src="some evil external link"><script>some_evil_javascript();</script></math>
14444 <p><math><img src="some evil external link"><script>some_evil_javascript();</script></math></p>
14448 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
14451 Parser hook: empty input
14464 Parser hook: empty input using terminated empty elements
14477 Parser hook: empty input using terminated empty elements (space before)
14490 Parser hook: basic input
14504 Parser hook: case insensitive
14518 Parser hook: case insensitive, redux
14531 Parser hook: nested tags
14535 <tag><tag></tag></tag>
14546 Parser hook: basic arguments
14548 <tag width=200 height = "100" depth = '50' square></tag>
14556 'square' => 'square',
14563 Parser hook: argument containing a forward slash (bug 5344)
14565 <tag filename='/tmp/bla'></tag>
14570 'filename' => '/tmp/bla',
14577 Parser hook: empty input using terminated empty elements (bug 2374)
14590 # </tag> should be output literally since there is no matching tag that begins it
14592 Parser hook: basic arguments using terminated empty elements (bug 2374)
14594 <tag width=200 height = "100" depth = '50' square/>
14604 'square' => 'square',
14613 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
14617 Parser hook: static parser hook not inside a comment
14619 <statictag>hello, world</statictag>
14620 <statictag action=flush/>
14628 Parser hook: static parser hook inside a comment
14630 <!-- <statictag>hello, world</statictag> -->
14631 <statictag action=flush/>
14637 # Nested template calls; this case was broken by Parser.php rev 1.506,
14641 Template:One-parameter
14643 (My parameter is: {{{1}}})
14647 Template:Map-one-parameter
14649 {{{{{1}}}|{{{2}}}}}
14653 Nested template calls
14655 {{Map-one-parameter|One-parameter|param}}
14657 <p>(My parameter is: param)
14666 # HTML+Tidy effectively strips out the empty tags completely
14667 # But since Parsoid doesn't it wraps the <s></s> tags in p-tags
14668 # which Tidy would have done for the PHP parser had there been content inside it.
14670 Sanitizer: Closing of open tags
14672 <s></s><table></table>
14674 <s></s><table></table>
14677 <p><s></s></p><table></table>
14681 Sanitizer: Closing of open but not closed tags
14690 Sanitizer: Closing of closed but not open tags
14699 Sanitizer: Closing of closed but not open table tags
14701 Table not started</td></tr></table>
14703 <p>Table not started</td></tr></table>
14708 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
14710 <span id="æ: v">byte</span>[[#æ: v|backlink]]
14712 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
14716 # In HTML5, the restrictions are that id must contain at least one character,
14717 # and must not contain any space characters.
14719 Sanitizer: Validating the contents of the id attribute (bug 4515)
14723 <br id="" /><br id="a space" />
14728 # In HTML5, id must be unique amongst all the ids in the element's home subtree.
14730 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
14734 <br id="foo" /><br id="foo" />
14736 Something need to be done. foo-2 ?
14740 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
14743 <meta itemprop="hello" content="world">
14744 <meta http-equiv="refresh" content="5">
14745 <meta itemprop="hello" http-equiv="refresh" content="5">
14746 <link itemprop="hello" href="{{SERVER}}">
14747 <link rel="stylesheet" href="{{SERVER}}">
14748 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
14751 <div itemscope="itemscope">
14752 <p> <meta itemprop="hello" content="world" />
14753 <meta http-equiv="refresh" content="5">
14754 <meta itemprop="hello" content="5" />
14756 <link itemprop="hello" href="http://example.org" />
14757 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
14758 <link itemprop="hello" href="http://example.org" />
14764 Language converter: output gets cut off unexpectedly (bug 5757)
14768 this bit is safe: }-
14770 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
14772 then we get cut off here: }-
14774 all additional text is vanished
14776 <p>this bit is safe: }-
14777 </p><p>but if we add a conversion instance: xxx
14778 </p><p>then we get cut off here: }-
14779 </p><p>all additional text is vanished
14784 Self closed html pairs (bug 5487)
14787 <center><font id="bug" />Centered text</center>
14788 <div><font id="bug2" />In div text</div>
14790 <center><font id="bug" />Centered text</center>
14791 <div><font id="bug2" />In div text</div>
14800 Punctuation: nbsp before exclamation
14804 <p>C'est grave !
14809 Punctuation: CSS !important (bug 11874)
14811 <div style="width:50% !important">important</div>
14813 <div style="width:50% !important">important</div>
14818 Punctuation: CSS ! important (bug 11874; with space after)
14820 <div style="width:50% ! important">important</div>
14822 <div style="width:50% ! important">important</div>
14828 HTML bullet list, closed tags (bug 5497)
14841 <ul data-parsoid='{"stx":"html"}'>
14842 <li data-parsoid='{"stx":"html"}'>One</li>
14843 <li data-parsoid='{"stx":"html"}'>Two</li>
14849 HTML bullet list, unclosed tags (bug 5497)
14861 <ul data-parsoid='{"stx":"html"}'>
14862 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>One</li>
14863 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>Two</li>
14869 HTML ordered list, closed tags (bug 5497)
14882 <ol data-parsoid='{"stx":"html"}'>
14883 <li data-parsoid='{"stx":"html"}'>One</li>
14884 <li data-parsoid='{"stx":"html"}'>Two</li>
14890 HTML ordered list, unclosed tags (bug 5497)
14903 <ol data-parsoid='{"stx":"html"}'>
14904 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>One</li>
14905 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>Two</li>
14911 HTML nested bullet list, closed tags (bug 5497)
14936 HTML nested bullet list, open tags (bug 5497)
14973 HTML nested ordered list, closed tags (bug 5497)
14998 HTML nested ordered list, open tags (bug 5497)
15035 HTML ordered list item with parameters oddity
15037 <ol><li id="fragment">One</li>
15040 <ol><li id="fragment">One</li>
15045 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
15047 bug 5918: autonumbering
15049 [http://first/] [http://second] [ftp://ftp]
15053 [mailto:enclosed@mail.tld With target]
15055 [mailto:enclosed@mail.tld]
15057 mailto:inline@mail.tld
15059 <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>
15060 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
15061 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
15062 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
15063 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
15066 <p><a rel="mw:ExtLink" href="http://first/"></a> <a rel="mw:ExtLink" href="http://second"></a> <a rel="mw:ExtLink" href="ftp://ftp"></a></p>
15067 <p><a rel="mw:ExtLink" href="ftp://inlineftp">ftp://inlineftp</a></p>
15068 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld">With target</a></p>
15069 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld"></a></p>
15070 <p><a rel="mw:ExtLink" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a></p>
15075 # Security and HTML correctness
15076 # From Nick Jenkins' fuzz testing
15080 Fuzz testing: Parser13
15095 Fuzz testing: Parser14
15100 <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>
15101 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15103 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
15109 <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>
15111 <div id="toc" class="toc">
15112 <div id="toctitle">
15116 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
15122 Fuzz testing: Parser14-table
15127 <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>
15128 <table style="__TOC__">
15133 <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>
15134 <table style="__TOC__">
15141 # Known to produce bogus xml (extra </td>)
15143 Fuzz testing: Parser16
15172 Fuzz testing: Parser21
15175 ! irc://{{ftp://a" onmouseover="alert('hello world');"
15180 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
15190 Fuzz testing: Parser22
15192 http://===r:::https://b
15196 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
15204 # Known to produce bad XML for now
15206 Fuzz testing: Parser24
15213 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
15214 <br style="onmouseover='alert(document.cookie);' " />
15216 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
15221 <u class="|">}}}} >
15222 <br style="onmouseover='alert(document.cookie);'" />
15224 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
15233 # Note: the current result listed for this is not what the original one was,
15234 # but the original bug was JavaScript injection, which is fixed in any case.
15235 # It's not clear that the original result listed was any more correct than the
15236 # current one. Original result:
15239 # <li class="||">
15240 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
15242 Fuzz testing: Parser25 (bug 6055)
15248 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
15250 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
15255 Fuzz testing: URL adjacent extension (with space, clean)
15257 http://example.com <nowiki>junk</nowiki>
15259 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
15264 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
15266 http://example.com<nowiki>junk</nowiki>
15268 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
15273 Fuzz testing: URL adjacent extension (no space, dirty; pre)
15275 http://example.com<pre>junk</pre>
15277 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
15280 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></p>
15287 Fuzz testing: image with bogus manual thumbnail
15289 [[Image:foobar.jpg|thumbnail= ]]
15291 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
15294 <figure class="mw-default-size" typeof="mw:Error mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"manualthumb","ak":"thumbnail= "}],"dsr":[0,32,2,2]}' data-mw='{"errors":[{"key":"missing-thumbnail","message":"This thumbnail does not exist.","params":{"name":""}}],"thumb":""}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{},"dsr":[2,30,null,null]}'><img resource="./File:Foobar.jpg" src="./Special:FilePath/" height="220" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"220"},"sa":{"resource":"Image:foobar.jpg"}}'/></a></figure>
15298 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
15300 <pre dir=" "></pre>
15302 <pre dir=" "></pre>
15307 Parsing optional HTML elements (Bug 6171)
15312 <td> Some tabular data</td>
15313 <td> More tabular data ...
15314 <td> And yet som tabular data</td>
15320 <td> Some tabular data</td>
15321 <td> More tabular data ...
15322 </td><td> And yet som tabular data</td>
15329 Correct handling of <td>, <tr> (Bug 6171)
15334 <td> Some tabular data</td>
15335 <td> More tabular data ...</td>
15336 <td> And yet som tabular data</td>
15342 <td> Some tabular data</td>
15343 <td> More tabular data ...</td>
15344 <td> And yet som tabular data</td>
15352 Parsing crashing regression (fr:JavaScript)
15356 <p></body></x>
15361 Inline wiki vs wiki block nesting
15367 <p><b>Bold paragraph</b>
15368 </p><p>New wiki paragraph
15372 # FIXME: The current php output is documented
15373 # and desired output is the parsoid target.
15375 Inline HTML vs wiki block nesting
15381 <p><b>Bold paragraph
15382 </p><p>New wiki paragraph</b>
15385 <p><b>Bold paragraph</b>
15386 </p><p>New wiki paragraph
15390 # Original result was this:
15391 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
15393 # While that might be marginally more intuitive, maybe, the six-apostrophe
15394 # construct is clearly pathological and the result stated here (which is what
15395 # the parser actually does) is about as reasonable as anything.
15397 Mixing markup for italics and bold
15400 '''bold''''''bold''bolditalics'''''
15402 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
15410 Article for special page transclusion test
15414 Special page transclusion
15417 {{Special:Prefixindex/Xyzzyx}}
15419 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
15424 Special page transclusion twice (bug 5021)
15427 {{Special:Prefixindex/Xyzzyx}}
15428 {{Special:Prefixindex/Xyzzyx}}
15430 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
15431 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
15436 Transclusion of default MediaWiki message
15438 {{MediaWiki:Mainpage}}
15445 Transclusion of nonexistent MediaWiki message
15447 {{MediaWiki:Mainpagexxx}}
15449 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
15454 Transclusion of MediaWiki message with underscore
15456 {{MediaWiki:history_short}}
15463 Transclusion of MediaWiki message with space
15465 {{MediaWiki:history short}}
15472 Invalid header with following text
15482 Section extraction test (section 0)
15502 Section extraction test (section 1)
15524 Section extraction test (section 2)
15545 Section extraction test (section 3)
15565 Section extraction test (section 4)
15589 Section extraction test (section 5)
15609 Section extraction test (section 6)
15630 Section extraction test (section 7)
15650 Section extraction test (section 8)
15670 Section extraction test (section 9)
15691 Section extraction test (section 10)
15711 Section extraction test (nonexistent section 11)
15730 Section extraction test with bogus heading (section 1)
15735 ==bogus== not a legal section
15739 ==bogus== not a legal section
15743 Section extraction test with bogus heading (section 2)
15748 ==bogus== not a legal section
15755 Section extraction test with comment after heading (section 1)
15767 Section extraction test with comment after heading (section 2)
15779 Section extraction test with bogus <nowiki> heading (section 1)
15784 ==bogus== <nowiki>not a legal section</nowiki>
15788 ==bogus== <nowiki>not a legal section</nowiki>
15792 Section extraction test with bogus <nowiki> heading (section 2)
15797 ==bogus== <nowiki>not a legal section</nowiki>
15804 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
15805 # instead of respecting commented sections
15807 Section extraction prefixed by comment (section 1)
15818 Section extraction prefixed by comment (section 2)
15829 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
15830 # instead of respecting HTML-style headings
15832 Section extraction, mixed wiki and html (section 1)
15848 Section extraction, mixed wiki and html (section 2)
15864 # Formerly testing for bug 3342
15866 Section extraction, heading surrounded by <noinclude>
15870 <noinclude>==unmarked==</noinclude>
15876 # Test behavior of bug 19910
15878 Sectiion with all-equals
15883 The line above must have a trailing space
15886 But just in case it doesn't...
15890 But just in case it doesn't...
15894 Section replacement test (section 0)
15925 Section replacement test (section 1)
15954 Section replacement test (section 2)
15984 Section replacement test (section 3)
16015 Section replacement test (section 4)
16042 Section replacement test (section 5)
16073 Section replacement test (section 6)
16103 Section replacement test (section 7)
16134 Section replacement test (section 8)
16165 Section replacement test (section 9)
16194 Section replacement test (section 10)
16224 Section replacement test with initial whitespace (bug 13728)
16228 Preformatted initial line
16232 Preformatted initial line
16239 Section extraction, heading followed by pre with 20 spaces (bug 6398)
16251 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
16264 Section extraction, <pre> around bogus header (bug 10309)
16281 Section replacement, <pre> around bogus header (bug 10309)
16283 noxml replace=2,"xxx"
16304 Handling of 
 in URLs
16308 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
16311 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://
16313 a</a></li></ul></li></ul>
16317 Handling of %0A in URLs
16321 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
16324 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
16328 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
16330 5 quotes, code coverage +1 line
16337 <p><b><i></i></b></p>
16340 # same html as previous, but wikitext adjusted to match parsoid html2wt
16341 # note that wt2html and html2html will put the <i> before the <b>
16343 5 quotes, code coverage +1 line w/ nowiki (1)
16345 parsoid=wt2wt,html2wt
16347 '''''<nowiki/>'''''
16352 <p><b><i></i></b></p>
16355 # same as previous, just swapping the <i> and <b>
16357 5 quotes, code coverage +1 line w/ nowiki (2)
16359 '''''<nowiki/>'''''
16364 <p><i><b></b></i></p>
16368 Special:Search page linking.
16372 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
16377 {{!}} is a magic word
16379 {{!}} is a magic word there and {{!}} is still a magic word here
16381 <p>| is a magic word there and | is still a magic word here
16384 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"!","href":"./Template:!"},"params":{},"i":0}}]}' data-parsoid='{"pi":[[]]}'>|</span> is a magic word there and <span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"!","href":"./Template:!"},"params":{},"i":0}}]}' data-parsoid='{"pi":[[]]}'>|</span> is still a magic word here</p>
16390 title=[[Parser test]]
16395 * {{FULLPAGENAMEE}}
16397 * {{BASEPAGENAMEE}}
16401 * {{ROOTPAGENAMEE}}
16403 * {{TALKPAGENAMEE}}
16404 * {{SUBJECTPAGENAME}}
16405 * {{SUBJECTPAGENAMEE}}
16408 * {{NAMESPACENUMBER}}
16412 * {{SUBJECTSPACEE}}
16413 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
16415 <ul><li> Parser test</li>
16416 <li> Parser_test</li>
16417 <li> Parser test</li>
16418 <li> Parser_test</li>
16419 <li> Parser test</li>
16420 <li> Parser_test</li>
16421 <li> Parser test</li>
16422 <li> Parser_test</li>
16423 <li> Parser test</li>
16424 <li> Parser_test</li>
16425 <li> Talk:Parser test</li>
16426 <li> Talk:Parser_test</li>
16427 <li> Parser test</li>
16428 <li> Parser_test</li>
16436 <li> <a href="/index.php?title=Template:Dynamic&action=edit&redlink=1" class="new" title="Template:Dynamic (page does not exist)">Template:Dynamic</a></li></ul>
16439 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
16449 image4 |300px| centre
16450 image5.svg| http://///////
16455 <ul class="gallery mw-gallery-traditional">
16456 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16457 <div class="thumb" style="height: 150px;">Image1.png</div>
16458 <div class="gallerytext">
16461 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16462 <div class="thumb" style="height: 150px;">Image2.gif</div>
16463 <div class="gallerytext">
16468 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16469 <div class="thumb" style="height: 150px;">Image3</div>
16470 <div class="gallerytext">
16473 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16474 <div class="thumb" style="height: 150px;">Image4</div>
16475 <div class="gallerytext">
16480 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16481 <div class="thumb" style="height: 150px;">Image5.svg</div>
16482 <div class="gallerytext">
16483 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
16487 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16488 <div class="thumb" style="height: 150px;">* image6</div>
16489 <div class="gallerytext">
16497 Gallery (with options)
16499 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
16500 File:Nonexistent.jpg|caption
16501 File:Nonexistent.jpg
16502 image:foobar.jpg|some '''caption''' [[Main Page]]
16504 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
16507 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
16508 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
16509 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16510 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
16511 <div class="gallerytext">
16516 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16517 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
16518 <div class="gallerytext">
16521 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16522 <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>
16523 <div class="gallerytext">
16524 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
16528 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16529 <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>
16530 <div class="gallerytext">
16533 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16534 <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>
16535 <div class="gallerytext">
16545 Gallery with link that has fragment
16548 image:foobar.jpg|link=Main_Page
16549 image:foobar.jpg|link=Main_Page#section
16550 image:foobar.jpg|link=Main Page#section|caption
16553 <ul class="gallery mw-gallery-traditional">
16554 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16555 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/Main_Page"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
16556 <div class="gallerytext">
16559 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16560 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/Main_Page#section"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
16561 <div class="gallerytext">
16564 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16565 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/Main_Page#section"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
16566 <div class="gallerytext">
16576 Gallery with wikitext inside caption
16579 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
16580 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
16583 <ul class="gallery mw-gallery-traditional">
16584 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16585 <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>
16586 <div class="gallerytext">
16587 <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>
16591 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16592 <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>
16593 <div class="gallerytext">
16594 <p>This is a test template
16603 gallery (with showfilename option)
16605 <gallery showfilename>
16606 File:Nonexistent.jpg|caption
16607 File:Nonexistent.jpg
16608 image:foobar.jpg|some '''caption''' [[Main Page]]
16612 <ul class="gallery mw-gallery-traditional">
16613 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16614 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16615 <div class="gallerytext">
16616 <p><a href="/wiki/File:Nonexistent.jpg" title="File:Nonexistent.jpg">Nonexistent.jpg</a><br />
16621 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16622 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16623 <div class="gallerytext">
16624 <p><a href="/wiki/File:Nonexistent.jpg" title="File:Nonexistent.jpg">Nonexistent.jpg</a><br />
16628 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16629 <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>
16630 <div class="gallerytext">
16631 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
16632 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
16636 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16637 <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>
16638 <div class="gallerytext">
16639 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
16648 Gallery (with namespace-less filenames)
16651 File:Nonexistent.jpg
16657 <ul class="gallery mw-gallery-traditional">
16658 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16659 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16660 <div class="gallerytext">
16663 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16664 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16665 <div class="gallerytext">
16668 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16669 <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>
16670 <div class="gallerytext">
16673 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16674 <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>
16675 <div class="gallerytext">
16683 HTML Hex character encoding (spells the word "JavaScript")
16685 parsoid=wt2html,wt2wt,html2html
16687 JavaScript
16689 <p>JavaScript
16694 <p><span typeof="mw:Entity">J</span><span typeof="mw:Entity">a</span><span typeof="mw:Entity">v</span><span typeof="mw:Entity">a</span><span typeof="mw:Entity">S</span><span typeof="mw:Entity">c</span><span typeof="mw:Entity">r</span><span typeof="mw:Entity">i</span><span typeof="mw:Entity">p</span><span typeof="mw:Entity">t</span></p>
16698 HTML Hex character encoding bogus encoding (bug 26437 regression check)
16702 <p>&#xsee;&#XSEE;
16705 <p>&#xsee;&#XSEE;</p>
16709 HTML Hex character encoding mixed case
16711 parsoid=wt2html,wt2wt,html2html
16720 <p><span typeof="mw:Entity">î</span><span typeof="mw:Entity">î</span></p>
16724 __FORCETOC__ override
16736 ISBN 978-0-1234-56 789
16738 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
16741 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789</p>
16745 ISBN followed by 5 spaces
16756 ISBN ISBN 1234567890
16758 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
16767 <p><a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-X</a>
16772 ISBN with empty prefix (parsoid test)
16776 <p><a href="Special:BookSources/1234567890" rel="mw:ExtLink">ISBN 1234567890</a></p>
16780 Bug 22905: <abbr> followed by ISBN followed by </a>
16782 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
16784 <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>
16793 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
16798 Double RFC with a wiki link
16802 <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>
16811 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
16814 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987</p>
16818 Centre-aligned image
16820 [[Image:foobar.jpg|centre]]
16822 <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>
16829 [[Image:foobar.jpg|none]]
16831 <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>
16836 Width + Height sized image (using px) (height is ignored)
16838 [[Image:foobar.jpg|640x480px]]
16840 <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>
16845 Width-sized image (using px, no following whitespace)
16847 [[Image:foobar.jpg|640px]]
16849 <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>
16854 Width-sized image (using px, with following whitespace - test regression from r39467)
16856 [[Image:foobar.jpg|640px ]]
16858 <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>
16863 Width-sized image (using px, with preceding whitespace - test regression from r39467)
16865 [[Image:foobar.jpg| 640px]]
16867 <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>
16872 Image with page parameter
16876 [[File:LoremIpsum.djvu|page=2]]
16878 <p><a href="/index.php?title=File:LoremIpsum.djvu&page=2" class="image"><img alt="LoremIpsum.djvu" src="http://example.com/images/thumb/5/5f/LoremIpsum.djvu/page2-2480px-LoremIpsum.djvu.jpg" width="2480" height="3508" srcset="http://example.com/images/thumb/5/5f/LoremIpsum.djvu/page2-3720px-LoremIpsum.djvu.jpg 1.5x, http://example.com/images/thumb/5/5f/LoremIpsum.djvu/page2-4960px-LoremIpsum.djvu.jpg 2x" /></a>
16881 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"page","ak":"page=2"}]}'><a href="./File:LoremIpsum.djvu" data-parsoid='{"a":{"href":"./File:LoremIpsum.djvu"},"sa":{}}'><img resource="./File:LoremIpsum.djvu" src="//example.com/images/5/5f/LoremIpsum.djvu" height="3508" width="2480" data-parsoid='{"a":{"resource":"./File:LoremIpsum.djvu","height":"3508","width":"2480"},"sa":{"resource":"File:LoremIpsum.djvu"}}'/></a></span></p>
16885 Another italics / bold test
16893 # FIXME: The php output seems broken. It's interleaving some open/close tags.
16899 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd></dt></dl></dd></dl></dd></dl></dd></dl></dd></dl></dd></dl>
16902 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd></dd></dl></dd></dl></dt></dl></dt></dl></dt></dl></dd></dl>
16907 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
16909 Images with the "|" character in the comment
16911 [[File:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
16913 <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"></a></div>An <a rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&param2=%7Cx">external</a> URL</div></div></div>
16916 <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>An <a rel="mw:ExtLink" href="http://test/?param1=|left|&param2=|x">external</a> URL</figcaption></figure>
16920 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
16922 <html><script>alert(1);</script></html>
16924 <p><html><script>alert(1);</script></html>
16929 HTML with raw HTML ($wgRawHtml==true)
16933 <html><script>alert(1);</script></html>
16935 <p><script>alert(1);</script>
16940 Parents of subpages, one level up
16942 subpage title=[[Subpage test/L1/L2/L3]]
16946 <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>
16952 Parents of subpages, one level up, not named
16954 subpage title=[[Subpage test/L1/L2/L3]]
16958 <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>
16965 Parents of subpages, two levels up
16967 subpage title=[[Subpage test/L1/L2/L3]]
16973 <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
16974 </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>
16979 Parents of subpages, two levels up, without trailing slash or name.
16981 subpage title=[[Subpage test/L1/L2/L3]]
16990 Parents of subpages, two levels up, with lots of extra trailing slashes.
16992 subpage title=[[Subpage test/L1/L2/L3]]
16996 <p><a href="/index.php?title=Subpage_test/L1&action=edit&redlink=1" class="new" title="Subpage test/L1 (page does not exist)">Subpage test/L1</a>
17001 Subpage test/L1/L2/L3Sibling
17007 Transclusion of a sibling page (one level up)
17009 subpage title=[[Subpage test/L1/L2/L3]]
17018 Transclusion of a child page
17020 subpage title=[[Subpage test/L1/L2]]
17029 Non-transclusion because of too many up levels
17031 subpage title=[[Subpage test/L1/L2/L3]]
17033 {{../../../../More than parent}}
17035 <p>{{../../../../More than parent}}
17040 Definition list code coverage
17046 <dl><dt> title  </dt>
17048 <dt> title </dt>
17054 <dl><dt> title <span typeof="mw:Placeholder"> </span></dt><dd> def</dd>
17055 <dt> title<span typeof="mw:Placeholder"> </span></dt><dd> def</dd>
17056 <dt>title</dt><dd> def</dd></dl>
17060 Don't fall for the self-closing div
17062 <div>hello world</div/>
17064 <div>hello world</div>
17073 <p>[[:Template:Msg]]
17082 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
17086 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
17088 Always escape literal '>' in output, not just after '<'
17102 <p>This is a test template
17103 This is a test template
17115 Inclusion of !userCanEdit() content
17119 <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>
17125 Out-of-order TOC heading levels
17134 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17136 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
17138 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
17139 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
17142 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
17144 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
17145 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
17151 <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>
17152 <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>
17153 <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>
17154 <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>
17155 <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>
17156 <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>
17162 ISBN with a dummy number
17172 ISBN with space-delimited number
17176 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
17182 ISBN with multiple spaces, no number
17201 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
17202 </p><p>ISBN 12345678901
17208 ISBN with trailing year (bug 8110)
17210 ISBN 1-234-56789-0 - 2006
17212 ISBN 1 234 56789 0 - 2006
17214 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
17215 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
17223 {{anchorencode:foo bar©#%n}}
17225 <p>foo_bar.C2.A9.23.25n
17230 anchorencode trims spaces
17232 {{anchorencode: __pretty__please__}}
17239 anchorencode deals with links
17241 {{anchorencode: [[hello|world]] [[hi]]}}
17248 anchorencode deals with templates
17250 {{anchorencode: {{Foo}} }}
17257 anchorencode encodes like the TOC generator: (bug 18431)
17259 === _ +:.3A%3A&&]] ===
17260 {{anchorencode: _ +:.3A%3A&&]] }}
17263 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
17264 <p>.2B:.3A.253A.26.26.5D.5D
17269 Bug 6200: blockquotes and paragraph formatting
17290 Bug 8293: Use of center tag ruins paragraph formatting
17311 Parsing of overlapping (improperly nested) inline html tags
17313 <span><s>x</span></s>
17315 <p><span><s>x</span></s></span>
17318 <p><span><s>x</s></span>
17323 ### Language variants related tests
17326 Self-link in language variants
17328 title=[[Dunav]] language=sr
17330 Both [[Dunav]] and [[Дунав]] are names for this river.
17332 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
17343 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
17345 title=[[Duna]] language=sr
17347 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
17349 <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.
17354 Link to a section of a variant of this title shouldn't be parsed as self-link
17356 title=[[Duna]] language=sr
17358 [[Dуна]] is a self-link while [[Dunа#Foo]] and [[Dуна#Foo]] are not self-links.
17360 <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.
17365 Link to pages in language variants
17369 Main Page can be written as [[Маин Паге]]
17371 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
17377 Multiple links to pages in language variants
17381 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
17383 <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>.
17389 Simple template in language variants
17395 <p>This is a test template
17401 Template with explicit namespace in language variants
17407 <p>This is a test template
17413 Basic test for template parameter in language variants
17417 {{парамтест|param=foo}}
17419 <p>This is a test template with parameter foo
17425 Simple category in language variants
17429 [[Category:МедиаWики Усер'с Гуиде]]
17431 <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>
17448 Don't convert blue categorylinks to another variant (bug 33210)
17452 [[A]][[Category:分类]]
17454 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
17459 Stripping -{}- tags (language variants)
17463 Latin proverb: -{Ne nuntium necare}-
17465 <p>Latin proverb: Ne nuntium necare
17471 Prevent conversion with -{}- tags (language variants)
17473 language=sr variant=sr-ec
17475 Latinski: -{Ne nuntium necare}-
17477 <p>Латински: Ne nuntium necare
17483 Prevent conversion of text with -{}- tags (language variants)
17485 language=sr variant=sr-ec
17487 Latinski: -{Ne nuntium necare}-
17489 <p>Латински: Ne nuntium necare
17495 Prevent conversion of links with -{}- tags (language variants)
17497 language=sr variant=sr-ec
17501 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
17507 -{}- tags within headlines (within html for parserConvert())
17509 language=sr variant=sr-ec
17513 <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>
17519 Explicit definition of language variant alternatives
17521 language=zh variant=zh-tw
17523 -{zh:China;zh-tw:Taiwan}-, not China
17525 <p>Taiwan, not China
17531 Conversion around HTML tags
17533 language=sr variant=sr-ec
17535 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
17536 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
17539 <span title="ЛаCтин">ски</span>
17545 Explicit session-wise language variant mapping (A flag and - flag)
17547 language=zh variant=zh-tw
17549 Taiwan is not China.
17550 But -{A|zh:China;zh-tw:Taiwan}- is China,
17551 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
17552 and -{China}- is China.
17554 <p>Taiwan is not China.
17555 But Taiwan is Taiwan,
17556 (This should be stripped!)
17557 and China is China.
17562 Explicit session-wise language variant mapping (H flag for hide)
17564 language=zh variant=zh-tw
17566 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
17569 <p>(This should be stripped!)
17575 Adding explicit conversion rule for title (T flag)
17577 language=zh variant=zh-tw showtitle
17579 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
17582 <p>Should be stripped!
17587 Testing that changing the language variant here in the tests actually works
17589 language=zh variant=zh showtitle
17591 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
17594 <p>Should be stripped!
17599 Recursive conversion of alt and title attrs shouldn't clear converter state
17601 language=zh variant=zh-cn showtitle
17603 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
17604 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
17608 Should be stripped<span title="Exclamation">!</span>
17613 Bug 24072: more test on conversion rule for title
17615 language=zh variant=zh-tw showtitle
17617 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
17618 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
17621 <p>This should be stripped!
17622 This won't take interferes with the title rule.
17627 Partly disable title conversion if variant == main language code
17629 language=zh variant=zh title=[[ZH]] showtitle
17631 -{T|zh-cn:CN;zh-tw:TW}-
17639 Partly disable title conversion if variant == main language code, more
17641 language=zh variant=zh title=[[ZH]] showtitle
17651 Raw output of variant escape tags (R flag)
17653 language=zh variant=zh-tw
17655 Raw: -{R|zh:China;zh-tw:Taiwan}-
17657 <p>Raw: zh:China;zh-tw:Taiwan
17662 Nested using of manual convert syntax
17664 language=zh variant=zh-hk
17666 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
17668 <p>Nested: Hello Hong Kong!
17673 Proper conversion of text in external links
17675 language=sr variant=sr-ec
17677 http://www.google.com
17678 gopher://www.google.com
17679 [http://www.google.com http://www.google.com]
17680 [gopher://www.google.com gopher://www.google.com]
17681 [https://www.google.com irc://www.google.com]
17682 [ftp://www.google.com www.google.com/ftp://dir]
17683 [//www.google.com www.google.com]
17685 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
17686 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
17687 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
17688 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
17689 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
17690 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
17691 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
17696 Do not convert roman numbers to language variants
17698 language=sr variant=sr-ec
17702 <p>Фридрих IV је цар.
17707 Unclosed language converter markup "-{"
17718 Don't convert raw rule "-{R|=>}-" to "=>"
17729 Don't break link parsing if language converter markup is in the caption.
17731 language=sr variant=sr-ec
17733 [[Main Page|-{R|main page}-]]
17735 <p><a href="/wiki/Main_Page" title="Маин Паге">main page</a>
17739 # FIXME: This test is currently broken in the PHP parser (bug 52661)
17741 Don't break image parsing if language converter markup is in the caption.
17745 [[File:Foobar.jpg|-{R|caption}-]]
17747 <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>
17751 # FIXME: This test is currently broken in the PHP parser (bug 52661)
17753 Don't break list handling if language converter markup is in the item.
17755 language=zh variant=zh-cn
17757 ;-{zh-cn:AAA;zh-tw:BBB}-
17759 <dl><dt><span class="error">在手动语言转换规则中检测到错误</span></dd></dl>
17766 # FIXME: This test is currently broken in the PHP parser (bug 52661)
17768 Don't break table handling if language converter markup is in the cell.
17770 language=sr variant=sr-ec
17793 Bug 529: Uncovered bullet
17802 # Plain MediaWiki does not remove empty lists, but tidy actually does.
17803 # Templates in Wikipedia rely on this behavior, as tidy has always been
17804 # enabled there. These tests are normally run *without* tidy, so specify the
17805 # full output here.
17806 # To test realistic parsing behavior, apply a tidy-like transformation to both
17807 # the expected output and your parser's output.
17809 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
17811 ******* Foo {{bullet}}
17813 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo </li></ul></li></ul></li></ul></li></ul></li></ul></li></ul></li>
17819 Bug 529: Uncovered table already at line-start
17842 Bug 529: Uncovered bullet in parser function result
17844 * Foo {{lc:{{bullet}} }}
17852 Bug 5678: Double-parsed template argument
17854 {{lc:{{{1}}}|hello}}
17861 Bug 5678: Double-parsed template invocation
17863 {{lc:{{paramtest {{!}} param = hello }} }}
17865 <p>{{paramtest | param = hello }}
17870 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
17873 title=[[Main Page]]
17875 {{PRVNÍVELKÉ:ěščř}}
17876 {{prvnívelké:ěščř}}
17896 Morwen/13: Unclosed link followed by heading
17903 <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>
17908 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
17915 <h1><span class="mw-headline" id="heading">heading</span></h1>
17920 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
17927 <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>
17942 Paragraphs inside divs (no extra line breaks)
17954 Paragraphs inside divs (extra line break on open)
17969 Paragraphs inside divs (extra line break on close)
17984 Paragraphs inside divs (extra line break on open and close)
18001 Nesting tags, paragraphs on lines which begin with <div>
18003 <div></div><strong>A
18006 <p><strong>A</strong></p>
18007 <p><strong>B</strong></p>
18015 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
18017 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
18019 <blockquote>Line one
18021 Line two</blockquote>
18023 <blockquote>Line one
18024 Line two</blockquote>
18028 <p>Line one Line two</p>
18033 Bug 6200: paragraphs inside blockquotes (extra line break on open)
18038 Line two</blockquote>
18043 Line two</blockquote>
18048 Line two</blockquote>
18052 Bug 6200: paragraphs inside blockquotes (extra line break on close)
18054 <blockquote>Line one
18059 <blockquote>Line one
18072 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
18094 Paragraphs inside blockquotes/divs (no extra line breaks)
18096 <blockquote><div>Line one
18098 Line two</div></blockquote>
18100 <blockquote><div>Line one
18101 Line two</div></blockquote>
18106 Paragraphs inside blockquotes/divs (extra line break on open)
18111 Line two</div></blockquote>
18116 Line two</div></blockquote>
18121 Paragraphs inside blockquotes/divs (extra line break on close)
18123 <blockquote><div>Line one
18126 </div></blockquote>
18128 <blockquote><div>Line one
18131 </div></blockquote>
18136 Paragraphs inside blockquotes/divs (extra line break on open and close)
18142 </div></blockquote>
18148 </div></blockquote>
18153 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
18155 wgLinkHolderBatchSize=0
18161 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
18162 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
18163 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
18168 Free external link invading image caption
18170 [[Image:Foobar.jpg|thumb|http://x|hello]]
18172 <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"></a></div>hello</div></div></div>
18177 Bug 15196: localised external link numbers
18181 [http://en.wikipedia.org/]
18183 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
18186 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/"></a></p>
18190 Multibyte character in padleft
18192 {{padleft:-Hello|7|Æ}}
18199 Multibyte character in padright
18201 {{padright:Hello-|7|Æ}}
18208 formatdate parser function
18210 {{#formatdate:2009-03-24}}
18212 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
18217 formatdate parser function, with default format
18219 {{#formatdate:2009-03-24|mdy}}
18221 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
18226 Spacing of numbers in formatted dates
18228 {{#formatdate:January 15}}
18230 <p><span class="mw-formatted-date" title="01-15">January 15</span>
18235 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
18237 language=nl title=[[MediaWiki:Common.css]]
18239 {{#formatdate:2009-03-24|dmy}}
18241 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
18254 Edit comment with link
18258 I like the [[Main Page]] a lot
18260 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
18264 Edit comment with link and link text
18268 I like the [[Main Page|best pages]] a lot
18270 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
18274 Edit comment with link and link text with suffix
18278 I like the [[Main Page|best page]]s a lot
18280 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
18284 Edit comment with section link (non-local, eg in history list)
18286 comment title=[[Main Page]]
18288 /* External links */ removed bogus entries
18290 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
18294 Edit comment with section link and text before it (non-local, eg in history list)
18296 comment title=[[Main Page]]
18298 pre-comment text /* External links */ removed bogus entries
18300 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>
18304 Edit comment with section link (local, eg in diff view)
18306 comment local title=[[Main Page]]
18308 /* External links */ removed bogus entries
18310 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
18314 Edit comment with subpage link (bug 14080)
18318 title=[[Subpage test]]
18320 Poked at a [[/subpage]] here...
18322 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
18326 Edit comment with subpage link and link text (bug 14080)
18330 title=[[Subpage test]]
18332 Poked at a [[/subpage|neat little page]] here...
18334 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
18338 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
18341 title=[[Subpage test]]
18343 Poked at a [[/subpage]] here...
18345 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
18349 Edit comment with bare anchor link (local, as on diff)
18353 title=[[Main Page]]
18357 <a href="#section">#section</a>
18361 Edit comment with bare anchor link (non-local, as on history)
18364 title=[[Main Page]]
18368 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
18372 Anchor starting with underscore
18376 <p><a href="#_ref">One</a>
18381 Id starting with underscore
18383 <div id="_ref"></div>
18385 <div id="_ref"></div>
18390 Space normalisation on autocomment (bug 22784)
18393 title=[[Main Page]]
18395 /* __hello__world__ */
18397 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
18401 percent-encoding and + signs in comments (Bug 26410)
18405 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
18407 <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>
18410 # Parsoid doesn't support this yet: see bug 73581
18411 # but it *should* omit the 'src' attribute if the image is bad.
18412 # PHP side of tests was disabled in
18413 # mediawiki/core:6bd31e7d95161a6e88fa86df60871051da997c3c
18414 # because of issues in the PHP parserTests infrastructure
18415 # (but the output below is indeed what the PHP side emits)
18417 Bad images - basic functionality
18420 !! DISABLED/html/php
18422 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"bad-image","message":"This image is blacklisted in this context."}]}'><a href="File:Bad.jpg"><img resource="./File:Bad.jpg" height="220" width="220"/></a></span></p>
18426 Bad images - bug 16039: text after bad image disappears
18431 !! DISABLED/html/php
18437 <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"bad-image","message":"This image is blacklisted in this context."}]}'><a href="File:Bad.jpg"><img resource="./File:Bad.jpg" height="220" width="220"/></a></span>
18442 Verify that displaytitle works (bug #22501) no displaytitle
18446 wgAllowDisplayTitle=true
18447 wgRestrictDisplayTitle=false
18449 this is not the the title
18452 <p>this is not the the title
18457 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
18462 wgAllowDisplayTitle=true
18463 wgRestrictDisplayTitle=false
18465 this is not the the title
18466 {{DISPLAYTITLE:whatever}}
18469 <p>this is not the the title
18474 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
18479 wgAllowDisplayTitle=true
18480 wgRestrictDisplayTitle=true
18482 this is not the the title
18483 {{DISPLAYTITLE:whatever}}
18486 <p>this is not the the title
18491 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
18496 wgAllowDisplayTitle=true
18497 wgRestrictDisplayTitle=true
18499 this is not the the title
18500 {{DISPLAYTITLE:screen}}
18503 <p>this is not the the title
18508 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
18513 wgAllowDisplayTitle=false
18515 this is not the the title
18516 {{DISPLAYTITLE:screen}}
18519 <p>this is not the the title
18520 <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>
18525 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
18530 wgAllowDisplayTitle=false
18532 this is not the the title
18535 <p>this is not the the title
18540 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
18545 wgAllowDisplayTitle=true
18546 wgRestrictDisplayTitle=true
18548 this is not the the title
18549 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
18551 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
18552 <p>this is not the the title
18557 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
18562 wgAllowDisplayTitle=true
18563 wgRestrictDisplayTitle=true
18565 this is not the the title
18566 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
18568 <span style="color: red;">s</span>creen
18569 <p>this is not the the title
18574 preload: check <noinclude> and <includeonly>
18578 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
18584 preload: check <onlyinclude>
18588 Goodbye <onlyinclude>Hello world</onlyinclude>
18594 preload: can pass tags through if we want to
18598 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
18600 <includeonly>Hello world</includeonly>
18604 preload: check that it doesn't try to do tricks
18608 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
18610 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
18614 Play a bit with r67090 and bug 3158
18616 <div style="width:50% !important"> </div>
18617 <div style="width:50% !important"> </div>
18618 <div style="width:50% !important"> </div>
18619 <div style="border : solid;"> </div>
18621 <div style="width:50% !important"> </div>
18622 <div style="width:50% !important"> </div>
18623 <div style="width:50% !important"> </div>
18624 <div style="border : solid;"> </div>
18627 <div style="width:50% !important" data-parsoid='{"stx":"html"}'><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></div>
18628 <div style="width:50% !important" data-parsoid='{"stx":"html","a":{"style":"width:50% !important"},"sa":{"style":"width:50%&nbsp;!important"}}'><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></div>
18629 <div style="width:50% !important" data-parsoid='{"stx":"html","a":{"style":"width:50% !important"},"sa":{"style":"width:50%&#160;!important"}}'><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></div>
18630 <div style="border : solid;" data-parsoid='{"stx":"html"}'><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></div>
18635 HTML5 data attributes
18637 <span data-foo="bar">Baz</span>
18638 <p data-abc-def_hij="">Quuz</p>
18640 <p><span data-foo="bar">Baz</span>
18642 <p data-abc-def_hij="">Quuz</p>
18647 percent-encoding and + signs in internal links (Bug 26410)
18649 [[User:+%]] [[Page+title%]]
18650 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
18651 [[%]] [[+]] [[File:%+abc%39|foo|[[bar]]]]
18652 [[%33%45]] [[%33%45+]]
18654 <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>
18655 <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>
18656 <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>
18657 <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>
18660 <p><a rel="mw:WikiLink" href="User:+%" title="User:+%">User:+%</a> <a rel="mw:WikiLink" href="Page+title%" title="Page+title%">Page+title%</a> <a rel="mw:WikiLink" href="%+" title="%+">%+</a> <a rel="mw:WikiLink" href="%+" title="%+">%20</a> <a rel="mw:WikiLink" href="%+" title="%+">%+ </a> <a rel="mw:WikiLink" href="%+r" title="%+r">%+r</a> <a rel="mw:WikiLink" href="%" title="%">%</a> <a rel="mw:WikiLink" href="+" title="+">+</a> <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"[[bar]]"}'><a href="File:%+abc9"><img resource="./File:%25+abc9" src="./Special:FilePath/%+abc9" height="220" width="220"/></a></span> <a rel="mw:WikiLink" href="3E" title="3E">3E</a> <a rel="mw:WikiLink" href="3E+" title="3E+">3E+</a></p>
18664 Special characters in embedded file links (bug 27679)
18666 [[File:Contains & ampersand.jpg]]
18667 [[File:Does not exist.jpg|Title with & ampersand]]
18669 <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>
18670 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
18673 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="File:Contains_&_ampersand.jpg"><img resource="./File:Contains_&_ampersand.jpg" src="./Special:FilePath/Contains_&_ampersand.jpg" height="220" width="220"/></a></span>
18674 <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"Title with & ampersand"}'><a href="File:Does_not_exist.jpg"><img resource="./File:Does_not_exist.jpg" src="./Special:FilePath/Does_not_exist.jpg" height="220" width="220"/></a></span></p>
18678 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
18680 Text's been normalized?
18682 <p>Text's been normalized?
18687 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
18689 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
18691 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
18696 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
18698 [http://www.example.org/ ideograms]
18700 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
18705 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
18707 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
18709 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
18733 Bug 31098 Template which includes system messages which includes the template
18737 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
18738 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
18743 Bug31490 Turkish: ucfirst 'blah'
18754 Bug31490 Turkish: ucfirst 'ix'
18765 Bug31490 Turkish: lcfirst 'BLAH'
18776 Bug31490 Turkish: ucfırst (with a dotless i)
18782 <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>
18787 Bug31490 ucfırst (with a dotless i) with English language
18793 <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>
18798 Bug 26375: TOC with italics
18800 title=[[Main Page]]
18803 == ''Lost'' episodes ==
18805 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18807 <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>
18811 <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>
18816 Bug 26375: TOC with bold
18818 title=[[Main Page]]
18821 == '''should be bold''' then normal text ==
18823 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18825 <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>
18829 <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>
18834 Bug 33845: Headings become cursive in TOC when they contain an image
18836 title=[[Main Page]]
18839 == Image [[Image:foobar.jpg]] ==
18841 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18843 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
18847 <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>
18852 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
18854 title=[[Main Page]]
18857 == <blockquote>Quote</blockquote> ==
18859 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18861 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
18865 <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>
18868 <div id="toc" class="toc">
18869 <div id="toctitle">
18873 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
18876 <h2><span class="mw-headline" id="Quote"></span></h2>
18878 <p><span class="mw-headline" id="Quote">Quote</span></p>
18880 <p><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></p>
18884 Unclosed tags in TOC
18886 title=[[Main Page]]
18890 <small>Hanc marginis exiguitas non caperet.</small>
18893 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18895 <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>
18899 <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>
18900 <p><small>Hanc marginis exiguitas non caperet.</small>
18906 Multiple tags in TOC
18909 == <i>Foo</i> <b>Bar</b> ==
18911 == <i>Foo</i> <blockquote>Bar</blockquote> ==
18913 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18915 <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>
18916 <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>
18920 <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>
18921 <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>
18924 <div id="toc" class="toc">
18925 <div id="toctitle">
18929 <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>
18930 <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>
18933 <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>
18934 <h2><span class="mw-headline" id="Foo_Bar_2"><i>Foo</i></span></h2>
18936 <p><span class="mw-headline" id="Foo_Bar_2">Bar</span></p>
18938 <p><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></p>
18942 Tags with parameters in TOC
18945 == <sup class="in-h2">Hello</sup> ==
18947 == <sup class="a > b">Evilbye</sup> ==
18949 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18951 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
18952 <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>
18956 <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>
18957 <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>
18962 span tags with directionality in TOC
18965 == <span dir="ltr">C++</span> ==
18967 == <span dir="rtl">זבנג!</span> ==
18969 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
18971 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
18973 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
18975 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18977 <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>
18978 <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>
18979 <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>
18980 <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>
18981 <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>
18985 <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>
18986 <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>
18987 <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>
18988 <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>
18989 <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>
18996 == {{int:headline_sample}} ==
19000 Bug 32057: Title needed when expanding <h> nodes.
19002 title=[[Main Page]]
19006 <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>
19011 Strip marker in urlencode
19013 {{urlencode:x<nowiki/>y}}
19014 {{urlencode:x<nowiki/>y|wiki}}
19015 {{urlencode:x<nowiki/>y|path}}
19042 Strip marker in formatNum
19044 {{formatnum:1<nowiki/>2}}
19045 {{formatnum:1<nowiki/>2|R}}
19053 Check noCommafy in formatNum
19057 {{formatnum:123456.78}}
19058 {{formatnum:123456.78|NOSEP}}
19066 Wrong option for formatNum (bug 56199)
19068 {{formatnum:1,234.56|Random}}
19069 {{formatnum:1,234.56|EVERYTHING}}
19070 {{formatnum:1234.56|any argument that has the string 'NOSEP'}}
19079 Strip marker in grammar
19083 {{grammar:elative|foo<nowiki/>bar}}
19090 Strip marker in padleft
19092 {{padleft:|2|x<nowiki/>y}}
19099 Strip marker in padright
19101 {{padright:|2|x<nowiki/>y}}
19108 Strip marker in anchorencode
19110 {{anchorencode:x<nowiki/>y}}
19117 nowiki inside link inside heading (bug 18295)
19119 ==[[foo|x<nowiki>y</nowiki>z]]==
19121 <h2><span class="mw-headline" id="xyz"><a href="/wiki/Foo" title="Foo">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>
19126 new support for bdi element (bug 31817)
19128 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
19130 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
19135 Ignore pipe between table row attributes
19139 |- id=foo | style='color: red'
19147 <tr id="foo" style="color: red">
19154 Gallery override link with WikiLink (bug 34852)
19157 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
19160 <ul class="gallery mw-gallery-traditional">
19161 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19162 <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>
19163 <div class="gallerytext">
19173 Gallery override link with absolute external link (bug 34852)
19176 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
19179 <ul class="gallery mw-gallery-traditional">
19180 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19181 <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>
19182 <div class="gallerytext">
19192 Gallery override link with malicious javascript (bug 34852)
19195 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
19198 <ul class="gallery mw-gallery-traditional">
19199 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19200 <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>
19201 <div class="gallerytext">
19211 Gallery with invalid title as link (bug 43964)
19214 File:foobar.jpg|link=<
19217 <ul class="gallery mw-gallery-traditional">
19218 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19219 <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>
19220 <div class="gallerytext">
19228 Language parser function
19237 Padleft and padright as substr
19239 {{padleft:|3|abcde}}
19240 {{padright:|3|abcde}}
19248 Special parser function
19250 {{#special:RandomPage}}
19251 {{#special:BaDtItLe}}
19252 {{#special:Foobar}}
19261 Bug 34939 - Case insensitive link parsing ([HttP://])
19263 [HttP://MediaWiki.Org/]
19265 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
19268 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/"></a></p>
19272 Bug 34939 - Case insensitive link parsing ([HttP:// title])
19274 [HttP://MediaWiki.Org/ MediaWiki]
19276 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
19281 Bug 34939 - Case insensitive link parsing (HttP://)
19283 HttP://MediaWiki.Org/
19285 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
19288 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a></p>
19306 <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>
19307 <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>
19308 <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>
19309 <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>
19310 <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>
19316 ### Parsoid-specific tests
19317 ### Parsoid-PHP parser incompatibilities
19320 1. SOL-sensitive wikitext tokens as template-args
19322 parsoid=wt2html,wt2wt
19328 <span about="#mwt1" typeof="mw:Transclusion">
19329 </span><ul about="#mwt1"><li>a</li>
19331 <span about="#mwt2" typeof="mw:Transclusion">
19332 </span><ol about="#mwt2"><li>a</li>
19334 <span about="#mwt3" typeof="mw:Transclusion">
19335 </span><dl about="#mwt3"><dd>a</dd>
19339 #### -----------------------------------------------------------------
19340 #### Parsoid-specific functionality tests
19341 #### -----------------------------------------------------------------
19343 # Bug 63642/66749: Formatting elt fixup around images is cleaned up.
19344 # We know wt2wt will fail, but we expect selser to pass.
19345 # Due to the nature of our testing, wt2wt and selser tests will enter the
19346 # blacklist and we'll catch selser regressions based on changes to the
19347 # blacklist entries for selser tests.
19349 1. Bad treebuilder fixup of formatting elt is cleaned up
19351 parsoid=wt2html,wt2wt
19356 [[Image:Foobar.jpg|right|Test]]
19363 <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>Test</figcaption></figure>
19370 2. Bad treebuilder fixup of formatting elt is cleaned up
19372 parsoid=wt2html,wt2wt
19374 '''foo[[File:Foobar.jpg|thumb|caption]]bar'''
19376 <small>[[Image:Foobar.jpg|right|300px]]</small>
19379 <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><b>caption</b></figcaption></figure>
19381 <small><figure class="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="34" width="300"/></a></figure></small>
19384 #### ----------------------------------------------------------------
19385 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
19386 #### tags. Parsoid's output for these tags differs from that of the
19388 #### ----------------------------------------------------------------
19391 Ref: 1. ref-location should be replaced with an index span
19396 B <ref name="x">foo</ref>
19399 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span>
19400 B <span about="#mwt4" class="reference" id="cite_ref-x-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}'><a href="#cite_note-x-2">[2]</a></span>
19401 C <span about="#mwt6" class="reference" id="cite_ref-y-3-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"y"}}'><a href="#cite_note-y-3">[3]</a></span></p>
19405 Ref: 2. ref-tags with identical names should all get the same index
19409 A <ref name="x">foo</ref>
19412 <p>A <span about="#mwt2" class="reference" id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}'><a href="#cite_note-x-1">[1]</a></span>
19413 B <span about="#mwt4" class="reference" id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="#cite_note-x-1">[1]</a></span></p>
19417 Ref: 3. spaces in ref-names should be ignored
19421 A <ref name="x">foo</ref>
19422 B <ref name=" x " />
19425 <p>A <span about="#mwt2" class="reference" id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}'><a href="#cite_note-x-1">[1]</a></span>
19426 B <span about="#mwt4" class="reference" id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="#cite_note-x-1">[1]</a></span>
19427 C <span about="#mwt6" class="reference" id="cite_ref-x-1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="#cite_note-x-1">[1]</a></span></p>
19430 # NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
19432 Ref: 4. 'constructor' should be accepted as a valid ref-name
19436 A <ref name="constructor">foo</ref>
19438 <p>A <span about="#mwt2" class="reference" id="cite_ref-constructor-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"constructor"}}'><a href="#cite_note-constructor-1">[1]</a></span></p>
19442 Ref: 5. body should accept generic wikitext
19447 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
19452 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"This is a <b data-parsoid='{\"dsr\":[19,40,3,3]}'><a rel=\"mw:WikiLink\" href=\"./Bolded_link\" title=\"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-parsoid='{\"pi\":[[{\"k\":\"1\",\"spc\":[\"\",\"\",\"\",\"\"]}]],\"dsr\":[55,76,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"transclusion\"}},\"i\":0}}]}'>transclusion</span>\n"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19454 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
19455 <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" title="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>
19461 Ref: 6. indent-pres should not be output in ref-body
19473 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo\n bar\n baz\n"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19475 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19476 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
19484 Ref: 7. No p-wrapping in ref-body
19503 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo\n\nbar\n\n\nbaz\n\n\n\nbooz\n"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19505 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19506 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
19521 Ref: 8. transclusion wikitext has lower precedence
19525 A <ref> foo {{echo|</ref> B C}}
19529 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo <span typeof=\"mw:Nowiki\" data-parsoid='{\"src\":\"{{\",\"dsr\":[12,14,0,0]}'>{{</span>echo|"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span> B C<span typeof="mw:Nowiki">}}</span></p>
19530 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19531 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <span typeof="mw:Nowiki">{{</span>echo|</li>
19536 Ref: 9. unclosed comments should not leak out of ref-body
19540 A <ref> foo <!--</ref> B C
19543 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo <!---->"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span> B C</p>
19544 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19545 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <!----></li>
19550 Ref: 10. Unclosed HTML tags should not leak out of ref-body
19554 A <ref> <b> foo </ref> B C
19558 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"<b data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[8,16,3,0]}'> foo </b>"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span> B C</p>
19561 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19562 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> <b data-parsoid='{"stx":"html","autoInsertedEnd":true}'> foo </b></li>
19567 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
19574 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span> B
19575 C <span about="#mwt4" class="reference" id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}'><a href="#cite_note-2">[2]</a></span> D</p>
19579 Ref: 12. ref-tags act as trailing newline migration barrier
19583 <!--the newline at the end of this line moves out of the p-tag-->a
19585 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
19590 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
19593 <p>b<!--the newline at the end of this line stays inside the p-tag--> <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="#cite_note-1">[1]</a></span>
19594 <span about="#mwt4" class="reference" id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="#cite_note-2">[2]</a></span></p>
19600 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
19608 <p><span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span> A
19609 <span about="#mwt4" class="reference" id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bar\n"},"attrs":{}}'><a href="#cite_note-2">[2]</a></span> B</p>
19613 Ref: 14. A nested ref-tag should be emitted as plain text
19617 <ref>foo <ref>bar</ref> baz</ref>
19621 <p><span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo &lt;ref>bar&lt;/ref> baz"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19623 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
19624 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <ref>bar</ref> baz</li>
19629 Ref: 15. ref-tags with identical names should get identical indexes
19633 A1 <ref name="a">foo</ref> A2 <ref name="a" />
19634 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
19638 <p>A1 <span about="#mwt3" class="reference" id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"a"}}'><a href="#cite_note-a-1">[1]</a></span> A2 <span about="#mwt4" class="reference" id="cite_ref-a-1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="#cite_note-a-1">[1]</a></span>
19639 B1 <span about="#mwt7" class="reference" id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"b"}}'><a href="#cite_note-b-2">[2]</a></span> B2 <span about="#mwt8" class="reference" id="cite_ref-b-2-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}'><a href="#cite_note-b-2">[2]</a></span></p>
19641 <ol class="references" typeof="mw:Extension/references" about="#mwt10" 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>
19645 ## We don't bother wt2wt-ing non-standard whitespace
19647 Ref: 16. Tokenizer should accept non-standard whitespace in <ref> and </ref> tags
19655 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19657 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19658 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
19662 Ref: 17. Generate valid HTML5 id/about attributes
19666 <ref name="a b">foo</ref>
19670 <p><span class="reference" id="cite_ref-a_b-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"a b"}}'><a href="#cite_note-a_b-1">[1]</a></span>
19673 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
19674 <li id="cite_note-a_b-1"><span rel="mw:referencedBy"><a href="#cite_ref-a_b-1-0">↑</a></span> foo</li>
19678 References: 1. references tag without any refs should be handled properly
19684 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'></ol>
19688 References: 2. references tag with group only outputs references from that group
19692 A <ref group="a">foo</ref>
19693 B <ref group="b">bar</ref>
19695 <references group="a" />
19697 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"group":"a"}}'><a href="#cite_note-1">[a 1]</a></span>
19698 B <span about="#mwt4" class="reference" id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"group":"b"}}'><a href="#cite_note-2">[b 1]</a></span></p>
19700 <ol class="references" typeof="mw:Extension/references" about="#mwt6" 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>
19705 References: 3. ref list should be cleared after processing references
19717 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19719 <ol class="references" typeof="mw:Extension/references" about="#mwt4" 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>
19722 <p>B <span about="#mwt6" class="reference" id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}'><a href="#cite_note-2">[1]</a></span></p>
19724 <ol class="references" typeof="mw:Extension/references" about="#mwt8" 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>
19729 References: 4. only referenced group should be cleared after processing references
19733 A <ref group="a">afoo</ref>
19736 <references group="a" />
19742 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"afoo"},"attrs":{"group":"a"}}'><a href="#cite_note-1">[a 1]</a></span>
19743 B <span about="#mwt4" class="reference" id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bfoo"},"attrs":{}}'><a href="#cite_note-2">[1]</a></span></p>
19745 <ol class="references" typeof="mw:Extension/references" about="#mwt6" 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>
19748 <p>C <span about="#mwt8" class="reference" id="cite_ref-3-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"cfoo"},"attrs":{}}'><a href="#cite_note-3">[2]</a></span></p>
19750 <ol class="references" typeof="mw:Extension/references" about="#mwt10" 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>
19755 References: 5. ref tags in references should be processed while ignoring all other content
19760 B <ref name="b">bar</ref>
19763 <ref name="a">foo</ref>
19764 This should just get lost.
19767 <p>A <span about="#mwt2" class="reference" id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="#cite_note-a-1">[1]</a></span>
19768 B <span about="#mwt4" class="reference" id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}'><a href="#cite_note-b-2">[2]</a></span></p>
19771 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","body":{"extsrc":"<ref name=\"a\">foo</ref>\nThis should just get lost.","html":"\n<span about=\"#mwt8\" class=\"reference\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid='{\"src\":\"&lt;ref name=\\\"a\\\">foo&lt;/ref>\",\"dsr\":[59,82,14,6]}' data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"a\"}}'><a href=\"#cite_note-a-1\">[1]</a></span>\n"},"attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy"><a href="#cite_ref-a-1-0">↑</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">↑</a></span> bar</li>
19776 References: 6. <references /> from a transclusion
19780 <ref>Foo</ref> {{echo|<references />}}
19782 <p><span about="#mwt3" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"Foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p> <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>
19786 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
19790 A <ref>foo bar for a</ref>
19791 B <ref group="X" name="b" />
19795 <references group="X">
19796 <ref name="b">foo</ref>
19799 <p>A <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo bar for a"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span>
19800 B <span about="#mwt4" class="reference" id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}'><a href="#cite_note-b-2">[X 1]</a></span></p>
19802 <ol class="references" typeof="mw:Extension/references" about="#mwt6" 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 bar for a</li></ol>
19804 <ol class="references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","body":{"extsrc":"<ref name=\"b\">foo</ref>","html":"\n<span about=\"#mwt10\" class=\"reference\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid='{\"src\":\"&lt;ref name=\\\"b\\\">foo&lt;/ref>\",\"dsr\":[96,119,14,6]}' data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"b\"}}'><a href=\"#cite_note-b-2\">[X 1]</a></span>\n"},"attrs":{"group":"X"}}'><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> foo</li></ol>
19808 Entities in ref name
19812 <ref name="test & me">hi</ref>
19814 <p><span about="#mwt2" class="reference" id="cite_ref-test_&_me-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"test &amp; me\">hi</ref>"}' data-mw='{"name":"ref","body":{"html":"hi"},"attrs":{"name":"test & me"}}'><a href="#cite_note-test_&_me-1">[1]</a></span></p>
19817 # This test is wt2html only because we're permitting the serializer to produce
19818 # dirty diffs, normalizing the unclosed references to the self-closed version.
19820 Generate references for unclosed references tag
19828 <p>a<span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
19831 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19832 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
19836 New reference serializes on its own line
19838 parsoid=wt2wt,html2wt
19843 foo<ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
19846 #--------- Test stripping of empty nodes in template content ----------
19848 Empty LI and TR nodes should be stripped from template content
19853 <ul typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyLITest","href":"./Template:EmptyLITest"},"params":{},"i":0}}]}'>
19857 <table typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyTRTest","href":"./Template:EmptyTRTest"},"params":{},"i":0}}]}'>
19870 Empty LI and TR nodes should not be stripped from top-level content
19897 Empty TR nodes should not be stripped if they have any attributes set
19899 {{EmptyTRWithHTMLAttrTest}}
19901 <table typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyTRWithHTMLAttrTest","href":"./Template:EmptyTRWithHTMLAttrTest"},"params":{},"i":0}}]}'>
19902 <tr align="center"></tr>
19903 <tr><td>foo</td></tr>
19904 <tr align="center"></tr>
19905 <tr><td>bar</td></tr>
19909 #### ----------------------------------------------------------------
19910 #### The following section of tests are primarily to test
19911 #### wikitext escaping capabilities of Parsoid. Given that
19912 #### escaping can be done any number of ways, the wikitext (input)
19913 #### is always adjusted to reflect how Parsoid adds nowiki
19916 #### We are marking several tests as parsoid-only since the
19917 #### HTML in the result section is different from what the
19918 #### PHP parser generates for it.
19919 #### ----------------------------------------------------------------
19922 #### --------------- Headings ---------------
19924 #### 1. Nested inside html <h1>=foo=</h1>
19925 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
19926 #### 3. Nested inside html with wikitext split by html tags
19927 #### 4. No escape needed
19928 #### 5. Empty headings <h1></h1>
19929 #### 6. Heading chars in SOL context
19930 #### ----------------------------------------
19932 Headings: 0. Unnested
19936 <nowiki>=foo=</nowiki>
19938 <nowiki> =foo= </nowiki>
19940 <nowiki>=foo=</nowiki>
19942 =foo''a''<nowiki>=</nowiki>
19944 <p><span typeof="mw:Nowiki">=foo=</span></p>
19946 <p><span typeof="mw:Nowiki"> =foo= </span>
19948 <span typeof="mw:Nowiki">=foo=</span></p>
19950 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
19953 # New headings and existing headings are handled differently
19955 Headings: 1. Nested inside html
19965 =<nowiki>=foo=</nowiki>=
19966 ==<nowiki>=foo=</nowiki>==
19967 ===<nowiki>=foo=</nowiki>===
19968 ====<nowiki>=foo=</nowiki>====
19969 =====<nowiki>=foo=</nowiki>=====
19970 ======<nowiki>=foo=</nowiki>======
19977 <h1 data-parsoid=''>=foo=</h1>
19978 <h2 data-parsoid=''>=foo=</h2>
19979 <h3 data-parsoid=''>=foo=</h3>
19980 <h4 data-parsoid=''>=foo=</h4>
19981 <h5 data-parsoid=''>=foo=</h5>
19982 <h6 data-parsoid=''>=foo=</h6>
19986 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
19991 <nowiki>*</nowiki>bar
19997 <nowiki>=bar=</nowiki>
20005 Headings: 3. Nested inside html with wikitext split by html tags
20009 = ='''bold'''<nowiki>foo=</nowiki> =
20011 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
20015 Headings: 4a. No escaping needed (testing just h1 and h2)
20033 = <nowiki>=</nowiki> =
20041 <h1><i>=</i>foo=</h1>
20042 <h1><span typeof="mw:Nowiki">=</span></h1>
20046 Headings: 4b. No escaping needed (inside p-tags)
20061 Headings: 5. Empty headings
20073 =====<nowiki/>=====
20075 ======<nowiki/>======
20086 Headings: 6a. Heading chars in SOL context (with trailing spaces)
20090 <nowiki>=a=</nowiki>
20092 <nowiki>=a=</nowiki>
20094 <nowiki>=a=</nowiki>
20096 <nowiki>=a=</nowiki>
20105 Headings: 6b. Heading chars in SOL context (with trailing newlines)
20133 Headings: 6c. Heading chars in SOL context (leading newline break)
20138 <nowiki>=b=</nowiki>
20145 Headings: 6d. Heading chars in SOL context (with interspersed comments)
20149 <!--c0--><nowiki>=a=</nowiki>
20151 <!--c1--><nowiki>=a=</nowiki> <!--c2--> <!--c3-->
20153 <p><!--c0-->=a=</p>
20154 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
20158 Headings: 6d. Heading chars in SOL context (No escaping needed)
20167 #### --------------- Lists ---------------
20168 #### 0. Outside nests (*foo, etc.)
20169 #### 1. Nested inside html <ul><li>*foo</li></ul>
20170 #### 2. Inside definition lists
20171 #### 3. Only bullets at start should be escaped
20172 #### 4. No escapes needed
20173 #### 5. No unnecessary escapes
20174 #### 6. Escape bullets in SOL position
20175 #### 7. Escape bullets in a multi-line context
20176 #### ----------------------------------------
20179 Lists: 0. Outside nests
20181 <nowiki>*</nowiki>foo
20183 <nowiki>#</nowiki>foo
20185 <nowiki>;Foo:</nowiki>bar
20194 Lists: 1. Nested inside html
20196 *<nowiki>*foo</nowiki>
20198 *<nowiki>#foo</nowiki>
20200 *<nowiki>:foo</nowiki>
20202 *<nowiki>;foo</nowiki>
20204 #<nowiki>*foo</nowiki>
20206 #<nowiki>#foo</nowiki>
20208 #<nowiki>:foo</nowiki>
20210 #<nowiki>;foo</nowiki>
20212 <ul><li>*foo</li></ul>
20213 <ul><li>#foo</li></ul>
20214 <ul><li>:foo</li></ul>
20215 <ul><li>;foo</li></ul>
20216 <ol><li>*foo</li></ol>
20217 <ol><li>#foo</li></ol>
20218 <ol><li>:foo</li></ol>
20219 <ol><li>;foo</li></ol>
20224 Lists: 2. Inside definition lists
20226 ;<nowiki>;foo</nowiki>
20228 ;<nowiki>:foo</nowiki>
20230 ;<nowiki>:foo</nowiki>
20233 :<nowiki>:foo</nowiki>
20235 <dl><dt>;foo</dt></dl>
20236 <dl><dt>:foo</dt></dl>
20239 <dl><dd>:foo</dd></dl>
20244 Lists: 3. Only bullets at start of text should be escaped
20246 *<nowiki>*foo*bar</nowiki>
20248 *<nowiki>*foo</nowiki>''it''*bar
20250 <ul><li>*foo*bar</li></ul>
20251 <ul><li>*foo<i>it</i>*bar</li></ul>
20256 Lists: 4. No escapes needed
20277 <li><a rel="mw:WikiLink" href="Foo" title="Foo">Foo</a>: bar
20281 <li><a rel="mw:WikiLink" href="Foo" title="Foo">Foo</a>*bar
20287 Lists: 5. No unnecessary escapes
20289 * bar <span><nowiki>[[foo]]</nowiki></span>
20291 *=bar <span><nowiki>[[foo]]</nowiki></span>
20293 *[[bar <span><nowiki>[[foo]]</nowiki></span>
20295 *]]bar <span><nowiki>[[foo]]</nowiki></span>
20297 *=bar <span>foo]]</span>=
20301 <ul><li> bar <span>[[foo]]</span></li></ul>
20302 <ul><li>=bar <span>[[foo]]</span></li></ul>
20303 <ul><li>[[bar <span>[[foo]]</span></li></ul>
20304 <ul><li>]]bar <span>[[foo]]</span></li></ul>
20305 <ul><li>=bar <span>foo]]</span>=</li></ul>
20306 <ul><li> <s></s>: a</li></ul>
20311 Lists: 6. Escape bullets in SOL position
20315 <!--cmt--><nowiki>*foo</nowiki>
20317 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
20321 Lists: 7. Escape bullets in a multi-line context
20324 <nowiki>*</nowiki>b
20331 #### --------------- HRs ---------------
20332 #### 1. Single line
20333 #### -----------------------------------
20336 HRs: 1. Single line
20340 ----<nowiki>----</nowiki>
20344 <hr><p><span typeof="mw:Nowiki">----</span></p>
20349 #### --------------- Tables ---------------
20350 #### 1a. Simple example
20351 #### 1b. No escaping needed (!foo)
20352 #### 1c. No escaping needed (|foo)
20353 #### 1d. No escaping needed (|}foo)
20355 #### 2a. Nested in td (<td>foo|bar</td>)
20356 #### 2b. Nested in td (<td>foo||bar</td>)
20357 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
20359 #### 3a. Nested in th (<th>foo!bar</th>)
20360 #### 3b. Nested in th (<th>foo!!bar</th>)
20361 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
20365 #### 4c. No escaping needed
20366 #### --------------------------------------
20369 Tables: 1a. Simple example
20380 Tables: 1b. No escaping needed
20389 Tables: 1c. No escaping needed
20398 Tables: 1d. No escaping needed
20407 Tables: 2a. Nested in td
20412 |<nowiki>foo|bar</nowiki>
20414 |x<div><nowiki>a|b</nowiki></div>
20418 <td>foo|bar</td></tr>
20419 <tr><td>x<div>a|b</div></td>
20424 Tables: 2b. Nested in td
20429 |<nowiki>foo||bar</nowiki>
20430 |''it''<nowiki>foo||bar</nowiki>
20434 <td><span typeof="mw:Nowiki">foo||bar</span></td>
20435 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
20439 Tables: 2c. Nested in td -- no escaping needed
20447 <table><tbody><tr><td>foo!!bar
20448 </td></tr></tbody></table>
20453 Tables: 3a. Nested in th
20461 <table><tbody><tr><th>foo!bar
20462 </th></tr></tbody></table>
20467 Tables: 3b. Nested in th
20472 !<nowiki>foo!!bar</nowiki>
20476 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
20481 Tables: 3c. Nested in th -- no escaping needed
20486 !<nowiki>foo||bar</nowiki>
20490 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
20494 Tables: 4a. Escape -
20501 |<nowiki>-bar</nowiki>
20505 <tr><th>-bar</th></tr>
20507 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
20511 Tables: 4b. Escape +
20518 |<nowiki>+bar</nowiki>
20522 <tr><th>+bar</th></tr>
20524 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
20528 Tables: 4c. No escaping needed
20549 <tr><td>foo-bar</td><td>foo+bar</td></tr>
20550 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
20556 <div>a|b</div></td>
20561 Tables: 4d. No escaping needed
20572 <tbody><tr><td><a rel="mw:WikiLink" href="./Foo" title="Foo">Foo</a>-bar</td>
20573 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>+1</td>
20574 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>-2</td></tr>
20579 Tables: Digest broken attributes on table and tr tag
20595 #### --------------- Links ----------------
20596 #### 1. Quote marks in link text
20597 #### 2. Wikilinks: Escapes needed
20598 #### 3. Wikilinks: No escapes needed
20599 #### 4. Extlinks: Escapes needed
20600 #### 5. Extlinks: No escapes needed
20601 #### --------------------------------------
20603 Links 1. Quote marks in link text
20607 [[Foo|Foo<nowiki>''boo''</nowiki>]]
20609 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
20613 Links 2. WikiLinks: Escapes needed
20618 [[Foo|<nowiki>Foobar]</nowiki>]]
20619 [[Foo|x [Foobar] x]]
20620 [[Foo|x <nowiki>[http://google.com g]</nowiki> x]]
20621 [[Foo|<nowiki>[[Bar]]</nowiki>]]
20622 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
20623 [[Foo|<nowiki>|Bar</nowiki>]]
20624 [[Foo|<nowiki>]]bar</nowiki>]]
20625 [[Foo|<nowiki>[[bar</nowiki>]]
20626 [[Foo|<nowiki>x [[ y</nowiki>]]
20627 [[Foo|<nowiki>x ]] y</nowiki>]]
20628 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
20630 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
20631 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
20632 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
20633 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
20634 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
20635 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
20636 <a href="Foo" rel="mw:WikiLink">|Bar</a>
20637 <a href="Foo" rel="mw:WikiLink">]]bar</a>
20638 <a href="Foo" rel="mw:WikiLink">[[bar</a>
20639 <a href="Foo" rel="mw:WikiLink">x [[ y</a>
20640 <a href="Foo" rel="mw:WikiLink">x ]] y</a>
20641 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
20645 Links 3. WikiLinks: No escapes needed
20652 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
20653 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
20657 Links 4. ExtLinks: Escapes needed
20661 [http://google.com <nowiki>[google]</nowiki>]
20662 [http://google.com <nowiki>google]</nowiki>]
20664 <nowiki>[http://google.com]</nowiki>
20666 <nowiki>[http://google.com google]</nowiki>
20669 <p><a href="http://google.com" rel="mw:ExtLink">[google]</a>
20670 <a href="http://google.com" rel="mw:ExtLink">google]</a></p>
20671 <p>[http://google.com]</p>
20672 <p>[http://google.com google]</p>
20676 Links 5. ExtLinks: No escapes needed
20680 [http://google.com [google]
20682 <a href="http://google.com" rel="mw:ExtLink">[google</a>
20686 Links 6. Add <nowiki/>s between text-nodes and url-links when required (bug 64300)
20688 <p>x<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>y
20689 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>?x
20690 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>&x
20691 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>'x
20692 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,x
20693 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.x
20694 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
20695 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>:x
20696 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
20697 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>!x
20698 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>=x
20699 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>(x)
20700 <a rel="mw:ExtLink" href="http://example.com(x" data-parsoid='{"stx":"url"}'>http://example.com(x</a>)
20703 x<nowiki/>http://example.com<nowiki/>y
20704 http://example.com<nowiki/>?x
20705 http://example.com<nowiki/>&x
20706 http://example.com<nowiki/>'x
20707 http://example.com<nowiki/>,x
20708 http://example.com<nowiki/>.x
20709 http://example.com<nowiki/>;x
20710 http://example.com<nowiki/>:x
20711 http://example.com<nowiki/>;x
20712 http://example.com<nowiki/>!x
20713 http://example.com<nowiki/>=x
20714 http://example.com<nowiki/>(x)
20715 http://example.com(x<nowiki/>)
20719 Links 7a. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
20722 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>
20724 "<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>"
20725 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>)
20726 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>) foo
20727 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,
20728 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>, foo
20734 "http://example.com"
20735 (http://example.com)
20736 (http://example.com) foo
20737 http://example.com,
20738 http://example.com, foo
20741 ## Parsoid currently fails wt2html on this one!
20743 Links 7b. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
20745 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.,;:!?</p>
20747 http://example.com.,;:!?
20751 Links 8. Add <nowiki/>s between text-nodes and RFC-links when required (bug 64300)
20753 <p><a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>4</p>
20759 Links 9. Don't add spurious <nowiki/>s between text-nodes and RFC-links (bug 64300)
20761 <p>x<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
20762 X<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
20763 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>?foo
20764 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>&foo
20774 Links 10. Add <nowiki/>s between text-nodes and PMID-links when required (bug 64300)
20776 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>4
20782 Links 11. Don't add spurious <nowiki/>s between text-nodes and PMID-links (bug 64300)
20784 <p>x<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
20785 X<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
20786 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>?foo
20787 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>&foo
20797 Links 12. Add <nowiki/>s between text-nodes and ISBN-links when required (bug 64300)
20799 <p><a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>1
20800 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>x
20801 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>b
20804 ISBN 1234567890<nowiki/>1
20805 ISBN 1234567890<nowiki/>x
20806 ISBN 1234567890<nowiki/>b
20810 Links 12. Don't add spurious <nowiki/>s between text-nodes and ISBN-links (bug 64300)
20812 <p><a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>'s
20817 #### --------------- Quotes ---------------
20818 #### 1. Quotes inside <b> and <i>
20819 #### 2. Link fragments separated by <i> and <b> tags
20820 #### 3. Link fragments inside <i> and <b>
20821 #### 4. No escaping needed
20822 #### --------------------------------------
20824 1. Quotes inside <b> and <i>
20826 parsoid=html2wt,wt2wt
20828 ''<nowiki/>'foo'<nowiki/>''
20829 ''<nowiki>''foo''</nowiki>''
20830 ''<nowiki>'''foo'''</nowiki>''
20832 '''<nowiki/>'foo'<nowiki/>'''
20833 '''<nowiki>''foo''</nowiki>'''
20834 '''<nowiki>'''foo'''</nowiki>'''
20835 '''foo'<nowiki/>''bar'<nowiki/>''baz'''
20836 '''foo'''<nowiki/>'s
20839 '<nowiki/>''foo''<nowiki/>'
20840 '<nowiki/>'''foo'''
20841 '''foo'''<nowiki/>'
20842 '<nowiki/>'''foo'''<nowiki/>'
20843 ''fools'<span> errand</span>''
20844 ''<span>fool</span>'s errand''
20853 <b>foo'<i>bar'</i>baz</b>
20861 <i>fools'<span> errand</span></i>
20862 <i><span>fool</span>'s errand</i>
20867 2. Link fragments separated by <i> and <b> tags
20869 [[''foo''<nowiki>hello]]</nowiki>
20871 [['''foo'''<nowiki>hello]]</nowiki>
20873 <p>[[<i>foo</i>hello]]
20874 </p><p>[[<b>foo</b>hello]]
20878 # FIXME: Escaping one or both of [[ and ]] is also acceptable --
20879 # this is one of the shortcomings of this format
20881 3. Link fragments inside <i> and <b>
20883 ''[[foo''<nowiki>]]</nowiki>
20885 '''[[foo'''<nowiki>]]</nowiki>
20888 </p><p><b>[[foo</b>]]
20893 4. No escaping needed
20895 '<span>''bar''</span>'
20896 '<span>'''bar'''</span>'
20898 <p>'<span><i>bar</i></span>'
20899 '<span><b>bar</b></span>'
20903 #### ----------- Paragraphs ---------------
20904 #### 1. No unnecessary escapes
20905 #### --------------------------------------
20908 1. No unnecessary escapes
20910 bar <span><nowiki>[[foo]]</nowiki></span>
20912 =bar <span><nowiki>[[foo]]</nowiki></span>
20914 [[bar <span><nowiki>[[foo]]</nowiki></span>
20916 ]]bar <span><nowiki>[[foo]]</nowiki></span>
20918 =bar <span>foo]]</span><nowiki>=</nowiki>
20920 <p>bar <span>[[foo]]</span>
20921 </p><p>=bar <span>[[foo]]</span>
20922 </p><p>[[bar <span>[[foo]]</span>
20923 </p><p>]]bar <span>[[foo]]</span>
20924 </p><p>=bar <span>foo]]</span>=
20928 #### ----------------------- PRE --------------------------
20929 #### 1. Leading whitespace in SOL context should be escaped
20930 #### ------------------------------------------------------
20932 1. Leading whitespace in SOL context should be escaped
20936 <nowiki> </nowiki>a
20938 <nowiki> </nowiki> a
20940 <nowiki> </nowiki>a(tab)
20942 <nowiki> </nowiki> a
20944 <nowiki> </nowiki> a
20947 <nowiki> </nowiki>b
20950 <nowiki> </nowiki>b
20953 <nowiki> </nowiki> b
20959 <p><!--cmt--> a</p>
20969 2. Leading whitespace in non-indent-pre contexts should not be escaped
20976 <p>foo <span about="#mwt2" class="reference" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"<i data-parsoid='{\"dsr\":[9,14,2,2]}'>a</i>\n b"},"attrs":{}}'><a href="#cite_note-1">[1]</a></span></p>
20980 3. Leading whitespace in indent-pre suppressing contexts should not be escaped
20999 4. Leading whitespace in indent-pre suppressing contexts should not be escaped
21003 [[File:Foobar.jpg|thumb|caption]]
21006 <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>
21010 5. Nowiki escaping should account for indent-pres
21019 #### --------------- Behavior Switches --------------------
21021 1. Valid behavior switches should be escaped
21025 <nowiki>__TOC__</nowiki>
21026 ''<nowiki>__TOC__</nowiki>''
21033 2. Invalid behavior switches should not be escaped
21044 #### --------------- HTML tags ---------------
21047 #### 3. multi-line html tag
21048 #### 4. extension tags
21049 #### -----------------------------------------
21055 <a href="http://google.com">google</a>
21057 <a href="http://google.com">google</a>
21063 <nowiki><div>foo</div>
21064 <div style="color:red">foo</div></nowiki>
21066 <p><div>foo</div>
21067 <div style="color:red">foo</div>
21072 3. multi-line html tag
21087 <nowiki><ref>foo</ref></nowiki>
21089 <nowiki><ref>bar</nowiki>
21091 baz<nowiki></ref></nowiki>
21093 <p><ref>foo</ref>
21094 </p><p><ref>bar
21095 </p><p>baz</ref>
21099 #### --------------- Others ---------------
21103 <nowiki>foo</nowiki>
21105 <p><nowiki>foo</nowiki>
21109 ## The quote-char in the input is necessary for triggering the bug
21111 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
21113 parsoid=wt2wt,html2wt
21122 Tag-like HTML structures are passed through as text
21144 </p><p>1<d e>f
21149 # This was a bug in the PHP parser (see bug 17663 and its dups,
21150 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
21152 Tag names followed by punctuation should not be recognized as tags
21156 <p><s.ome> text
21161 HTML tag with necessary entities in attributes
21163 <span title="&amp;">foo</span>
21165 <p><span title="&amp;">foo</span>
21170 HTML tag with 'unnecessary' entity encoding in attributes
21172 <span title="&">foo</span>
21174 <p><span title="&">foo</span>
21179 HTML tag with broken attribute value quoting
21181 <span title="Hello world>Foo</span>
21183 <p><span>Foo</span>
21186 <p><span title="Hello world">Foo</span>
21191 Parsoid-only: HTML tag with broken attribute value quoting
21195 <span title="Hello world>Foo</span>
21197 <p><span title="Hello world">Foo</span>
21202 Table with broken attribute value quoting
21205 | title="Hello world|Foo
21216 <td title="Hello world">Foo
21222 Table with broken attribute value quoting on consecutive lines
21225 | title="Hello world|Foo
21226 | style="color:red|Bar
21239 <td title="Hello world">Foo
21240 </td><td style="color: red">Bar
21241 </td></tr></tbody></table>
21246 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
21256 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
21266 Accept empty td cell attribute
21269 | align="center" | foo || |
21274 <td align="center"> foo </td>
21281 Non-empty attributes in th-cells
21284 ! Foo !! style="color: red" | Bar
21290 <th style="color: red"> Bar
21296 Accept empty attributes in th-cells
21311 Empty table rows go away
21332 ### Parsoid-centric tests for testing RTing of inter-element separators
21333 ### Edge cases not tested by existing parser tests and specific to
21334 ### Parsoid-specific serialization strategies.
21338 RT-ed inter-element separators should be valid separators
21350 # Parsoid-only since PHP parser relies on Tidy for correct output
21352 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
21366 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'><small data-parsoid='{"stx":"html","autoInsertedEnd":true}'>foo
21367 <p>bar</p></small></td></tr>
21371 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'><small data-parsoid='{"stx":"html","autoInsertedEnd":true}'>foo<small data-parsoid='{"stx":"html","autoInsertedEnd":true}'></small></small></td></tr>
21376 Empty TD followed by TD with tpl-generated attribute
21381 |{{echo|style='color:red'}}|foo
21395 Indented table with an empty td
21414 Indented block & table
21428 <div data-parsoid='{"stx":"html"}'>foo</div>
21430 <tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>foo</td></tr>
21435 Indent and comment before table row
21450 <!--hi--><tbody><tr data-parsoid='{"startTagSrc":"|-","autoInsertedEnd":true}'>
21451 <td data-parsoid='{"autoInsertedEnd":true}'> there</td></tr>
21455 # Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext
21457 Empty TR followed by a template-generated TR
21463 {{echo|<tr><td>foo</td></tr>}}
21469 <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}}]}'>
21474 ## PHP and parsoid output differ for this, and since this is primarily
21475 ## for testing Parsoid's serializer, marking this Parsoid only
21477 Empty TR followed by mixed-ws-comment line should RT correctly
21493 <!--c--> </tr><!--d-->
21499 Multi-line image caption generated by templates with/without trailing newlines
21501 [[File:Foobar.jpg|thumb|300x300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
21502 [[File:Foobar.jpg|thumb|300x300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
21504 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" height="34" width="300"/></a><figcaption>foo\n<span about="#mwt9" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"A"}},"i":0}}]}'>A</span>\n<span about="#mwt10" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"B"}},"i":0}}]}'>B</span>\n<span about="#mwt11" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"C"}},"i":0}}]}'>C</span></figcaption></figure>
21505 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" height="34" width="300"/></a><figcaption>foo\n<span about="#mwt12" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"A"}},"i":0}}]}'>A</span>\n<span about="#mwt13" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"B"}},"i":0}}]}'>B</span>\n<span about="#mwt14" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"C"}},"i":0}}]}'>C</span>\n\n</figcaption></figure>
21509 New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
21513 <includeonly>foo</includeonly>
21520 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>foo</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><p>new para</p>
21522 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid=''/><h1>new heading</h1>
21525 ## PHP emits broken html for this, and since this is primarily
21526 ## a Parsoid serializer test, marking this Parsoid only
21528 Improperly nested inline or quotes tags with whitespace in between
21532 <span> <s>x</span> </s>
21535 <p><span> <s>x</s></span><s> </s>
21536 <b> <i>x</i></b><i> </i>
21541 Encapsulate protected attributes from wt
21545 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
21547 <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>
21551 ## Currently the p-wrapper is fragile in how it adds / removes transformations.
21552 ## Having nested or stray pre tags results in the attempt to add duplicates,
21553 ## causing an assertion fail. This test tries to prevent that situation.
21555 Ensure ParagraphWrapper can deal with stray closing pre tags
21565 1. Ensure fostered text content is wrapped in element nodes
21569 <table>hi</table><table>ho</table>
21578 2. Ensure fostered text content is wrapped in element nodes (traps regressions around fostered marker on the element getting lost)
21580 parsoid=wt2html,wt2wt
21589 <tbody><tr><td> a</td></tr>
21594 Encapsulation properly handles null DSR information from foster box
21596 parsoid=wt2html,wt2wt
21598 {{echo|<table>foo<tr><td>bar</td></tr></table>}}
21600 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table>foo<tr><td>bar</td></tr></table>"}},"i":0}}]}">foo</span><table><tbody><tr><td>bar</td></tr></tbody></table>
21604 1. Encapsulate foster-parented transclusion content
21606 parsoid=wt2wt,wt2html
21608 <table>{{echo|foo<tr><td>bar</td></tr>}}</table>
21610 <p typeof="mw:Transclusion" data-mw="{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<tr><td>bar</td></tr>"}},"i":0}},"</table>"]}">foo</p><table>
21620 2. Encapsulate foster-parented transclusion content
21622 parsoid=wt2wt,wt2html
21624 <table><div>{{echo|foo}}</div><tr><td>bar</td></tr></table>
21626 <div typeof="mw:Transclusion" data-mw="{"parts":["<table><div>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}},"</div><tr><td>bar</td></tr></table>"]}">foo</div>
21637 3. Encapsulate foster-parented transclusion content
21639 parsoid=wt2wt,wt2html
21641 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
21643 <div typeof="mw:Transclusion" data-mw="{"parts":["<table><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div><tr><td>"}},"i":0}},"bar</td></tr></table>"]}">
21656 4. Encapsulate foster-parented transclusion content
21658 parsoid=wt2wt,wt2html
21660 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
21662 <div typeof="mw:Transclusion" data-mw="{"parts":["<table><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div><tr><td>"}},"i":0}},"bar</td></tr></table>"]}">
21675 5. Encapsulate foster-parented transclusion content
21677 parsoid=wt2wt,wt2html
21679 <table><tr><td><div><p>{{echo|foo</p></div></td>foo}}</tr></table>
21681 <p typeof="mw:Transclusion" data-mw="{"parts":["<table><tr><td><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo"}},"i":0}},"</tr></table>"]}">foo</p>
21696 6. Encapsulate foster-parented transclusion content
21698 parsoid=wt2wt,wt2html
21700 <table><tr><td><div><p>{{echo|foo</p></div></td>foo</tr></table>}}<p>ok</p>
21702 <p typeof="mw:Transclusion" data-mw="{"parts":["<table><tr><td><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo</tr></table>"}},"i":0}}]}">foo</p>
21718 7. Encapsulate foster-parented transclusion content
21720 parsoid=wt2wt,wt2html
21722 <table>{{echo|<p>foo</p>}}<td>bar</td></table>
21724 <p typeof="mw:Transclusion" data-mw="{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<p>foo</p>"}},"i":0}},"<td>bar</td></table>"]}">foo</p>
21735 8. Encapsulate foster-parented transclusion content
21737 parsoid=wt2wt,wt2html
21740 }}{|{{echo|style='color:red'}}
21745 <p typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n"}},"i":0}}]}">a</p><p 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}}}</p><table>
21755 9. Encapsulate foster-parented transclusion content
21757 parsoid=wt2wt,wt2html
21759 <table>{{echo|hi</table>hello}}
21761 <p 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</p><table about="#mwt2" data-parsoid='{"stx":"html"}'></table><p about="#mwt2">hello</p>
21765 Table in fosterable position
21767 parsoid=wt2html,wt2wt
21776 <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">
21778 <table about="#mwt1" data-parsoid='{"autoInsertedEnd":true}'></table>
21784 # Parsoid only for bug 64747
21786 Properly encapsulate empty-content transclusions in fosterable positions
21794 <table about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["<table>\n",{"template":{"target":{"wt":"#if:","function":"#if"},"params":{"1":{"wt":"\n<td>foo</td>\n"}},"i":0}},"\n</table>"]}' data-parsoid='{"stx":"html","pi":[[{"k":"1","spc":["","","",""]}]],"src":"<table>\n{{#if:|\n<td>foo</td>\n}}\n</table>"}'>
21800 Support <object> element with .data attribute
21804 <object data="test.swf"></object>
21806 <object data="test.swf"></object>
21810 Don't block XML namespace declaration
21812 <span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">MediaWiki</span>
21814 <p><span>MediaWiki</span>
21817 <p><span xmlns:dct="http://purl.org/dc/terms/" data-x-property="dct:title" data-parsoid='{"stx":"html"}'>MediaWiki</span></p>
21820 # -----------------------------------------------------------------
21821 # The following section of tests are primarily to spec requirements
21822 # around serialization of new/edited content.
21824 # All these tests are marked Parsoid html2wt and html2html only
21825 # ----------------------------------------------------------------
21827 # 'mi' is a localinterwiki prefix as well as a language
21829 Serialize interwiki links pointing to the current wiki as plain wiki links (bug 65869)
21835 <p><a rel="mw:ExtLink" href="http://mi.wikipedia.org/wiki/Foo">Foo</a></p>
21839 New wiki links (href variations)
21843 <a rel="mw:WikiLink" href="./Foo_bar">Foo_bar</a>
21844 <a rel="mw:WikiLink" href="Foo_bar">Foo_bar</a>
21845 <a rel="mw:WikiLink" href="Foo bar">Foo_bar</a>
21846 <a rel="mw:WikiLink" href="./Toxine_bact%C3%A9rienne">Toxine bactérienne</a>
21851 [[Toxine bactérienne]]
21855 New wiki links (content string variations)
21859 <a rel="mw:WikiLink" href="./Foo_bar">Foo_bar</a>
21860 <a rel="mw:WikiLink" href="./Foo_bar">Foo bar</a>
21861 <a rel="mw:WikiLink" href="./Foo_bar">./Foo_bar</a>
21865 [[Foo_bar|./Foo_bar]]
21869 New category links (href variations)
21873 <link rel="mw:PageProp/Category" href="./Category:Toxine_bactérienne" />
21874 <link rel="mw:PageProp/Category" href="./Category:Toxine_bact%C3%A9rienne" />
21875 <link rel="mw:PageProp/Category" href="Category:Toxine_bact%C3%A9rienne" />
21877 [[Category:Toxine bactérienne]]
21878 [[Category:Toxine bactérienne]]
21879 [[Category:Toxine bactérienne]]
21883 New interlanguage links (href variations)
21887 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine bactérienne" />
21888 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine_bactérienne" />
21889 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine_bact%C3%A9rienne" />
21891 [[es:Toxine bactérienne]]
21892 [[es:Toxine_bactérienne]]
21893 [[es:Toxine_bactérienne]]
21897 Image: Modifying size of an image (1)
21900 "modes": ["wt2wt"],
21902 ["img[height]", "attr", "height", "22"],
21903 ["img[width]", "attr", "width", "200"]
21907 [[Image:Foobar.jpg|230x230px]]
21909 [[Image:Foobar.jpg|200x200px]]
21913 Image: Modifying size of an image (2)
21916 "modes": ["wt2wt"],
21918 ["img[height]", "attr", "height", "100"],
21919 ["img[width]", "attr", "width", "500"]
21923 [[Image:Foobar.jpg|230x230px]]
21925 [[Image:Foobar.jpg|500x500px]]
21928 # Change in size is ignored so long as class='mw-default-size'
21930 Image: Modifying size of an image (3)
21933 "modes": ["wt2wt"],
21935 ["figure[class]", "removeClass", "mw-default-size"],
21936 ["figure img", "attr", "height", "19"],
21937 ["figure img", "attr", "width", "170"]
21941 [[Image:Foobar.jpg|thumb]]
21943 [[Image:Foobar.jpg|thumb|170x170px]]
21947 Image: Modifying alignment of an image (bug 48665)
21950 "modes": ["wt2wt"],
21952 ["figure[class]", "removeClass", "mw-halign-right"],
21953 ["figure[class]", "addClass", "mw-halign-left"]
21957 [[Image:Foobar.jpg|thumb|caption|right]]
21959 [[Image:Foobar.jpg|thumb|caption|left]]
21963 Image: Modifying mw-default-size of an frameless image (bug 62805)
21966 "modes": ["wt2wt"],
21968 ["figure.mw-default-size", "removeClass", "mw-default-size"]
21972 [[Image:Foobar.jpg|frameless|right]]
21974 [[Image:Foobar.jpg|frameless|right|220x220px]]
21978 Image: Modifying valign of an image (bug 49221)
21981 "modes": ["wt2wt"],
21983 ["*[typeof=\"mw:Image\"]", "removeClass", "mw-valign-middle"],
21984 ["*[typeof=\"mw:Image\"]", "addClass", "mw-valign-text-top"]
21988 [[File:Foobar.jpg|20px|middle]]
21990 [[File:Foobar.jpg|20px|text-top]]
21994 Image: Modifying alt attribute of an image (bug 56400)
21997 "modes": ["wt2wt"],
21999 ["img[alt]", "attr", "alt", "some alternate edited text"]
22003 [[File:Foobar.jpg|thumb|some caption|alt=some alternate text]]
22005 [[File:Foobar.jpg|thumb|some caption|alt=some alternate edited text]]
22009 Image: Modifying caption of an image
22012 "modes": ["wt2wt"],
22014 ["figcaption", "text", "new caption"]
22018 [[Image:Foobar.jpg|thumb|original caption]]
22020 [[Image:Foobar.jpg|thumb|new caption]]
22024 Image: empty alt attribute (bug 48924)
22028 [[File:Foobar.jpg|thumb|alt=|bar]]
22030 <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>
22034 #Image: new attributes should be serialized in wiki's language for RTL languages (bug 51852)
22039 #[[Imagen:Foobar.jpg|derecha|miniaturadeimagen]]
22041 #<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>
22045 Image: Block level image should have \n before and after
22048 [[File:Foobar.jpg|right|thumb|150x150px]]
22052 <figure class="mw-halign-right" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="17" width="150"/></a></figure>
22057 Image: New block level image should have \n before and after (existing content)
22060 [[File:Foobar.jpg|right|thumb|150x150px]]
22064 <figure class="mw-halign-right" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"right","ak":"right"},{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"150x150px"}]}'><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/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>
22069 Image: upright option (parsoid)
22073 [[File:Foobar.jpg|thumb|upright|caption]]
22074 [[File:Foobar.jpg|thumb|upright=0.5|caption]]
22075 [[File:Foobar.jpg|thumb|500x500px|upright=0.5|caption]]
22077 <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>
22078 <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="12" width="110"/></a><figcaption>caption</figcaption></figure>
22079 <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>
22083 Image: upright option is ignored on inline and frame images (parsoid)
22087 [[File:Foobar.jpg|500x500px|upright=0.5|caption]]
22089 <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>
22093 Image: from basic HTML (1)
22097 <span typeof="mw:Image">
22098 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
22101 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
22105 Image: from basic HTML (2)
22109 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
22111 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
22115 Image: from basic HTML (3)
22119 <a href="Main"><img src="File:Foobar.jpg" width=100 height=100 alt="Alt"></a>
22121 [[File:Foobar.jpg|link=Main|alt=Alt|100x100px]]
22125 Image: from basic HTML (4)
22129 <img src="File:Foobar.jpg">
22131 [[File:Foobar.jpg|link=]]
22135 Lists: Serialize correctly even when list content is wrapped in p-tags (like VE does)
22142 <li><p>foo</p></li>
22147 Lists: Serialize correctly even when list tags has unneeded whitespace between tags
22153 <ul> <li>foo</li></ul>
22157 Don't strip leading whitespace when handling indent-pre suppressing tags
22165 '''This is very bold of you!'''
22169 indented cell (no pre-wrapping!)
22176 <tr><td> indented row</td></tr>
22179 <b>This is very bold of you!</b>
22182 indented cell (no pre-wrapping!)
22190 Nowiki-wrap leading whitespace when handling indent-pre inducing tags
22195 <nowiki> </nowiki><span>bar</span>
22198 <nowiki> </nowiki></span>bar2
22201 <nowiki> </nowiki><span>bar</span>
22204 <nowiki> </nowiki><span>foo</span>
22222 Lists: Add space after bullets
22228 * <span> baz</span>
22233 <li><span> baz</span></li>
22238 Lists: Dont insert newlines in a serialized list item.
22245 <ul><li>a<br>b</li><li>c</li></ul>
22249 Headings: Add space before/after == (Bug 51744)
22259 == <span> baz</span> ==
22264 <h2><span> baz</span></h2>
22268 Parsoid: Serialize positional parameters with = in them as named parameter
22274 {{echo|1 = f=oo|2 = bar}}
22276 <!--Orig params with data-parsoid has heuristics for handling = chars-->
22277 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
22278 {{echo|<nowiki>f=oo</nowiki>|bar}}
22280 <p about="#mwt1" typeof="mw:Transclusion"
22281 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}}]}'>foo</p>
22283 <p about="#mwt1" typeof="mw:Transclusion"
22284 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}, "2":{"wt":"bar"}},"i":0}}]}'>foo</p>
22286 <!--Orig params with data-parsoid has heuristics for handling = chars-->
22287 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
22288 <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>
22292 Parsoid: Correctly serialize block-node children when they are a combination of text and p-nodes
22308 <div>a<p>b</p></div>
22317 Substrings resembling wikitext in hrefs should not get nowiki escapes
22323 <a rel="mw:WikiLink" href="./Foo''bar''baz">Foo''bar''baz</a>
22326 #-----------------------------
22327 # I/B quote minimization tests
22328 #-----------------------------
22331 1. I/B quote minimization: wikitext-only tags should be combined
22351 <p><i>A</i><i>B</i></p>
22352 <p><b>A</b><b>B</b></p>
22353 <p><i>A</i><b><i>B</i></b></p>
22354 <p><b>A</b><i><b>B</b></i></p>
22355 <p><b>A</b><i><b>B</b><b>C</b></i><b>D</b></p>
22356 <p><i><b>A</b></i><i><b>B</b></i></p>
22357 <p><i><b>A</b></i><b><i>B</i></b></p>
22358 <p><b><i>A</i></b><i><b>B</b></i></p>
22362 2. I/B quote minimization: wikitext and html tags should not be combined
22368 ''A''<nowiki/>'''<i>B</i>'''
22370 <p><i>A</i><i data-parsoid='{"stx":"html"}'>B</i></p>
22371 <p><i>A</i><b><i data-parsoid='{"stx":"html"}'>B</i></b></p>
22375 3. I/B quote minimization: templated content stops minimization
22379 ''A''{{echo|''B''}}
22381 ''A''{{echo|'''''B'''''}}
22383 <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>
22384 <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>
22388 4. I/B quote minimization: new content should be mimimized with adjacent old content
22398 <p><i>A</i><i>B</i></p>
22399 <p><b>A</b><b>B</b></p>
22400 <p><i>A</i><b><i>B</i></b></p>
22403 #------------------------------------
22404 # End of I/B quote minimization tests
22405 #------------------------------------
22408 Bug 54262: New entities
22414 <span typeof="mw:Entity"> </span>
22417 ## Note that there is no wikitext output for 'unknownproperty' ##
22418 ## Unknown magic words are silently dropped ##
22433 __NOCONTENTCONVERT__
22435 <meta property='mw:PageProp/toc' />
22436 <meta property='mw:PageProp/notoc' />
22437 <meta property='mw:PageProp/forcetoc' />
22438 <meta property='mw:PageProp/index' />
22439 <meta property='mw:PageProp/noindex' />
22440 <meta property='mw:PageProp/nogallery' />
22441 <meta property='mw:PageProp/noeditsection' />
22442 <meta property='mw:PageProp/notitleconvert' />
22443 <meta property='mw:PageProp/nocontentconvert' />
22444 <meta property='mw:PageProp/unknownproperty' />
22448 Consecutive <pre>s should not get merged
22450 parsoid=html2wt,html2html
22466 <pre>a</pre><pre>b</pre>
22480 Edited ISBN links not serializable as ISBN links should serialize as wikilinks
22484 [[Special:BookSources/1234567890|ISBN 1234567895]]
22486 <a rel="mw:ExtLink" href="./Special:BookSources/1234567890">ISBN 1234567895</a>
22490 Edited RFC links not serializable as RFC links should serialize as extlinks
22494 [//tools.ietf.org/html/rfc123 New RFC]
22496 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink">New RFC</a>
22500 Edited PMID links not serializable as PMID links should serialize as extlinks
22504 [//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract New PMID]
22506 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink">New PMID</a>
22510 Edited Redirect link should emit a non-piped wikitext link
22516 <link rel="mw:PageProp/redirect" href="Bar" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>
22520 T75121: Infer extension name from typeOf if data-mw is not present
22526 <div typeOf="mw:Extension/foo"></div>
22529 # -----------------------------------------------------------------
22530 # End of section for Parsoid-only html2wt tests for serialization
22532 # -----------------------------------------------------------------
22539 Try for 100% code coverage