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)
551 Italics and bold: 2-quote opening sequence: (2,4)
561 # same html as previous, but wikitext adjusted to match parsoid html2wt
563 Italics and bold: 2-quote opening sequence: (2,4) w/ nowiki
565 ''foo<nowiki>''</nowiki>''
571 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
573 Italics and bold: 2-quote opening sequence: (2,5)
586 # same html as previous, but wikitext adjusted to match parsoid html2wt
588 Italics and bold: 2-quote opening sequence: (2,5+3) w/ nowiki
590 ''foo'''''<nowiki/>'''
601 ### 3-quote opening sequence tests
605 Italics and bold: 3-quote opening sequence: (3,2)
614 Italics and bold: 3-quote opening sequence: (3,3)
623 Italics and bold: 3-quote opening sequence: (3,4)
631 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
633 Italics and bold: 3-quote opening sequence: (3,5)
646 # same html as previous, but wikitext adjusted to match parsoid html2wt
648 Italics and bold: 3-quote opening sequence: (3,5+2) w/ nowiki
650 '''foo'''''<nowiki/>''
661 ### 4-quote opening sequence tests
665 Italics and bold: 4-quote opening sequence: (4,2)
675 # same html as previous, but wikitext adjusted to match parsoid html2wt
677 Italics and bold: 4-quote opening sequence: (4,2) w/ nowiki
679 <nowiki>''</nowiki>''foo''
686 Italics and bold: 4-quote opening sequence: (4,3)
695 Italics and bold: 4-quote opening sequence: (4,4)
705 # same html as previous, but wikitext adjusted to match parsoid html2wt
707 Italics and bold: 4-quote opening sequence: (4,4) w/ nowiki
709 '<nowiki/>'''foo'<nowiki/>'''
715 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
717 Italics and bold: 4-quote opening sequence: (4,5)
726 <p>'<b>foo</b><i></i>
730 # same html as previous, but wikitext adjusted to match parsoid html2wt
732 Italics and bold: 4-quote opening sequence: (4,5+2) w/ nowiki
734 '<nowiki/>'''foo'''''<nowiki/>''
739 <p>'<b>foo</b><i></i>
745 ### 5-quote opening sequence tests
749 Italics and bold: 5-quote opening sequence: (5,2)
759 # same html as previous, but wikitext adjusted to match parsoid html2wt
760 # skipping wt2html and html2html because it wants to put <i> before <b>
762 Italics and bold: 5-quote opening sequence: (5,2+3)
764 parsoid=wt2wt,html2wt
773 Italics and bold: 5-quote opening sequence: (5,3)
783 # same html as previous, but wikitext adjusted to match parsoid html2wt
785 Italics and bold: 5-quote opening sequence: (5,3+2)
794 Italics and bold: 5-quote opening sequence: (5,4)
800 <p><i><b>foo'</b></i>
805 Italics and bold: 5-quote opening sequence: (5,5)
814 Italics and bold: 5-quote opening sequence: (5,6)
818 <p><i><b>foo'</b></i>
823 ### multiple quote sequences in a line
826 Italics and bold: multiple quote sequences: (2,4,2)
832 <p><i>foo'<b>bar</b></i>
837 # same html as previous, but wikitext adjusted to match parsoid html2wt
839 Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
841 ''foo'<nowiki/>'''bar'''''
843 <p><i>foo'<b>bar</b></i>
849 Italics and bold: multiple quote sequences: (2,4,3)
855 <p><i>foo'<b>bar</b></i>
860 # same html as previous, but wikitext adjusted to match parsoid html2wt
862 Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
864 ''foo'<nowiki/>'''bar'''''
866 <p><i>foo'<b>bar</b></i>
872 Italics and bold: multiple quote sequences: (2,4,4)
878 <p><i>foo'<b>bar'</b></i>
883 # same html as previous, but wikitext adjusted to match parsoid html2wt
885 Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
887 ''foo'<nowiki/>'''bar'<nowiki/>'''''
889 <p><i>foo'<b>bar'</b></i>
894 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
896 Italics and bold: multiple quote sequences: (3,4,2)
905 <p><b>foo'</b>bar<i></i>
909 # same html as previous, but wikitext adjusted to match parsoid html2wt
911 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
915 '''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
920 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
925 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
927 Italics and bold: multiple quote sequences: (3,4,3)
936 <p><b>foo'</b>bar<b></b>
940 # same html as previous, but wikitext adjusted to match parsoid html2wt
942 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
944 '''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
949 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
954 ### other quote tests
957 Italics and bold: other quote tests: (2,3,5)
959 ''this is about '''foo's family'''''
961 <p><i>this is about <b>foo's family</b></i>
967 Italics and bold: other quote tests: (2,(3,3),2)
969 ''this is about '''foo's''' family''
971 <p><i>this is about <b>foo's</b> family</i>
977 Italics and bold: other quote tests: (3,2,3,2)
981 '''this is about ''foo'''s family''
983 <p><b>this is about <i>foo</i></b><i>s family</i>
988 # same html as previous, but wikitext adjusted to match parsoid html2wt
990 Italics and bold: other quote tests: (3,2,3+2+2,2)
992 '''this is about ''foo'''''<nowiki/>''s family''
994 <p><b>this is about <i>foo</i></b><i>s family</i>
1000 Italics and bold: other quote tests: (3,2,3,3)
1002 '''this is about ''foo'''s family'''
1004 <p>'<i>this is about </i>foo<b>s family</b>
1010 Italics and bold: other quote tests: (3,(2,2),3)
1012 '''this is about ''foo's'' family'''
1014 <p><b>this is about <i>foo's</i> family</b>
1020 Italicized possessive
1022 The ''[[Main Page]]'''s talk page.
1024 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
1027 <p>The <i><a rel="mw:WikiLink" href="Main_Page" title="Main Page">Main Page</a>'</i>s talk page.</p>
1031 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
1032 (Requires tidy for PHP parser output to be fixed up)
1034 parsoid=wt2html,wt2wt
1051 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
1052 <td><i>a</i></td><td><i>b</i></td></tr>
1061 Non-html5 tags should be accepted
1063 <center>''foo''</center>
1065 <font>''foo''</font>
1066 <strike>''foo''</strike>
1069 <center><i>foo</i></center>
1070 <p><big><i>foo</i></big>
1071 <font><i>foo</i></font>
1072 <strike><i>foo</i></strike>
1078 <wbr> is valid wikitext (bug 52468)
1086 # <strike> is HTML4, <s> is HTML4/5.
1088 <s> or <strike> for strikethrough
1090 <strike>strike</strike>
1094 <p><strike>strike</strike>
1102 Text-level semantic html elements in wikitext
1105 <strong>text</strong>
1121 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1128 <strong>text</strong>
1144 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1152 # test cases taken from
1153 # http://www.w3.org/TR/html5/text-level-semantics.html#the-ruby-element
1155 Ruby markup (W3C-style)
1157 ; Mono-ruby for individual base characters
1158 : <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby>
1160 : <ruby>今日<rt>きょう</rt></ruby>
1162 : <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby>
1164 : <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby>
1166 : <ruby><rb>旧</rb><rb>金</rb><rb>山</rb><rt>jiù</rt><rt>jīn</rt><rt>shān</rt><rtc>San Francisco</rtc></ruby>
1168 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1169 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1170 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1173 <dl><dt> Mono-ruby for individual base characters</dt>
1174 <dd> <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby></dd>
1175 <dt> Group ruby</dt>
1176 <dd> <ruby>今日<rt>きょう</rt></ruby></dd>
1177 <dt> Jukugo ruby</dt>
1178 <dd> <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby></dd>
1179 <dt> Inline ruby</dt>
1180 <dd> <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby></dd>
1181 <dt> Double-sided ruby</dt>
1182 <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>
1184 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1185 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1186 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1191 # There is a tidy bug here: http://sourceforge.net/p/tidy/bugs/946/
1193 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
1195 <b→> doesn't work! </b→>
1197 <bä> doesn't work! </bä>
1199 <boo> works fine </boo>
1201 <s.foo>s.foo</s.foo>
1205 <p><b→> doesn't work! </b→>
1206 </p><p><bä> doesn't work! </bä>
1207 </p><p><boo> works fine </boo>
1208 </p><p><s.foo>s.foo</s.foo>
1209 </p><p><sub-ID#1>
1214 Isolated close tags should be treated as literal text (bug 52760)
1221 </p><p><s.foo>s</s>
1226 ### Special characters
1230 Bare pipe character (bug 52363)
1239 Bare pipe character from a template (bug 52363)
1248 ### <nowiki> test cases
1252 <nowiki> unordered list
1254 <nowiki>* This is not an unordered list item.</nowiki>
1256 <p>* This is not an unordered list item.
1263 <nowiki>Lorem ipsum dolor
1271 <p>Lorem ipsum dolor
1284 :There is not nowiki.
1285 :There is <nowiki>nowiki</nowiki>.
1287 #There is not nowiki.
1288 #There is <nowiki>nowiki</nowiki>.
1290 *There is not nowiki.
1291 *There is <nowiki>nowiki</nowiki>.
1293 <dl><dd>There is not nowiki.</dd>
1294 <dd>There is nowiki.</dd></dl>
1295 <ol><li>There is not nowiki.</li>
1296 <li>There is nowiki.</li></ol>
1297 <ul><li>There is not nowiki.</li>
1298 <li>There is nowiki.</li></ul>
1303 Entities inside <nowiki>
1305 <nowiki><</nowiki>
1312 Entities inside template parameters
1318 <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>
1322 Properly escape nowiki when combined with other wiki markup
1326 <nowiki>* </nowiki></nowiki> tag
1328 <p>* </nowiki> tag</p>
1335 Comments and Indent-Pre
1337 <!-- comment 1 --> asdf
1339 <!-- comment 1 --> asdf
1342 <!-- comment 1 --> asdf
1343 <!-- comment 2 -->xyz
1345 <!-- comment 1 --> asdf
1346 <!-- comment 2 --> xyz
1402 asdf<!-- comment 1 -->jkl
1412 <!-- foo --> b <!-- bar -->
1426 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1432 Comment semantics and delimiters
1434 <!-- --><!----><!-----><!------>
1440 Comment semantics and delimiters, redux
1442 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1443 -- foo -- funky huh? ... -->
1449 Comment semantics and delimiters: directors cut
1451 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1452 everything starting with < followed by !-- until the first -- and > we see,
1453 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1461 Comment semantics: nesting
1463 <!--<!-- no, we're not going to do anything fancy here -->-->
1470 Comment semantics: unclosed comment at end
1472 <!--This comment will run out to the end of the document
1477 # Bug 58184: document parsoid's behaviour
1479 Suppress comment closing tag in lenient browsers
1481 parsoid=wt2html,html2html
1483 <!-- Browsers--!> think this is closed -->
1487 <!-- Browsers--¡> think this is closed -->
1491 Comment in template title
1500 Comment on its own line post-expand
1512 Comment on its own line post-expand with non-significant whitespace
1524 Multiple comments should still parse as SOL-transparent
1526 parsoid=wt2html,wt2wt
1529 <!--c2--><!--c3--><!--c4-->*b
1540 ### paragraph wrapping tests
1555 Block tag on one line (<div>)
1571 Block tag on one line (<blockquote>)
1573 a <blockquote>foo</blockquote>
1577 a <blockquote>foo</blockquote>
1589 Block tag on both lines (<div>)
1606 Block tag on both lines (<blockquote>)
1608 a <blockquote>foo</blockquote>
1610 b <blockquote>foo</blockquote>
1612 a <blockquote>foo</blockquote>
1613 b <blockquote>foo</blockquote>
1627 Multiple lines without block tags
1651 # Tidy strips out the empty <div> tags. Parsoid doesn't.
1652 # So, we have a separate section for Parsoid. We don't want
1653 # to mimic this stripping behavior in Parsoid. It affects
1654 # editing experience and also requires us to maintain additional
1657 Empty lines between lines with block tags
1695 <div data-parsoid='{"stx":"html"}'></div>
1698 <div data-parsoid='{"stx":"html"}'></div><p>a</p>
1701 <div data-parsoid='{"stx":"html"}'>a</div><p>b</p>
1703 <div data-parsoid='{"stx":"html"}'>b</div><p>d</p>
1706 <div data-parsoid='{"stx":"html"}'>e</div>
1709 ## PHP parser emits output which is broken
1710 ## XXX The parsoid output doesn't match the tidy output.
1712 Unclosed HTML p-tags should be handled properly
1720 <p>foo</div></p>
1724 <div data-parsoid='{"stx":"html"}'><p data-parsoid='{"stx":"html", "autoInsertedEnd":true}'>foo</p></div>
1729 ## SSS FIXME: I can come up with other scenarios where this doesn't work because
1730 ## of eager output of buffered tokens in the p-wrapper. But, I'm going to ignore
1733 1. P-wrapping should leave sol-transparent tags outside p-tags where possible
1737 a [[Category:A1]] [[Category:A2]]
1742 <link href="Category:A1"/> <link href="Category:A2"/> <link href="Category:A3"/> <link href="Category:A4"/>
1746 2. P-wrapping should leave sol-transparent tags outside p-tags where possible
1752 <link href="Category:A1"/><p>a</p>
1756 ### Preformatted text
1765 And a [[Main Page|link]]
1771 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1776 Tabs don't trigger preformatted text
1780 This is preformatted text.
1786 <pre>This is preformatted text.
1792 Ident preformatting with inline content
1803 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1820 Regression with preformatted in <center>
1834 Bug 52763: Preformatted in <blockquote>
1840 indented cell (no pre-wrapping!)
1850 <p> indented cell (no pre-wrapping!)
1858 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
1875 Bug 15491: <ins>/<del> in blockquote
1878 Foo <del>bar</del> <ins>baz</ins> quux
1882 <p>Foo <del>bar</del> <ins>baz</ins> quux
1888 # Note that the p-wrapping is newline sensitive, which could be
1889 # considered a bug: tidy will wrap only the 'Foo' in the example
1890 # below in a <p> tag. (see comment 23-25 of bug #6200)
1892 Bug 15491: <ins>/<del> in blockquote (2)
1894 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1897 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1903 <del>bar</del> <ins>baz</ins> quux</blockquote>
1907 <pre> with attributes (bug 3202)
1909 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1911 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1916 <pre> with width attribute (bug 3202)
1918 <pre width="8">Narrow screen goodies</pre>
1920 <pre width="8">Narrow screen goodies</pre>
1925 <pre> with forbidden attribute (bug 3202)
1927 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1929 <pre width="8">Narrow screen goodies</pre>
1934 Entities inside <pre>
1943 <pre> with forbidden attribute values (bug 3202)
1945 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1947 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1952 <nowiki> inside <pre> (bug 13238)
1960 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1968 <pre><nowiki>Foo</nowiki></pre>
1973 <nowiki> and <pre> preference (first one wins)
2004 </pre> inside nowiki
2006 <nowiki></pre></nowiki>
2012 # Parsoid doesn't strip empty tags, like Tidy does.
2014 Empty pre; pre inside other HTML tags (bug 54946)
2016 parsoid=wt2html,wt2wt
2047 HTML pre followed by indent-pre
2062 <p><pre>foo</pre></p>
2064 <p data-parsoid='{"stx":"html","autoInsertedEnd":true}'></p><pre data-parsoid='{"stx":"html"}'>foo</pre><p data-parsoid='{"autoInsertedStart":true,"stx":"html"}'></p>
2068 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
2076 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
2086 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
2098 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
2119 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
2123 {{echo| foo}}{{echo| bar}}
2128 {{echo|<!--cmt--> foo}}
2130 <!--cmt-->{{echo| foo}}
2132 {{echo|{{echo| }}bar}}
2150 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
2187 Things that look like <pre> tags aren't treated as such
2189 Barack Obama <President> of the United States
2190 <President></President>
2192 <p>Barack Obama <President> of the United States
2193 <President></President>
2197 ## PHP parser discards the "<pre " string
2199 Handle broken pre-like tags (bug 64025)
2203 {{echo|<pre <pre>x</pre>}}
2205 <table><pre </table>
2208 <table><pre></pre></table>
2211 <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>
2220 Parsoid: handle pre with space after attribute
2224 <pre style="width:50%;" >{{echo|foo}}</pre>
2226 <pre style="width:50%;">{{echo|foo}}</pre>
2229 # TODO / maybe: fix wt2wt for this
2231 Parsoid: Don't paragraph-wrap fosterable content
2257 Parsoid: Don't paragraph-wrap fosterable content even if table syntax is unbalanced
2285 #--------------------------------------------------------------------
2286 # Transclusion parameter whitespace stripping tests
2287 # Behavior is different for positional and named parameters
2288 #--------------------------------------------------------------------
2290 Templates: Strip leading and trailing whitespace from named-param values
2294 {{echo|1= {{echo|b}} }}
2307 <ul><li> d</li></ul>
2312 Templates: Don't strip whitespace from positional-param values
2316 {{echo|{{echo|b}} }}
2348 <ul><li> f</li></ul>
2356 Templates: Handle empty comment-and-ws-only lines correctly
2359 <!--should be ignored-->
2360 <!--should be ignored as well-->
2369 Templates: Handle comments in the target
2372 <!-- should be ignored -->
2375 {{echo<!-- should be ignored -->
2378 {{echo<!-- should be ignored -->|foo}}
2380 {{<!-- should be ignored -->echo|foo}}
2382 <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>
2384 <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>
2386 <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>
2388 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2392 Templates: Handle comments in parameter names (bug 67657)
2395 <!-- should be ignored -->
2399 <!-- should be ignored -->
2402 {{echo|1<!-- should be ignored --> = foo}}
2404 {{echo|<!-- should be ignored -->1 = foo}}
2406 <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>
2408 <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>
2410 <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>
2412 <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>
2416 Templates: Other wikitext in parameter names (bug 67657)
2420 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"''1''":{"wt":"foo"}},"i":0}}]}'>{{{1}}}</p>
2426 #--------------------------------------------------------------------
2427 # Transclusion parameter escaping tests
2428 #--------------------------------------------------------------------
2430 Templates: Parsoid parameter escaping test 1
2434 {{echo|[foo]|{{echo|[bar]}}}}
2436 <p about="#mwt1" typeof="mw:Transclusion"
2437 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}}]}'>[foo]</p>
2441 Parsoid: Pipes in external links in template parameter
2445 {{echo|[{{echo|http://example.com}} link]}}
2447 <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>
2451 Parsoid: pipe in transclusion parameter
2455 {{echo|http://foo.com/a|b}}
2457 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2458 typeof="mw:Transclusion"
2459 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>
2463 Parsoid: Pipe in external link target and content in template parameter
2465 parsoid=html2wt,wt2wt
2467 {{echo|[http://foo.com/a|b a|b]}}
2469 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2470 typeof="mw:Transclusion"
2471 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},
2472 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}}]}'>a|b</a></p>
2476 Parsoid: Pipe in template with nested template in external link target in template parameter (seriously)
2480 {{echo|[{{fullurl:{{FULLPAGENAME}}|action=edit}} bar]}}
2482 <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>
2486 Templates: Don't escape already nowiki-escaped text in template parameters
2488 parsoid=html2wt,wt2wt
2490 {{echo|foo<nowiki>|</nowiki>bar}}
2491 {{echo|<nowiki><div></nowiki>}}
2492 {{echo|<nowiki></nowiki>}}
2494 <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>
2495 <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>
2496 <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>
2502 Templates: '=' char in nested transclusions should not trigger nowiki escapes or conversion to named param
2504 parsoid=html2wt,wt2wt
2506 {{echo|{{echo|1=bar}}}}
2508 <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>
2513 Templates parameters with special tokenizing behavior dont get modified because of arg escaping
2519 <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>
2523 ### Parsoid-centric tests for testing RT edge cases for pre
2527 1a. Indent-Pre and Comments
2540 1b. Indent-Pre and Comments
2553 1c. Indent-Pre and Comments
2566 1d. Indent-Pre and Comments
2567 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
2580 2a. Indent-Pre and tables
2601 2b. Indent-Pre and tables
2617 2c. Indent-Pre and tables (bug 42252)
2634 2d. Indent-Pre and tables
2651 <tbody><tr><td> b</td></tr>
2656 2e. Indent-Pre and table-line syntax
2669 2f. Indent-pre started by table-line syntax
2688 3a. Indent-Pre and block tags (single-line html)
2692 c <blockquote> foo </blockquote>
2697 c <blockquote> foo </blockquote>
2698 <pre><span> foo </span>
2701 <p>a </p><p data-parsoid='{"stx":"html"}'> foo </p>
2702 <p>b </p><div data-parsoid='{"stx":"html"}'> foo </div>
2703 <p>c </p><blockquote data-parsoid='{"stx":"html"}'> foo </blockquote>
2704 <pre><span> foo </span>
2721 3b. Indent-Pre and block tags (multi-line html)
2726 <pre>a <span>foo</span>
2731 <pre>a <span data-parsoid='{"stx":"html"}'>foo</span></pre>
2732 b <div data-parsoid='{"stx":"html"}'> foo </div>
2742 3c. Indent-Pre and block tags (pre-content on separate line)
2806 4. Indent-Pre and extension tags
2812 a <ul class="gallery mw-gallery-traditional">
2813 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
2814 <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>
2815 <div class="gallerytext">
2822 <ul class="gallery mw-gallery-traditional">
2823 <li class="gallerybox" style="width: 155px">
2824 <div style="width: 155px">
2825 <div class="thumb" style="width: 150px;">
2826 <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>
2828 <div class="gallerytext"></div>
2835 Table wikitext syntax outside wiki-tables
2838 ! not a table heading
2841 | class="foo bar" | baz
2848 ! not a table heading
2851 | class="foo bar" | baz
2860 Render paragraphs when indent-pre is suppressed in blocklevels
2877 4. Multiple spaces at start-of-line
2895 ## NOTE: the leading white-space chars on empty line are significant
2897 5a. White-space in indent-pre
2909 ## NOTE: the leading white-space chars on empty line are significant
2911 5b. White-space in indent-pre
2930 5c. White-space in indent-pre
2943 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
2966 7a. Indent-pre and category links
2968 parsoid=wt2html,wt2wt
2970 [[Category:foo]] <!-- No pre-wrapping -->
2971 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
2973 <link rel="mw:PageProp/Category" href="./Category:Foo"> <!-- No pre-wrapping -->
2974 <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 -->
2978 7b. Indent-pre and category links
2980 parsoid=wt2html,wt2wt
2983 [[Category:foo]] {{echo|b}}
2986 <link rel="mw:PageProp/Category" href="./Category:Foo"> a
2987 <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>
2991 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
2995 HTML-pre: 1. embedded newlines
3029 <pre data-parsoid='{"stx":"html"}'>foo</pre>
3031 <pre data-parsoid='{"stx":"html","strippedNL":"\n"}'>
3035 <pre data-parsoid='{"stx":"html"}'>
3040 <pre data-parsoid='{"stx":"html"}'>
3048 HTML-pre: big spaces
3085 <pre data-parsoid='{"stx":"html"}'>
3104 HTML-pre: 2: indented text
3117 HTML-pre: 3: other wikitext
3138 ### Definition lists
3145 <dl><dt> name </dt>
3146 <dd> Definition</dd></dl>
3151 Definition list for indentation only
3155 <dl><dd> Indented text</dd></dl>
3160 Definition list with no space
3165 <dd>Definition</dd></dl>
3170 Definition list with URL link
3172 ; http://example.com/ : definition
3174 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt>
3175 <dd> definition</dd></dl>
3180 Definition list with bracketed URL link
3182 ;[http://www.example.com/ Example]:Something about it
3184 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt>
3185 <dd>Something about it</dd></dl>
3190 Definition list with wikilink containing colon
3192 ; [[Help:FAQ]]: The least-read page on Wikipedia
3194 <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>
3195 <dd> The least-read page on Wikipedia</dd></dl>
3199 # At Brion's and JeLuF's insistence... :)
3201 Definition list with news link containing colon
3203 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
3205 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt>
3206 <dd> This isn't even a real newsgroup!</dd></dl>
3211 Malformed definition list with colon
3213 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
3215 <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>
3220 Definition lists: colon in external link text
3222 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
3224 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt>
3225 <dd> OK, I made that up</dd></dl>
3230 Definition lists: colon in HTML attribute
3232 ;<b style="display: inline">bold</b>
3234 <dl><dt><b style="display: inline">bold</b></dt></dl>
3239 Definition lists: self-closed tag
3241 ;one<br/>two : two-line fun
3243 <dl><dt>one<br />two </dt>
3244 <dd> two-line fun</dd></dl>
3249 Bug 11748: Literal closing tags
3253 <dd>test test test test test</dd>
3255 <dd>test test test test test</dd>
3260 <dd>test test test test test</dd>
3262 <dd>test test test test test</dd>
3268 Definition and unordered list using wiki syntax nested in unordered list using html tags.
3271 ; term : description
3276 <dl><dt> term </dt>
3277 <dd> description</dd></dl>
3278 <ul><li> unordered</li></ul>
3285 Definition list with empty definition and following paragraph
3297 Nested definition lists using html syntax
3306 Definition Lists: No nesting: Multiple dd's
3319 Definition Lists: Indentation: Regular
3327 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3332 Definition Lists: Indentation: Missing 1st level
3338 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3343 Definition Lists: Indentation: Multi-level indent
3347 <dl><dd><dl><dd><dl><dd>i3</dd></dl></dd></dl></dd></dl>
3352 Definition Lists: Hacky use to indent tables
3359 should be left alone
3361 <dl><dd><dl><dd><table>
3366 </td></tr></table></dd></dl></dd></dl>
3368 should be left alone
3373 Definition Lists: Hacky use to indent tables, with comments (bug 63979)
3381 should be left alone
3384 <dl><dd><dl><dd><table><tr>
3387 </tr></table><!-- bar --></dd></dl></dd></dl>
3389 should be left alone</p>
3393 Definition Lists: Hacky use to indent tables, with comment before table
3399 <dl><dd><dl><dd><!-- foo --><table><tr>
3401 </tr></table></dd></dl></dd></dl>
3406 Definition Lists: Hacky use to indent tables (WS-insensitive)
3415 <dd> <table><tr><td>a</td></tr></table> </dd>
3418 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
3419 ## as an empty dt item. It also ignores all but the last ";" when followed
3420 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
3421 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
3424 ## Ex: ";;t2 ::d2" is transformed into:
3436 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
3437 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
3448 ## All Parsoid only definition list tests have this difference.
3450 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
3451 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
3454 Table / list interaction: indented table with lists in table contents
3469 <ul><li> b</li></ul>
3473 <ul><li> d</li></ul>
3474 </td></tr></table></dd></dl>
3479 Table / list interaction: lists nested in tables nested in indented lists
3502 </td></tr></table></dd></dl>
3509 Definition Lists: Nesting: Multi-level (Parsoid only)
3539 Definition Lists: Nesting: Test 2 (Parsoid only)
3559 Definition Lists: Nesting: Test 3 (Parsoid only)
3587 Definition Lists: Nesting: Test 4
3592 <dl><dd><dl><dd><dl><dt>t3</dt>
3593 <dd>d3</dd></dl></dd></dl></dd></dl>
3598 ## The Parsoid team believes the following three test exposes a
3599 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
3600 ## wrong to close the <dl> after the <dt> containing the <ul>.)
3601 ## It also exposes a "misfeature" in tidy, which doesn't like
3602 ## <dl> tags with a single <dt> child; it converts the <dt> into
3603 ## a <dd> in that case. (Parsoid leaves the <dt> alone!)
3605 Definition Lists: Mixed Lists: Test 1
3611 <dl><dd><dl><dt><ul><li> foo</li>
3612 <li> bar</li></ul></dt></dl>
3613 <dl><dt> baz</dt></dl></dd></dl>
3648 Definition Lists: Mixed Lists: Test 2
3653 <ul><li><dl><dd> d1</dd>
3654 <dd> d2</dd></dl></li></ul>
3660 Definition Lists: Mixed Lists: Test 3
3665 <ul><li><dl><dd><dl><dd><dl><dd> d1</dd>
3666 <dd> d2</dd></dl></dd></dl></dd></dl></li></ul>
3672 Definition Lists: Mixed Lists: Test 4
3677 <ul><li><dl><dt>d1 </dt>
3680 <dd>d4</dd></dl></li></ul>
3686 Definition Lists: Mixed Lists: Test 5
3692 <dl><dd> d2</dd></dl></dd></dl></li></ul>
3698 Definition Lists: Mixed Lists: Test 6
3703 <ol><li><ul><li><dl><dd>d1
3704 <dl><dd><dl><dd> d3</dd></dl></dd></dl></dd></dl></li></ul></li></ol>
3710 Definition Lists: Mixed Lists: Test 7
3715 <dl><dd><ul><li> d1</li>
3716 <li> d2</li></ul></dd></dl>
3722 Definition Lists: Mixed Lists: Test 8
3727 <dl><dd><ul><li> d1</li></ul>
3728 <dl><dd><ul><li> d2</li></ul></dd></dl></dd></dl>
3734 Definition Lists: Mixed Lists: Test 9
3738 <ul><li><dl><dt>foo </dt>
3739 <dd>bar</dd></dl></li></ul>
3745 Definition Lists: Mixed Lists: Test 10
3749 <ul><li><ol><li><dl><dt>foo </dt>
3750 <dd>bar</dd></dl></li></ol></li></ul>
3754 # The Parsoid team disagrees with the PHP parser's seemingly-random
3755 # rules regarding dd/dt on the next two tests. Parsoid is more
3756 # consistent, and recognizes the shared nesting and keeps the
3757 # still-open tags around until the nesting is complete.
3758 # (And tidy again converts <dt> to <dd> before 'bar'.)
3761 Definition Lists: Mixed Lists: Test 11
3766 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt>
3767 <dd><ul><li><dl><dt><dl><dt>bar</dt></dl></dd></dl></li></ul></dd></dl>
3768 <dl><dt>boo </dt>
3769 <dd>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
3824 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3825 <dd data-parsoid='{"stx":"row"}'>bar</dd>
3829 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3830 <dd data-parsoid='{"stx":"row"}'>baz</dd>
3839 # Another case where tidy converts a <dt> to a <dd> (but Parsoid doesn't).
3841 Definition Lists: Weird Ones: Test 1
3843 *#;*::;; foo : bar (who uses this?)
3845 <ul><li><ol><li><dl><dt> foo </dt>
3846 <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>
3865 <dt>bar (who uses this?)</dt>
3897 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3898 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd>
3910 Definition Lists: colons occurring in tags
3924 <dt><span>a:b</span></dt>
3925 <dt><div>a:b</div></dt>
3928 <dt><i>a:b</i></dt></dl>
3933 Definition Lists: colons and tables 1
3945 </td></tr></table></dd></dl>
3949 </td></tr></table></dd></dl>
3953 # Parsoid's output (as documented below) differs from php's in this case.
3954 # This is probably a bug. If we fixup parsoid to match php's output, the
3955 # above test should pass and the below test case can be removed. It is
3956 # unclear which output is more desirable.
3959 Definition Lists: colons and tables 2
3971 </td></tr></table></dd>
3975 </td></tr></table></dd></dl>
3983 External links: non-bracketed
3985 Non-bracketed: http://example.com
3987 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3991 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3993 External links: numbered
3995 Numbered: [http://example.com]
3996 Numbered: [http://example.net]
3997 Numbered: [http://example.com]
3999 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
4000 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
4001 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
4004 <p>Numbered: <a rel="mw:ExtLink" href="http://example.com"></a>
4005 Numbered: <a rel="mw:ExtLink" href="http://example.net"></a>
4006 Numbered: <a rel="mw:ExtLink" href="http://example.com"></a></p>
4010 External links: specified text
4012 Specified text: [http://example.com link]
4014 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
4019 External links: trail
4021 Linktrails should not work for external links: [http://example.com link]s
4023 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
4028 External links: dollar sign in URL
4030 http://example.com/1$2345
4032 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
4036 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4038 External links: dollar sign in URL (autonumber)
4040 [http://example.com/1$2345]
4042 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
4045 <p><a rel="mw:ExtLink" href="http://example.com/1$2345"></a></p>
4049 External links: open square bracket forbidden in URL (bug 4377)
4051 parsoid=wt2html,wt2wt,html2html
4053 http://example.com/1[2345
4055 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
4058 <p><a rel="mw:ExtLink" href="http://example.com/1">http://example.com/1</a>[2345</p>
4062 External links: open square bracket forbidden in URL (named) (bug 4377)
4064 parsoid=wt2html,html2html
4066 [http://example.com/1[2345]
4068 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
4071 <p><a rel="mw:ExtLink" href="http://example.com/1">[2345</a></p>
4074 # parsoid adds a space before the link name
4076 External links: open square bracket forbidden in URL (named) (bug 4377)
4079 [http://example.com/1 [2345]
4081 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
4086 External links: nowiki in URL link text (bug 6230)
4088 [http://example.com/ <nowiki>''example site''</nowiki>]
4090 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
4095 External links: newline forbidden in text (bug 6230 regression check)
4097 [http://example.com/ first
4100 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
4106 External links: Pipe char between url and text
4108 [http://example.com | link]
4110 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
4115 External links: protocol-relative URL in brackets
4117 [//example.com/ Test]
4119 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
4123 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4125 External links: protocol-relative URL in brackets without text
4129 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
4132 <p><a rel="mw:ExtLink" href="//example.com"></a></p>
4136 External links: protocol-relative URL in free text is left alone
4140 <p>//example.com/Foo
4145 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
4147 foo//example.com/Foo
4149 <p>foo//example.com/Foo
4154 External links: with no contents
4156 [http://en.wikipedia.org/wiki/Foo]
4158 [[wikipedia:Foo|Bar]]
4160 [[wikipedia:Foo|<span>Bar</span>]]
4162 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/wiki/Foo">[1]</a>
4163 </p><p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo">Bar</a>
4164 </p><p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo"><span>Bar</span></a>
4167 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo"></a></p>
4168 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="wikipedia:Foo">Bar</a></p>
4169 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="wikipedia:Foo"><span>Bar</span></a></p>
4173 External links: Free with trailing punctuation
4183 http://example.com/url_with_(brackets)
4184 (http://example.com/url_without_brackets)
4185 http://example.com/url_with_entity
4186 http://example.com/url_with_entity 
4187 http://example.com/url_with_entity 
4188 http://example.com/url_with_entity<
4189 http://example.com/url_with_entity<
4190 http://example.com/url_with_entity<
4192 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>,
4193 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>;
4194 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>\
4195 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>.
4196 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>:
4197 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>!
4198 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>?
4199 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4200 <a rel="nofollow" class="external free" href="http://example.com/url_with_(brackets)">http://example.com/url_with_(brackets)</a>
4201 (<a rel="nofollow" class="external free" href="http://example.com/url_without_brackets">http://example.com/url_without_brackets</a>)
4202 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity ">http://example.com/url_with_entity </a>
4203 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity ">http://example.com/url_with_entity </a>
4204 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity ">http://example.com/url_with_entity </a>
4205 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><
4206 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity%3C">http://example.com/url_with_entity%3C</a>
4207 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity%3C">http://example.com/url_with_entity%3C</a>
4212 External links: No preceding word characters allowed (bug 65278)
4214 NOPEhttp://example.com
4215 N0http://example.com
4216 ok:http://example.com
4217 ok-http://example.com
4219 <p>NOPEhttp://example.com
4220 N0http://example.com
4221 ok:<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4222 ok-<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4229 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4231 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
4236 External image from https
4238 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4240 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
4245 External image (when not allowed)
4247 wgAllowExternalImages=0
4249 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4251 <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>
4256 Link to non-http image, no img tag
4258 Link to non-http image, no img tag: ftp://example.com/test.jpg
4260 <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>
4265 External links: terminating separator
4267 Terminating separator: http://example.com/thing,
4269 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
4274 External links: intervening separator
4276 Intervening separator: http://example.com/1,2,3
4278 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
4283 External links: old bug with URL in query
4285 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
4287 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
4292 External links: old URL-in-URL bug, mixed protocols
4294 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
4296 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
4301 External links: URL in text
4303 URL in text: [http://example.com http://example.com]
4305 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4310 External links: Clickable images
4312 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
4314 <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>
4319 External links: raw ampersand
4321 Old & use: http://x&y
4323 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
4328 External links: encoded ampersand
4330 Old & use: http://x&y
4332 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
4335 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y">http://x&y</a></p>
4339 External links: encoded equals (bug 6102)
4341 http://example.com/?foo=bar
4343 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
4346 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a></p>
4350 ## Note that parsoid doesn't explicit mark autonumbered links, nor
4351 ## does it number them. As discussed in bug 53505, we can identify
4352 ## autonumbered links via CSS.
4356 External links: [raw ampersand]
4358 Old & use: [http://x&y]
4360 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
4363 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
4366 # note that parsoid html is identical to [raw ampersand] case; so html2wt
4367 # mode will return the [raw ampersand] wikitext
4369 External links: [encoded ampersand]
4371 parsoid=wt2html,wt2wt,html2html
4373 Old & use: [http://x&y]
4375 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
4378 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
4382 External links: [raw equals]
4384 [http://example.com/?foo=bar]
4386 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
4389 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
4392 # note that parsoid html is identical to [raw equals] case; so html2wt
4393 # mode will return the [raw equals] wikitext
4395 External links: [encoded equals] (bug 6102)
4397 parsoid=wt2html,wt2wt,html2html
4399 [http://example.com/?foo=bar]
4401 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
4404 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
4407 # xxx parsoid strips the IDN character, so the round-trip tests will
4408 # obviously fail and are disabled. --cscott
4410 External links: [IDN ignored character reference in hostname; strip it right off]
4412 parsoid=wt2html,wt2wt,html2html
4414 [http://e‌xample.com/]
4416 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
4419 <p><a rel="mw:ExtLink" href="http://example.com/"></a></p>
4422 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
4423 # Where an external link could easily circumvent the sanitization of the text of
4424 # a link like this (where an IDN-ignore character is in the URL somewhere), this
4425 # test demands a higher standard. That's a bit strange.
4429 # http://example.com -> [http://example.com|http://example.com]
4430 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
4432 # The first example is sanitized, but the second is not. Any security benefits
4433 # from this production are trivial to circumvent. Either remove this test and
4434 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
4435 # the test accordingly.
4439 # xxx parsoid strips the IDN character, so the round-trip tests will
4440 # obviously fail and are disabled. --cscott
4442 External links: IDN ignored character reference in hostname; strip it right off
4444 parsoid=wt2html,html2html
4446 http://e‌xample.com/
4448 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
4451 <p><a rel="mw:ExtLink" href="http://example.com/">http://example.com/</a></p>
4455 External links: www.jpeg.org (bug 554)
4459 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
4463 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4465 External links: URL within URL (original bug 2)
4467 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
4469 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
4472 <p><a rel="mw:ExtLink" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp"></a></p>
4476 BUG 361: URL inside bracketed URL
4478 [http://www.example.com/foo http://www.example.com/bar]
4480 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
4485 BUG 361: URL within URL, not bracketed
4487 http://www.example.com/foo?=http://www.example.com/bar
4489 <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>
4494 BUG 289: ">"-token in URL-tail
4496 http://www.example.com/<hello>
4498 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
4503 BUG 289: literal ">"-token in URL-tail
4505 http://www.example.com/<b>html</b>
4507 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
4512 BUG 289: ">"-token in bracketed URL
4514 [http://www.example.com/<hello> stuff]
4516 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
4521 BUG 289: literal ">"-token in bracketed URL
4523 [http://www.example.com/<b>html</b> stuff]
4525 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
4530 BUG 289: literal double quote at end of URL
4532 http://www.example.com/"hello"
4534 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
4539 BUG 289: literal double quote in bracketed URL
4541 [http://www.example.com/"hello" stuff]
4543 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
4548 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
4550 [http://www.example.com test]
4552 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
4557 External links: link text with spaces
4559 [http://www.example.com a b c]
4560 [http://www.example.com ''a'' ''b'']
4562 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
4563 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
4568 External links: wiki links within external link (Bug 3695)
4570 [http://example.com [[wikilink]] embedded in ext link]
4572 <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>
4575 <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>
4579 BUG 787: Links with one slash after the url protocol are invalid
4583 [http:/example.com title]
4585 <p>http:/example.com
4586 </p><p>[http:/example.com title]
4591 Bracketed external links with template-generated invalid target
4593 [{{echo|http:/example.com}} title]
4595 <p>[http:/example.com title]
4600 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
4602 ''[http://example.com text'']
4603 [http://example.com '''text]'''
4604 ''Something [http://example.com in italic'']
4605 ''Something [http://example.com mixed''''', even bold]'''
4606 '''''Now [http://example.com both''''']
4608 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
4609 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
4610 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
4611 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
4612 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
4618 Bug 4781: %26 in URL
4620 http://www.example.com/?title=AT%26T
4622 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
4625 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a></p>
4628 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
4629 # % is actually legal in HTML5. Any change in output would need testing though.
4631 Bug 4781, 5267: %25 in URL
4633 http://www.example.com/?title=100%25_Bran
4635 <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>
4638 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a></p>
4642 Bug 4781, 5267: %28, %29 in URL
4644 http://www.example.com/?title=Ben-Hur_%281959_film%29
4646 <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>
4649 <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>
4654 Bug 4781: %26 in autonumber URL
4656 [http://www.example.com/?title=AT%26T]
4658 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
4661 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T"></a></p>
4665 Bug 4781, 5267: %26 in autonumber URL
4667 [http://www.example.com/?title=100%25_Bran]
4669 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
4672 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran"></a></p>
4676 Bug 4781, 5267: %28, %29 in autonumber URL
4678 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
4680 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
4683 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29"></a></p>
4688 Bug 4781: %26 in bracketed URL
4690 [http://www.example.com/?title=AT%26T link]
4692 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
4695 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">link</a></p>
4699 Bug 4781, 5267: %25 in bracketed URL
4701 [http://www.example.com/?title=100%25_Bran link]
4703 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
4708 Bug 4781, 5267: %28, %29 in bracketed URL
4710 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
4712 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
4715 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a></p>
4719 External link containing a period in the anchor. (bug 63947)
4721 [//foo.org/bar#baz. bang]
4723 [//foo.org/bar. bang]
4725 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4726 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4729 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4730 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4734 External link containing a single quote. (bug 63947)
4738 [//foo.org/bar'baz bang]
4740 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4741 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4744 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4745 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4750 External link containing a period in the anchor. (bug 63947)
4752 [//foo.org/bar#baz. bang]
4754 [//foo.org/bar. bang]
4756 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4757 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4760 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4761 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4765 External link containing a single quote. (bug 63947)
4769 [//foo.org/bar'baz bang]
4771 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4772 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4775 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4776 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4781 External link containing double-single-quotes in text '' (bug 4598 sanity check)
4783 Some [http://example.com/ pretty ''italics'' and stuff]!
4785 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
4790 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
4792 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
4794 <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>
4799 External link containing double-single-quotes with no space separating the url from text in italics
4801 [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]].]
4803 <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>
4806 <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>
4808 <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>
4812 External link with comments in link text
4814 [http://www.google.com Google <!-- comment -->]
4816 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
4821 URL-encoding in URL functions (single parameter)
4823 {{localurl:Some page|amp=&}}
4825 <p>/index.php?title=Some_page&amp=&
4830 URL-encoding in URL functions (multiple parameters)
4832 {{localurl:Some page|q=?&=&}}
4834 <p>/index.php?title=Some_page&q=?&amp=&
4841 http://example.com/index.php?foozoid%5B%5D=bar
4843 http://example.com/index.php?foozoid[]=bar
4845 <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>
4846 </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>
4849 <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>
4851 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid[]=bar">http://example.com/index.php?foozoid[]=bar</a></p>
4855 IPv6 urls (bug 21261)
4859 http://[2404:130:0:1000::187:2]/index.php
4861 <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>
4866 Non-extlinks in brackets
4875 [{{echo|foo}} ''bar'']
4876 [{{echo|foo}}l's] errand
4877 [{{echo|foo}}l's errand]
4879 [url=http://example.com]
4892 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
4897 Percent encoding in external links
4899 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
4901 <p><a rel="nofollow" class="external text" href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a>
4904 <p><a rel="mw:ExtLink"
4905 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
4909 Use url link syntax for links where the content is equal the link target
4913 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4916 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
4920 Parenthesis in external links, especially URL links
4924 http://example.com/test)
4926 http://example.com/(test)
4928 http://example.com/((test)
4930 (http://example.com/(test))
4932 (http://example.com/(test)))))
4934 http://example.com/a)b
4936 [http://example.com) foo]
4938 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4939 </p><p><a rel="nofollow" class="external free" href="http://example.com/test">http://example.com/test</a>)
4940 </p><p><a rel="nofollow" class="external free" href="http://example.com/(test)">http://example.com/(test)</a>
4941 </p><p><a rel="nofollow" class="external free" href="http://example.com/((test)">http://example.com/((test)</a>
4942 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test))">http://example.com/(test))</a>
4943 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test)))))">http://example.com/(test)))))</a>
4944 </p><p><a rel="nofollow" class="external free" href="http://example.com/a)b">http://example.com/a)b</a>
4945 </p><p><a rel="nofollow" class="external text" href="http://example.com)">foo</a>
4948 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)</p>
4949 <p><a rel="mw:ExtLink" href="http://example.com/test">http://example.com/test</a>)</p>
4950 <p><a rel="mw:ExtLink" href="http://example.com/(test)">http://example.com/(test)</a></p>
4951 <p><a rel="mw:ExtLink" href="http://example.com/((test)">http://example.com/((test)</a></p>
4952 <p>(<a rel="mw:ExtLink" href="http://example.com/(test))">http://example.com/(test))</a></p>
4953 <p>(<a rel="mw:ExtLink" href="http://example.com/(test)))))">http://example.com/(test)))))</a></p>
4954 <p><a rel="mw:ExtLink" href="http://example.com/a)b">http://example.com/a)b</a></p>
4955 <p><a rel="mw:ExtLink" href="http://example.com)">foo</a></p>
4959 Parenthesis in external links, w/ transclusion or comment
4961 (http://example.com/{{echo|hi}})
4963 (http://example.com<!-- hi -->)
4965 <p>(<a rel="nofollow" class="external free" href="http://example.com/hi">http://example.com/hi</a>)
4966 </p><p>(<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4969 <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>
4971 <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>
4975 Replace invalid link targets when serializing
4979 <a rel="mw:WikiLink" href="./]] foo [[bar">Manual</a>
4981 [[MediaWiki:Badtitletext|Manual]]
4991 Normal text. '''Bold text.''' Normal text. ''Italic text.''
4993 Normal text. '''''Bold italic text.''''' Normal text.
4995 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
4996 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
5001 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
5002 # parser strips. The wikitext contains just the first half of the bold
5005 Unclosed and unmatched quotes
5007 '''''Bold italic text '''with bold deactivated''' in between.'''''
5009 '''''Bold italic text ''with italic deactivated'' in between.'''''
5013 ..spanning two paragraphs (should not work).'''
5015 '''Bold tag left open
5017 ''Italic tag left open
5021 <!-- Unmatching number of opening, closing tags: -->
5022 '''This year''''s election ''should'' beat '''last year''''s.
5024 ''Tom'''s car is bigger than ''Susan'''s.
5026 Plain ''italic'''s plain
5028 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
5029 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
5030 </p><p><b>Bold text..</b>
5031 </p><p>..spanning two paragraphs (should not work).
5032 </p><p><b>Bold tag left open</b>
5033 </p><p><i>Italic tag left open</i>
5035 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
5036 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
5037 </p><p>Plain <i>italic'</i>s plain
5040 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
5041 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
5042 </p><p><b>Bold text..</b>
5043 </p><p>..spanning two paragraphs (should not work).<b></b>
5044 </p><p><b>Bold tag left open</b>
5045 </p><p><i>Italic tag left open</i>
5047 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
5048 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
5049 </p><p>Plain <i>italic'</i>s plain
5056 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
5059 # This should not produce <table></table> as <table><tr><td></td></tr></table>
5060 # is the bare minimum required by the spec, see:
5061 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
5062 # Parsoid team replies: empty table tags are legal in HTML5
5064 A table with no data.
5077 A table with stray table end tags on start tag line (wt2html)
5081 {|style="color: red;"|}
5083 {|style="color: red;" |}
5087 {|style="color: red;"|} id="foo"
5091 {|style="color: red;" |} id="foo"
5095 <table style="color: red;"></table>
5097 <table style="color: red;">
5103 <table style="color: red;" id="foo">
5109 <table style="color: red;" id="foo">
5118 A table with no data (take 2)
5126 # A table with nothing but a caption is invalid XHTML, we might want to render
5127 # this as <p>caption</p>
5128 # Parsoid team replies: table with only a caption is legal in HTML5
5130 A table with nothing but a caption
5138 </caption><tr><td></td></tr></table>
5141 <table><caption> caption</caption></table>
5145 A table with caption with default-spaced attributes and a table row
5148 |+ style="color: red;" | caption1
5154 <caption style="color: red;"> caption1
5163 A table with captions with non-default spaced attributes and a table row
5166 |+style="color: red;"|caption2
5167 |+ style="color: red;"| caption3
5173 <caption style="color: red;">caption2
5175 <caption style="color: red;"> caption3
5184 Table td-cell syntax variations
5188 | foo bar foo || baz
5189 | style='color:red;' | baz
5190 | style='color:red;' || baz
5197 <td> foo bar foo </td>
5200 <td style="color:red;"> baz
5202 <td> style='color:red;' </td>
5230 Simple table but with multiple dashes for row wikitext
5248 Multiplication table
5250 {| border="1" cellpadding="2"
5251 |+Multiplication table
5253 ! × !! 1 !! 2 !! 3
5271 <table border="1" cellpadding="2">
5272 <caption>Multiplication table
5319 Accept "||" in table headings
5334 Accept "!!" in table data
5348 <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>
5353 Accept "||" in indented table headings
5363 </th></tr></table></dd></dl>
5368 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
5385 Accept "| !" at start of line in tables (ignore !-attribute)
5389 | !style="color:red" | bar
5401 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 +/-
5405 |style='color:red;'|+1
5406 |style='color:blue;'|-1
5418 <td style="color:red;">+1
5420 <td style="color:blue;">-1
5444 |rowspan=2| Cell 2, row 1 (and 2)
5455 <td rowspan="2"> Cell 2, row 1 (and 2)
5473 {| bgcolor=#ABCDEF border=2
5478 |the original table again
5486 <table bgcolor="#ABCDEF" border="2">
5494 <td>the original table again
5500 Invalid attributes in table cell (bug 1830)
5514 # The "|}" to close the table is missing from the input, so parsoid's
5515 # *2wt modes will fail.
5517 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
5519 parsoid=wt2html,html2html
5522 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
5526 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
5527 <td>]" onmouseover="alert(document.cookie)">test
5535 <td><a rel="mw:ExtLink" href="ftp://|x||"></a>" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
5540 Indented table markup mixed with indented pre content (proposed in bug 6200)
5545 Text that should be rendered preformatted
5553 <pre>Text that should be rendered preformatted
5562 Template-generated table cell attributes and cell content
5567 | <!--foo--> <!--bar--> <!--baz--> {{table_attribs}}
5568 |align=center {{table_attribs}}
5569 | <!--foo--> align=center <!--bar--> {{table_attribs}}
5574 <td style="color: red"> Foo
5576 <td style="color: red"> Foo
5578 <td style="color: red"> Foo
5580 <td align="center" style="color: red"> Foo
5582 <td align="center" style="color: red"> Foo
5588 Template-generated table cell attributes and cell content (2)
5591 |align=center {{table_cells}}
5596 <td align="center" style="color: red"> Foo </td>
5604 Table with row followed by newlines and table heading
5622 Table with empty line following the start tag
5639 # FIXME: Preserve the attribute properly (with an empty string as value) in
5640 # the PHP parser. Parsoid implements the behavior below.
5642 Table attributes with empty value
5652 </td></tr></tbody></table>
5657 Wikitext table with a lot of comments
5680 Wikitext table with double-line table cell
5697 Table cell with a single comment
5714 Table-cell after a comment-only-empty-line
5731 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>a</td>
5733 <!--c2--><td data-parsoid='{"autoInsertedEnd":true}'> b</td></tr>
5739 Build table with {{!}}
5741 {{{!}} class="wikitable"
5744 {{!}}- style="color:red;"
5745 {{!}} data {{!}}{{!}} style="color:red;" {{!}} second data
5748 <table class="wikitable">
5754 <tr style="color:red;">
5756 <td style="color:red;"> second data
5762 Build table with pipe as data
5764 {| class="wikitable"
5767 |- style="color:red;"
5768 | data || style="color:red;" | second data
5770 | style="color:red;" | data with | || style="color:red;" | second data with |
5772 || data with | ||| second data with |
5775 <table class="wikitable">
5781 <tr style="color:red;">
5783 <td style="color:red;"> second data
5786 <td style="color:red;"> data with | </td>
5787 <td style="color:red;"> second data with |
5790 <td> data with | </td>
5791 <td> second data with |
5797 Build table with wikilink
5799 {| class="wikitable"
5800 ! header || second header
5801 |- style="color:red;"
5802 | data [[Main Page|linktext]] || second data [[Main Page|linktext]]
5804 | data || second data [[Main Page|link|text with pipe]]
5807 <table class="wikitable">
5812 <tr style="color:red;">
5813 <td> data <a href="/wiki/Main_Page" title="Main Page">linktext</a> </td>
5814 <td> second data <a href="/wiki/Main_Page" title="Main Page">linktext</a>
5818 <td> second data <a href="/wiki/Main_Page" title="Main Page">link|text with pipe</a>
5823 # The expected HTML structure in this test is debatable. The PHP parser does
5824 # not parse this kind of table at all. The main focus for Parsoid is on
5825 # round-tripping, so this output is ok for now. TODO: revisit!
5827 Wikitext table with html-syntax row
5837 <td>foo</td></tr></tbody></table>
5840 ## Note that Parsoid output differs from PHP and PHP+tidy here.
5841 ## The lack of <tr> tags in the PHP output is arguably a bug in the
5842 ## PHP parser, which tidy then compounds by fostering the content
5843 ## entirely out of the table. Parsoid recognizes the table context
5844 ## and generates <tr> and <td> wrappers as needed. Hopefully nobody
5845 ## depends on PHP's treatment of broken table markup!
5847 Implicit <td> after a |-
5849 parsoid=wt2html,html2html
5869 # Again, Parsoid adds implicit <td>s here, PHP and Tidy strip the b out.
5871 <pre> tags should be recognized in an explicit <td> context, but not in an implicit <td> context
5873 parsoid=wt2html,html2html
5906 <tr><td><pre>a</pre></td></tr>
5907 <tr><td> b</td></tr>
5912 # PHP + Tidy strips the list out of the table; Parsoid wraps it.
5913 # Parsoid generates the missing <td>, so wt2wt won't succeed.
5915 Lists should be recognized in an implicit <td> context
5917 parsoid=wt2html,html2html
5944 Parsoid: Round-trip tables directly followed by content (bug 51219)
5946 parsoid=wt2html,wt2wt
5971 Parsoid: Default to a newline after tables in new content (bug 51219)
5978 <nowiki> </nowiki>bar
5985 <tr><td>foo</td></tr></tbody></table> bar
5987 <tr><td>baz</td></tr></tbody></table><b>quux</b>
5991 Parsoid: newline inducing block nodes don't suppress <nowiki>
6003 Parsoid: Row-syntax table headings followed by comment & table cells
6005 parsoid=wt2html,wt2wt
6009 <!-- foo --> || baz || quux
6023 <tbody><tr><th> foo </th><th> bar
6024 <!-- foo --> </th><td> baz </td><td> quux</td></tr>
6029 # PHP throws away the (semi-broken) "foo" class here; Parsoid
6032 Parsoid: Recover better from broken table attributes
6052 <p>foo</p></td></tr>
6057 Strip unsupported table tags
6108 Plain link, capitalized
6112 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6117 Plain link, uncapitalized
6121 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
6128 [[Main Page|The Main Page]]
6130 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
6135 Piped link with comment in link text
6137 [[Main Page|The Main<!--front--> Page]]
6139 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
6144 Piped link with multiple pipe characters in link text
6146 [[Main Page||The|Main|Page|]]
6148 <p><a href="/wiki/Main_Page" title="Main Page">|The|Main|Page|</a>
6151 <p><a rel="mw:WikiLink" href="Main_Page" title="Main Page">|The|Main|Page|</a></p>
6159 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
6164 Broken link with fragment
6166 [[Zigzagzogzagzig#zug]]
6168 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
6173 Special page link with fragment
6175 [[Special:Version#anchor]]
6177 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
6182 Nonexistent special page link with fragment
6184 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
6186 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
6193 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
6195 <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>
6202 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
6204 <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>!!!
6215 Bug 43661: Piped links with identical prefixes
6217 [[prefixed article|prefixed articles with spaces]]
6219 [[prefixed article|prefixed articlesaoeu]]
6221 [[Main Page|Main Page test]]
6223 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
6224 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
6225 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
6231 Link with HTML entity in suffix / tail
6233 [[Main Page]]", [[Main Page]]a
6235 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
6240 Link with 3 brackets
6249 Link with 4 brackets
6253 <p>[[<a href="/wiki/Main_Page" title="Main Page">Main Page</a>]]
6258 Piped link with 3 brackets
6260 [[[main page|the main page]]]
6262 <p>[[[main page|the main page]]]
6267 Piped link with extlink-like text
6270 [[Main Page|This is a [bar]]]
6272 <p><a href="/wiki/Main_Page" title="Main Page">[bar]</a>
6273 <a href="/wiki/Main_Page" title="Main Page">This is a [bar]</a>
6278 Link with multiple pipes
6280 [[Main Page|The|Main|Page]]
6282 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
6286 # Note that parsoid does not munge anchor text; all non-space
6287 # characters are valid in HTML5 ids.
6289 Anchor containing a #. (bug 63430)
6291 [[Main Page#And#Link]]
6293 <p><a href="/wiki/Main_Page#And.23Link" title="Main Page">Main Page#And#Link</a>
6296 <p><a rel="mw:WikiLink" href="./Main_Page#And%23Link" title="Main Page">Main Page#And#Link</a></p>
6302 [[Talk:Parser testing]], [[Meta:Disclaimers]]
6304 <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>
6309 Link with space in namespace
6311 [[User talk:Foo bar]]
6313 <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>
6318 MemoryAlpha:AlphaTest
6320 This is an article in the MemoryAlpha namespace
6321 (which shadows the memoryalpha interwiki link).
6325 Namespace takes precedence over interwiki link (bug 51680)
6327 [[MemoryAlpha:AlphaTest]]
6329 <p><a href="/wiki/MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
6333 # The previous test doesn't work correctly in html2*, due to not recognizing the
6334 # link as an internal one. This one checks for the correct behavior.
6336 Link to namespace preferred over interwiki with correct rel attribute
6338 parsoid=html2wt,html2html
6340 [[MemoryAlpha:AlphaTest]]
6342 <p><a rel="mw:WikiLink" href="./MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
6347 Piped link to namespace
6349 [[Meta:Disclaimers|The disclaimers]]
6351 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
6358 [[Usually caused by a typo (oops}]]
6360 <p>[[Usually caused by a typo (oops}]]
6367 Just a test of an article title containing a percent.
6371 Link containing % (not as a hex sequence)
6375 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
6378 <p><a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7% Solution</a></p>
6381 # note that the parsoid HTML is identical to the previous test output,
6382 # so the previous test ensures that the html2wt mode will generate the
6383 # "not as a hex sequence" wikitext.
6385 Link containing % as a single hex sequence interpreted to char
6387 parsoid=wt2wt,wt2html,html2html
6391 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
6394 <p><a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7% Solution</a></p>
6398 Link containing % as a double hex sequence interpreted to hex sequence
6402 <p>[[7%2525 Solution]]
6406 # note that parsoid does not munge anchor text; all non-space
6407 # characters are valid in HTML5 anchors.
6409 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
6410 Example for such a section: == < ==
6412 [[%23%3c]][[%23%3e]]
6414 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
6417 <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>
6421 Link containing "<#" and ">#" as a hex sequences
6423 [[%3c%23]][[%3e%23]]
6425 <p>[[%3c%23]][[%3e%23]]
6430 Link containing an equals sign
6432 [[Special:BookSources/isbn=4-00-026157-6]]
6434 <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>
6437 <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>
6443 Just a test of an article title containing a tilde.
6446 # note that links containing signatures, like [[Foo~~~~]], are
6447 # massaged by the pre-save transform (PST) and so the tildes are never
6448 # seen by the parser.
6450 Link containing a tilde
6454 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
6457 <p><a rel="mw:WikiLink" href="./Foo~bar" title="Foo~bar">Foo~bar</a></p>
6461 Link containing double-single-quotes '' (bug 4598)
6463 [[Lista d''e paise d''o munno]]
6465 <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>
6468 <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>
6472 Link containing double-single-quotes '' in text (bug 4598 sanity check)
6474 Some [[Link|pretty ''italics'' and stuff]]!
6476 <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>!
6479 <p>Some <a rel="mw:WikiLink" href="Link" title="Link">pretty <i>italics</i> and stuff</a>!</p>
6483 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
6485 ''Some [[Link|pretty ''italics'' and stuff]]!''
6487 <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>
6492 Link with double quotes in title part (literal) and alternate part (interpreted)
6494 [[File:Denys_Savchenko_''Pentecoste''.jpg]]
6498 [[''Pentecoste''|Pentecoste]]
6500 [[''Pentecoste''|''Pentecoste'']]
6502 <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>
6503 </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>
6504 </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>
6505 </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>
6508 <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>
6509 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">''Pentecoste''</a></p>
6510 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">Pentecoste</a></p>
6511 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''"><i>Pentecoste</i></a></p>
6515 Broken image links with HTML captions (bug 39700)
6517 [[File:Nonexistent|<script></script>]]
6518 [[File:Nonexistent|100x100px|<script></script>]]
6519 [[File:Nonexistent|<]]
6520 [[File:Nonexistent|a<i>b</i>c]]
6522 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
6523 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
6524 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
6525 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
6528 <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>
6529 <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>
6530 <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>
6531 <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>
6537 [[http://www.example.com]]
6539 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
6542 <p>[<a rel="mw:ExtLink" href="http://www.example.com"></a>]</p>
6546 Plain link to URL with link text
6548 [[http://www.example.com Link text]]
6550 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
6555 Plain link to protocol-relative URL
6557 [[//www.example.com]]
6559 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
6562 <p>[<a rel="mw:ExtLink" href="//www.example.com"></a>]</p>
6566 Plain link to protocol-relative URL with link text
6568 [[//www.example.com Link text]]
6570 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
6575 Plain link to page with question mark in title
6581 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
6582 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
6587 # I'm fairly sure the expected result here is wrong.
6588 # We want these to be URL links, not pseudo-pages with URLs for titles....
6589 # However the current output is also pretty screwy.
6592 # I'm changing it to match the current output--it arguably makes more
6593 # sense in the light of the test above. Old expected result was:
6594 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
6596 # But I think this test is bordering on "garbage in, garbage out" anyway.
6601 Piped link to URL: [[http://www.example.com|an example URL]]
6603 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
6606 <p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com|an">example URL</a>]</p>
6610 BUG 2: [[page|http://url/]] should link to page, not http://url/
6612 [[Main Page|http://url/]]
6614 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
6617 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">http://url/</a></p>
6620 # Parsoid does not mark self-links, by design.
6622 BUG 337: Escaped self-links should be bold
6626 [[Bug462]] [[Bug462]]
6628 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
6631 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong></p>
6633 <p><a rel="mw:WikiLink" href="./Bug462" title="Bug462">Bug462</a> <a rel="mw:WikiLink" href="./Bug462" title="Bug462">Bug462</a></p>
6637 Self-link to section should not be bold
6641 [[Main Page#section]]
6643 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
6654 Self-link to numeric title
6660 <p><strong class="selflink">0</strong>
6665 Link to numeric-equivalent title
6671 <p><a href="/wiki/00" title="00">00</a>
6676 <nowiki> inside a link
6678 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
6680 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
6685 Non-breaking spaces in title
6687 [[ Main Page ]]
6689 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
6694 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
6700 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
6705 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
6711 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
6716 Internal link with en linktrail: no apostrophes (bug 27473)
6722 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
6727 Internal link with ca linktrail with apostrophes (bug 27473)
6733 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
6738 Internal link with kaa linktrail with apostrophes (bug 27473)
6744 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
6749 Link with multiple ":" in a subpage-supporting namespace (bug 63636)
6751 [[User:Foo/Test/63636:Bar|Test]]
6753 <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>
6756 <p><a rel="mw:WikiLink" href="./User:Foo/Test/63636:Bar" title="User:Foo/Test/63636:Bar">Test</a></p>
6760 Purely hash wikilink
6762 title=[[User:test/123]]
6766 <p><a href="#a">b</a>
6769 <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>
6773 1. Interaction of linktrail and template encapsulation
6779 <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>
6783 2. Interaction of linktrail and template encapsulation
6787 {{echo|Some [[Fool]]}}s
6789 <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>
6793 3. Interaction of linktrail and template encapsulation
6797 {{echo|Some [[Fool]]s are '''bold and foolish'''}}
6799 <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>
6809 Internal link with is link prefix
6813 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
6815 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
6826 Internal link with is link trail and link prefix
6830 [[mótmælendatrú|xxx]]ar
6832 mótmælenda[[söfnuður]]
6833 mótmælenda[[söfnuður|söfnuðir]]
6834 mótmælenda[[söfnuður|söfnuðir]]xxx
6836 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
6837 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
6838 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
6839 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
6840 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
6845 Parsoid link trail escaping
6847 parsoid=html2wt,html2html
6851 <p><a rel="mw:WikiLink" href="Apple" title="Apple">apple</a>s</p>
6855 Parsoid link prefix escaping
6858 parsoid=html2wt,html2html
6860 Aðrir mótmælenda<nowiki/>[[söfnuður]]
6862 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður" title="Söfnuður">söfnuður</a></p>
6866 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
6874 [http://wp.org ''foo'']
6876 <p><a href="/wiki/Foo" title="Foo"> bar</a>
6877 </p><p><a href="/wiki/Foo" title="Foo"> <i>bar</i></a>
6878 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
6879 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
6884 Parsoid: Scoped parsing should handle mixed transclusions and plain text
6888 [[Foo|{{echo|a}} b {{echo|c}}]]
6890 <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>
6894 Link with angle bracket after anchor
6898 <p><a href="/wiki/Foo#.3Cbar.3E" title="Foo">Foo#<bar></a>
6901 <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>
6905 ### Interwiki links (see maintenance/interwiki.sql)
6909 Inline interwiki link
6911 parsoid=wt2html,wt2wt,html2html
6913 [[MeatBall:SoftSecurity]]
6915 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
6918 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a></p>
6922 Inline interwiki link with empty title (bug 2372)
6924 parsoid=wt2html,wt2wt,html2html
6928 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
6931 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?" title="meatball:">MeatBall:</a></p>
6935 Interwiki link encoding conversion (bug 1636)
6937 *[[Wikipedia:ro:Olteniţa]]
6938 *[[Wikipedia:ro:Olteniţa]]
6940 <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>
6941 <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>
6945 <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>
6946 <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>
6951 Interwiki link with fragment (bug 2130)
6953 [[MeatBall:SoftSecurity#foo]]
6955 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
6959 # Ideally the wikipedia: prefix here should be proto-relative too
6960 # [CSA]: this is kind of a bogus test, as the PHP parser test doesn't
6961 # define the 'en' prefix, and originally the test used 'wikipedia',
6962 # which isn't a localinterwiki prefix hence the links to the 'en:Foo'
6965 Different interwiki prefixes mapping to the same URL
6973 [[:wikipedia:Foo|Foo]]
6975 [[wikipedia:en:Foo]]
6977 [[:wikipedia:en:Foo]]
6981 <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>
6983 <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>
6985 <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 <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>
6989 <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>
6991 <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>
6993 <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>
6997 Interwiki links that cannot be represented in wiki syntax
7000 [[meatball:ok#foo|ok with fragment]]
7001 [[meatball:ok_as_well?|ok ending with ? mark]]
7002 [http://de.wikipedia.org/wiki/Foo?action=history has query]
7003 [http://de.wikipedia.org/wiki/#foo is just fragment]
7006 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?ok" class="extiw" title="meatball:ok">meatball:ok</a>
7007 <a href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo" class="extiw" title="meatball:ok">ok with fragment</a>
7008 <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>
7009 <a rel="nofollow" class="external text" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
7010 <a rel="nofollow" class="external text" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a>
7013 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok" title="meatball:ok">meatball:ok</a>
7014 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo" title="meatball:ok">ok with fragment</a>
7015 <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>
7016 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
7017 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a></p>
7021 Interwiki links: trail
7023 [[wikipedia:Foo|Ba]]r
7025 <p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo">Bar</a>
7028 <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>
7032 Local interwiki link
7034 parsoid=wt2html,wt2wt,html2html
7036 [[local:Template:Foo]]
7038 <p><a href="/wiki/Template:Foo" title="Template:Foo">local:Template:Foo</a>
7041 <p><a rel="mw:WikiLink" href="./Template:Foo" title="Template:Foo">local:Template:Foo</a></p>
7044 # Parsoid does not mark self-links, by design.
7046 Local interwiki link: self-link to current page
7049 parsoid=wt2html,wt2wt,html2html
7053 <p><strong class="selflink">local:Main Page</strong>
7056 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">local:Main Page</a></p>
7060 Local interwiki link: prefix only (bug 64167)
7062 parsoid=wt2html,wt2wt,html2html
7066 <p><a href="/wiki/Main_Page" title="Main Page">local:</a>
7069 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">local:</a></p>
7073 Local interwiki link: with additional interwiki prefix (bug 61357)
7075 parsoid=wt2html,wt2wt,html2html
7077 [[local:meatball:Hello]]
7079 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?Hello" class="extiw" title="meatball:Hello">local:meatball:Hello</a>
7082 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?Hello" title="meatball:Hello">local:meatball:Hello</a></p>
7086 Multiple local interwiki link prefixes
7088 [[local:local:local:local:mi:local:Foo]]
7090 parsoid=wt2html,wt2wt,html2html
7092 <p><a href="/wiki/Foo" title="Foo">local:local:local:local:mi:local:Foo</a>
7095 <p><a rel="mw:WikiLink" href="./Foo" title="Foo">local:local:local:local:mi:local:Foo</a></p>
7099 ### Interlanguage links
7100 ### Language links (so that searching for '### language' matches..)
7106 parsoid=wt2html,wt2wt,html2html
7114 <p>Blah blah blah</p>
7115 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7119 Interlanguage link with spacing
7121 parsoid=wt2html,wt2wt,html2html
7129 <p>Blah blah blah</p>
7130 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7134 Double interlanguage link
7136 parsoid=wt2html,wt2wt,html2html
7145 <p>Blah blah blah</p>
7146 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish"/>
7147 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7151 Interlanguage link variations
7153 parsoid=wt2html,wt2wt,html2html
7164 <p>Blah blah blah</p>
7165 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish" />
7166 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese" />
7167 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Foo_bar" />
7168 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Foo_bar" />
7172 Interlanguage link, with prefix links
7182 <p>Blah blah blah</p>
7183 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7187 Double interlanguage link, with prefix links (bug 8897)
7198 <p>Blah blah blah</p>
7199 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish"/>
7200 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
7204 "Extra" interlanguage links (bug 32189 / gerrit 111390)
7212 <p>Blah blah blah</p>
7213 <link rel="mw:PageProp/Language" title="Multilingual" href="http://wikisource.org/wiki/Article"/>
7217 Parsoid-specific test: Wikilinks with should RT properly
7223 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
7228 Parsoid bug 53221: Wikilinks should be properly entity-escaped
7232 He&nbsp;llo [[Foo|He&nbsp;llo]]
7234 He&nbsp;llo [[He&nbsp;llo]]
7236 <p>He&nbsp;llo <a href="Foo" rel="mw:WikiLink">He&nbsp;llo</a></p>
7237 <p>He&nbsp;llo <a href="He&nbsp;llo" rel="mw:WikiLink">He&nbsp;llo</a></p>
7241 Parsoid: handle constructor well
7247 <p><a href="/index.php?title=Constructor&action=edit&redlink=1" class="new" title="Constructor (page does not exist)">constructor</a>
7248 </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>
7251 <p><a rel="mw:WikiLink" href="./Constructor" title="Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"}}">constructor</a></p>
7253 <p><a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"}}">constructor:foo</a></p>
7262 # Note that `ko` isn't a known interlanguage prefix
7264 Parsoid: recognize interlanguage links without a target page
7274 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/"/>
7276 <p><a rel="mw:WikiLink" href="./Ko:" title="Ko:">ko:</a></p>
7279 # Note that `ko` isn't a known interwiki prefix
7281 Parsoid: recognize interwiki links without a target page
7283 parsoid=wt2html,wt2wt,html2html
7289 <p><a href="http://es.wikipedia.org/wiki/" class="extiw" title="es:">es:</a>
7290 </p><p><a href="/wiki/Ko:" title="Ko:">ko:</a>
7293 <p><a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/" title="es:">es:</a></p>
7294 <p><a rel="mw:WikiLink" href="./Ko:" title="Ko:">ko:</a></p>
7298 Handle interwiki links pointing to the current wiki as plain wiki links (bug 45209)
7302 <p><a href="/wiki/Foo" title="Foo">mi:Foo</a>
7305 <p><a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"mi:Foo"}}'>mi:Foo</a></p>
7309 Interlanguage link with preceding local interwiki link (bug 68085)
7311 parsoid=wt2html,wt2wt,html2html
7314 [[local:es:Spanish]]
7317 <a href="http://es.wikipedia.org/wiki/Spanish" class="extiw" title="es:Spanish">local:es:Spanish</a>
7321 <a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/Spanish" title="es:Spanish">local:es:Spanish</a></p>
7325 Looks like an interlanguage link, but is actually a local interwiki
7327 parsoid=wt2html,wt2wt,html2html
7333 <a href="/wiki/Template:Foo" title="Template:Foo">mi:Template:Foo</a>
7337 <a rel="mw:WikiLink" href="Template:Foo" title="Template:Foo">mi:Template:Foo</a></p>
7341 ### Redirects, Parsoid-only
7344 1. Simple redirect to page
7348 #REDIRECT [[Main Page]]
7350 <link rel="mw:PageProp/redirect" href="./Main_Page">
7353 # Only wt2html and html2html since "Main_Page" will serialize to "Main Page"
7355 2. Other redirect variants
7357 parsoid=wt2html,wt2wt
7359 #REDIRECT [[Main_Page]]
7360 #REDIRECT [[<nowiki>[[Bar]]</nowiki>]]
7362 <link rel="mw:PageProp/redirect" href="./Main_Page"><link rel="mw:PageProp/redirect" href="./%5B%5BBar%5D%5D">
7368 parsoid=wt2html,wt2wt
7373 <li>REDIRECT [[]]</li></ol>
7377 Optional colon in #REDIRECT
7379 # the colon is archaic syntax. we support it for wt2html, but we
7380 # don't care that it roundtrips back to the modern syntax.
7381 parsoid=wt2html,html2html
7383 #REDIRECT:[[Main Page]]
7385 <link rel="mw:PageProp/redirect" href="./Main_Page">
7389 Whitespace in #REDIRECT with optional colon
7391 # the colon and gratuitous whitespace is archaic syntax. we support
7392 # it for wt2html, but we don't care that it roundtrips back to the
7393 # modern syntax (without extra whitespace)
7394 parsoid=wt2html,html2html
7401 <link rel="mw:PageProp/redirect" href="./Main_Page">
7405 Piped link in #REDIRECT
7407 # content after piped link is ignored. we support this syntax,
7408 # but don't care that the piped link is lost when we roundtrip this.
7411 #REDIRECT [[Main Page|bar]]
7413 <link rel="mw:PageProp/redirect" href="./Main_Page">
7417 Redirect to category
7421 #REDIRECT [[Category:Foo]]
7423 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
7427 Redirect to category with URL encoding
7431 #REDIRECT [[Category%3AFoo]]
7433 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
7437 Redirect to category page
7439 parsoid=wt2html,html2html
7441 #REDIRECT [[:Category:Foo]]
7443 <p><a rel="mw:WikiLink" href="Category:Foo" title="Category:Foo">Category:Foo</a></p>
7447 Redirect to image page (1)
7451 #REDIRECT [[File:Wiki.png]]
7453 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
7457 Redirect to image page (2)
7461 #REDIRECT [[Image:Wiki.png]]
7463 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
7467 Redirect to language
7471 #REDIRECT [[en:File:Wiki.png]]
7473 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
7477 Redirect to interwiki
7481 #REDIRECT [[meatball:File:Wiki.png]]
7483 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
7487 Non-English #REDIRECT
7492 #TILVÍSUN [[Main Page]]
7494 <link rel="mw:PageProp/redirect" href="./Main_Page">
7505 <p>Foo<link rel="mw:PageProp/redirect" href="./Foo"></p>
7522 Broken br tag sanitization
7530 # TODO: Fix html2html mode (bug 51055)!
7531 # This </br> handling was added as part of bug 50831; but it
7532 # differs from how PHP+tidy handles this. We should investigate
7535 Parsoid: Broken br tag recognition
7551 Incorrecly removing closing slashes from correctly formed XHTML
7553 <br style="clear:both;" />
7555 <p><br style="clear:both;" />
7560 Failing to transform badly formed HTML into correct XHTML
7562 <br style="clear: left;">
7563 <br style="clear: right;">
7564 <br style="clear: both;">
7566 <p><br style="clear: left;" />
7567 <br style="clear: right;" />
7568 <br style="clear: both;" />
7572 ## FIXME: Is Parsoid's acceptance of self-closing html-tags
7573 ## a feature or a bug? See https://phabricator.wikimedia.org/T76962
7575 Handling html with a div self-closing tag
7584 <p><div title />
7588 <p><div title=bar />
7589 <div title=bar/>
7591 <div title="bar/"></div>
7595 <div title="" data-parsoid='{"stx":"html","selfClose":true}'></div>
7596 <div title="" data-parsoid='{"stx":"html","selfClose":true}'></div>
7597 <div title="" data-parsoid='{"stx":"html","selfClose":true,"brokenHTMLTag":true}'></div>
7598 <div title="bar" data-parsoid='{"stx":"html","selfClose":true}'></div>
7599 <div title="bar" data-parsoid='{"stx":"html","selfClose":true}'></div>
7600 <div title="bar/" data-parsoid='{"stx":"html","autoInsertedEnd":true}'></div>
7604 Handling html with a br self-closing tag
7613 <p><br title="title" />
7614 <br title="title" />
7631 Horizontal ruler (should it add that extra space?)
7646 Horizontal ruler -- 4+ dashes render hr
7655 Horizontal ruler -- eats additional dashes on the same line
7664 Horizontal ruler -- does not collapse dashes on consecutive lines
7675 Horizontal ruler -- <4 dashes render as plain text
7684 Horizontal ruler -- Supports content following dashes on same line
7696 ### Block-level elements
7705 <ul><li>Common list</li>
7707 <li>item 3</li></ul>
7718 <ol><li>Numbered list</li>
7720 <li> item 3</li></ol>
7734 ***#Number on level 4
7736 **#Number on level 3
7737 **#Number on level 3
7741 #** Level 3, but ordered
7744 <ol><li> with numbers</li></ol>
7745 <ul><li> and bullets</li></ul>
7746 <ol><li> and numbers</li></ol></li>
7748 <ul><li>bullet level 2
7749 <ul><li>bullet level 3
7750 <ol><li>Number on level 4</li></ol></li></ul></li>
7752 <ol><li>Number on level 3</li>
7753 <li>Number on level 3</li></ol></li></ul>
7754 <ol><li>number level 2</li></ol></li>
7756 <ul><li><ul><li> Level 3</li></ul></li></ul></li></ul>
7757 <ol><li><ul><li><ul><li> Level 3, but ordered</li></ul></li></ul></li></ol>
7768 <ul><li>bar</li></ul></li></ul>
7778 <ul><li><ul><li>foo</li></ul></li>
7784 Nested lists 3 (first element empty)
7790 <ul><li>bar</li></ul></li></ul>
7795 Nested lists 4 (first element empty)
7800 <ul><li><ul><li></li></ul></li>
7806 Nested lists 5 (both elements empty)
7811 <ul><li><ul><li></li></ul></li>
7817 Nested lists 6 (both elements empty)
7823 <ul><li></li></ul></li></ul>
7828 Nested lists 7 (skip initial nesting levels)
7832 <ul><li><ul><li><ul><li> foo</li></ul></li></ul></li></ul>
7837 Nested lists 8 (multiple nesting transitions)
7845 <ul><li><ul><li> bar</li></ul></li>
7846 <li> baz</li></ul></li>
7852 1. Lists with start-of-line-transparent tokens before bullets: Comments
7865 2. Lists with start-of-line-transparent tokens before bullets: Template close
7870 <ul><li>foo bar</li>
7876 List items are not parsed correctly following a <pre> block (bug 785)
7882 <ul><li> <pre>foo</pre></li>
7883 <li> <pre>bar</pre></li>
7889 List items from template
7900 * notSOL{{inner list}}
7903 <ul><li> item 1</li>
7904 <li> item 2</li></ul>
7905 <ul><li> item 0</li>
7907 <li> item 2</li></ul>
7908 <ul><li> item 0</li>
7911 <li> item 2</li></ul>
7916 List interrupted by empty line or heading
7924 <ul><li> foo</li></ul>
7925 <ul><li><ul><li> bar</li></ul></li></ul>
7926 <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>
7927 <ul><li> Another list item</li></ul>
7932 Multiple list tags generated by templates
7953 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
7956 <!--This line will NOT split the list-->
7958 <!--This line will NOT split the list either-->
7960 <!--foo--> <!----> <!--This line NOT split the list either-->
7971 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
7974 <!--This line will NOT split the list-->
7976 <!--This line will NOT split the list either-->
7978 <!--foo--> <!----> <!--This line NOT split the list
7991 (The PHP parser relies on Tidy for the hack)
7993 parsoid=wt2html,wt2wt
7997 * {{echo|<li>templated li-hack}}
7998 * <!--foo--> <li> unsupported li-hack with preceding comments
8001 <li><li>not a li-hack
8008 <li>templated li-hack</li>
8009 <li>unsupported li-hack with preceding comments</li>
8012 <li>not a li-hack</li>
8017 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
8044 Parsoid: Test of whitespace serialization with Templated bullets
8051 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}}]}'> Bar</li>
8055 # ------------------------------------------------------------------------
8056 # The next set of tests are about Parsoid's ability to handle badly nested
8057 # tags (parse, minimize scope of fixup, and roundtrip back)
8058 # ------------------------------------------------------------------------
8061 Unbalanced closing block tags break a list
8062 (php parser relies on Tidy to fix up)
8080 # Parsoid fails this test, but it might be tricky to support properly.
8083 Unbalanced closing non-block tags don't break a list
8084 (php parser relies on Tidy to fix up)
8091 <li><span>a</span></li>
8092 <li><span>b</span></li>
8106 Unclosed formatting tags that straddle lists are closed and reopened
8107 (php parser relies on Tidy to fix up)
8109 parsoid=wt2html,wt2wt,html2html
8119 <ol><li> <s> a</s></li>
8120 <li><s> b </s></li></ol>
8123 # Parsoid fails this test, but it might be tricky to support properly.
8126 List embedded in a non-block tag
8127 (Ugly Parsoid output -- worth fixing; PHP parser relies on Tidy)
8134 <li><small>foo</small></li>
8144 # This is a bug in the PHP parser + tidy combination.
8145 # (The </tr> tag gets parsed as text and html-escaped by PHP,
8146 # and then fostered out of the table by tidy.)
8147 # We believe the Parsoid output to be correct.
8149 Table with missing opening <tr> tag
8151 parsoid=wt2html,wt2wt
8176 # Note that the current date is hard-coded as
8177 # 1970-01-01T00:02:03Z (a Thursday)
8178 # when running parser tests. The timezone is also fixed to GMT, so
8179 # local date will be identical to current date.
8182 Magic Word: {{CURRENTDAY}}
8191 Magic Word: {{CURRENTDAY2}}
8200 Magic Word: {{CURRENTDAYNAME}}
8209 Magic Word: {{CURRENTDOW}}
8218 Magic Word: {{CURRENTMONTH}}
8227 Magic Word: {{CURRENTMONTH1}}
8236 Magic Word: {{CURRENTMONTHABBREV}}
8238 {{CURRENTMONTHABBREV}}
8245 Magic Word: {{CURRENTMONTHNAME}}
8247 {{CURRENTMONTHNAME}}
8254 Magic Word: {{CURRENTMONTHNAMEGEN}}
8256 {{CURRENTMONTHNAMEGEN}}
8263 Magic Word: {{CURRENTTIME}}
8272 Magic Word: {{CURRENTHOUR}}
8281 Magic Word: {{CURRENTWEEK}} (@bug 4594)
8290 Magic Word: {{CURRENTYEAR}}
8299 Magic Word: {{CURRENTTIMESTAMP}}
8301 {{CURRENTTIMESTAMP}}
8308 Magic Words LOCAL (UTC)
8312 * {{LOCALMONTHNAME}}
8313 * {{LOCALMONTHNAMEGEN}}
8314 * {{LOCALMONTHABBREV}}
8323 * {{LOCALTIMESTAMP}}
8338 <li> 19700101000203</li></ul>
8343 Magic Word: {{FULLPAGENAME}}
8345 title=[[User:Ævar Arnfjörð Bjarmason]]
8349 <p>User:Ævar Arnfjörð Bjarmason
8354 Magic Word: {{FULLPAGENAMEE}}
8356 title=[[User:Ævar Arnfjörð Bjarmason]]
8360 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8365 Magic Word: {{TALKSPACE}}
8367 title=[[User:Ævar Arnfjörð Bjarmason]]
8376 Magic Word: {{TALKSPACE}}, same namespace
8378 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8387 Magic Word: {{TALKSPACE}}, main namespace
8389 title=[[Parser Test]]
8398 Magic Word: {{TALKSPACEE}}
8400 title=[[User:Ævar Arnfjörð Bjarmason]]
8409 Magic Word: {{SUBJECTSPACE}}
8411 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8420 Magic Word: {{SUBJECTSPACE}}, same namespace
8422 title=[[User:Ævar Arnfjörð Bjarmason]]
8431 Magic Word: {{SUBJECTSPACE}}, main namespace
8433 title=[[Parser Test]]
8441 Magic Word: {{SUBJECTSPACEE}}
8443 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8452 Magic Word: {{NAMESPACE}}
8454 title=[[User:Ævar Arnfjörð Bjarmason]]
8463 Magic Word: {{NAMESPACEE}}
8465 title=[[User:Ævar Arnfjörð Bjarmason]]
8474 Magic Word: {{NAMESPACENUMBER}}
8476 title=[[User:Ævar Arnfjörð Bjarmason]]
8485 Magic Word: {{SUBPAGENAME}}
8487 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
8496 Magic Word: {{SUBPAGENAMEE}}
8498 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
8507 Magic Word: {{ROOTPAGENAME}}
8509 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
8513 <p>Ævar Arnfjörð Bjarmason
8518 Magic Word: {{ROOTPAGENAMEE}}
8520 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
8524 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8529 Magic Word: {{BASEPAGENAME}}
8531 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
8535 <p>Ævar Arnfjörð Bjarmason
8540 Magic Word: {{BASEPAGENAMEE}}
8542 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
8546 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8551 Magic Word: {{TALKPAGENAME}}
8553 title=[[User:Ævar Arnfjörð Bjarmason]]
8557 <p>User talk:Ævar Arnfjörð Bjarmason
8562 Magic Word: {{TALKPAGENAMEE}}
8564 title=[[User:Ævar Arnfjörð Bjarmason]]
8568 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8573 Magic Word: {{SUBJECTPAGENAME}}
8575 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8579 <p>User:Ævar Arnfjörð Bjarmason
8584 Magic Word: {{SUBJECTPAGENAMEE}}
8586 title=[[User talk:Ævar Arnfjörð Bjarmason]]
8588 {{SUBJECTPAGENAMEE}}
8590 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8595 Magic Word: {{NUMBEROFFILES}}
8604 Magic Word: {{PAGENAME}}
8606 title=[[User:Ævar Arnfjörð Bjarmason]]
8610 <p>Ævar Arnfjörð Bjarmason
8615 Magic Word: {{PAGENAME}} with metacharacters
8617 title=[['foo & bar = baz']]
8621 <p><i>'foo & bar = baz'</i>
8624 <p><i>'foo & bar = baz'</i></p>
8628 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
8630 title=[[*RFC 1234 http://example.com/]]
8634 <p>*RFC 1234 http://example.com/
8637 <p>*RFC 1234 http://example.com/</p>
8641 Magic Word: {{PAGENAMEE}}
8643 title=[[User:Ævar Arnfjörð Bjarmason]]
8647 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
8652 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
8654 title=[[*RFC 1234 http://example.com/]]
8658 <p>*RFC_1234_http://example.com/
8661 <p>*RFC_1234_http://example.com/</p>
8665 Magic Word: {{REVISIONID}}
8674 Magic Word: {{SCRIPTPATH}}
8683 Magic Word: {{STYLEPATH}}
8692 Magic Word: {{SERVER}}
8696 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
8701 Magic Word: {{SERVERNAME}}
8710 Magic Word: {{SITENAME}}
8719 Case-sensitive magic words, when cased differently, should just be template transclusions
8726 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
8727 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
8728 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
8729 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
8734 Case-insensitive magic words should still work with weird casing.
8744 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
8749 Namespace 1 {{ns:1}}
8758 Namespace 1 {{ns:01}}
8767 Namespace 0 {{ns:0}} (bug 4783)
8775 Namespace 0 {{ns:00}} (bug 4783)
8783 Namespace -1 {{ns:-1}}
8792 Namespace User {{ns:User}}
8801 Namespace User talk {{ns:User_talk}}
8810 Namespace User talk {{ns:uSeR tAlK}}
8819 Namespace File {{ns:File}}
8828 Namespace File {{ns:Image}}
8837 Namespace (lang=de) Benutzer {{ns:User}}
8848 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
8854 <p>Benutzer Diskussion
8862 {{urlencode:hi world?!}}
8863 {{urlencode:hi world?!|WIKI}}
8864 {{urlencode:hi world?!|PATH}}
8865 {{urlencode:hi world?!|QUERY}}
8875 Magic Word: prioritize type info over data-parsoid
8881 <meta property="mw:PageProp/forcetoc" data-parsoid='{"src":"__NOTOC__","magicSrc":"__NOTOC__"}'/>
8885 Magic Word: serialize on separate line (parsoid)
8887 parsoid=wt2wt,html2wt
8893 foo<meta property="mw:PageProp/notoc"/>bar
8897 Magic Word: rt non-english wikis
8904 <meta property="mw:PageProp/noeditsection" data-parsoid='{"src":"__NOEDITSECTION__","magicSrc":"__NOEDITSECTION__"}'/>
8911 Magic links: internal link to RFC (bug 479)
8915 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
8920 Magic links: RFC (bug 479)
8924 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
8929 Magic links: RFC (bug 65278)
8931 This is RFC 822 but thisRFC 822 is not RFC 822linked.
8933 <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.
8938 Magic links: ISBN (bug 1937)
8942 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
8947 Magic links: ISBN (bug 65278)
8949 This is ISBN 978-0-316-09811-3 but thisISBN 978-0-316-09811-3 is not ISBN 978-0-316-09811-3linked.
8951 <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.
8956 Magic links: PMID incorrectly converts space to underscore
8960 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
8965 Magic links: PMID (bug 65278)
8967 This is PMID 1234 but thisPMID 1234 is not PMID 1234linked.
8969 <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.
8978 Nonexistent template
8980 {{thistemplatedoesnotexist}}
8982 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
8987 Template with invalid target containing tags
8989 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
8991 <p>{{a<b>b</b>|foo|a=b|a = b}}
8996 Template with invalid target containing unclosed tag
8998 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
9000 <p>{{a<b>|foo|a=b|a = b}}</b>
9005 Template with invalid target containing wikilink
9009 <p>{{<a href="/wiki/Main_Page" title="Main Page">Main Page</a>}}
9012 <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>
9016 Template with just whitespace in it, bug #68421
9020 <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>
9026 This is a test template
9034 <p>This is a test template
9039 Template with explicit namespace
9043 <p>This is a test template
9051 This is a test template with parameter {{{param}}}
9057 {{paramtest|param=foo}}
9059 <p>This is a test template with parameter foo
9064 Template:paramtestnum
9070 Template unnamed parameter
9072 {{paramtestnum|Main Page|the main page}}
9074 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
9079 Template:templatesimple
9085 Template:templateredirect
9087 #redirect [[Template:templatesimple]]
9091 Template:templateasargtestnum
9097 Template:templateasargtest
9099 {{template{{{templ}}}}}
9103 Template:templateasargtest2
9109 Template with template name as unnamed argument
9111 {{templateasargtestnum|templatesimple}}
9118 Template with template name as argument
9120 {{templateasargtest|templ=simple}}
9127 Template with template name as argument (2)
9129 {{templateasargtest2|templ=templatesimple}}
9136 Template:templateasargtestdefault
9138 {{{{{templ|templatesimple}}}}}
9148 Template with default value
9150 {{templateasargtestdefault}}
9157 Template with default value (value set)
9159 {{templateasargtestdefault|templ=templa}}
9168 {{templateredirect}}
9175 Template with argument in separate line
9177 {{ templateasargtest |
9185 Template with complex template as argument
9188 param ={{ templateasargtest |
9191 <p>This is a test template with parameter (test)
9196 Template with thumb image (with link in description)
9198 {{paramtest|param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
9200 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>
9203 <p>This is a test template with parameter</p>
9204 <div class="thumb tright">
9205 <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>
9206 <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>
9210 <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>
9214 Template:complextemplate
9216 {{{1}}} {{paramtest|
9217 param ={{{param}}}}}
9221 Template with complex arguments
9224 param ={{ templateasargtest |
9225 templ = simple }}|[[Template:complextemplate|link]]}}
9227 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
9232 BUG 553: link with two variables in a piped link
9235 |[[{{{1}}}|{{{2}}}]]
9240 <td>[[{{{1}}}|{{{2}}}]]
9246 Magic variable as template parameter
9248 {{paramtest|param={{SITENAME}}}}
9250 <p>This is a test template with parameter MediaWiki
9257 [[{{{param}}}|link]]
9261 Template parameter as link source
9263 {{linktest|param=Main Page}}
9265 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
9270 Template-generated attribute string (k='v')
9272 <span {{attr_str|id|v1}}>bar</span>
9274 <p><span id="v1">bar</span>
9281 including another template, {{paramtest|param={{{arg}}}}}
9285 Template passing argument to another template
9287 {{paramtest2|arg='hmm'}}
9289 <p>including another template, This is a test template with parameter 'hmm'
9300 Template as link source
9304 [[{{linktest2}}|Main Page]]
9306 [[{{linktest2}}]]Page
9308 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
9309 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
9310 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
9328 Template infinite loop
9332 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
9337 Template from main namespace
9356 BUG 529: Template with table, not included at beginning of line
9375 BUG 523: Template shouldn't eat newline (or add an extra one before table)
9395 BUG 41: Template parameters shown as broken links
9404 Template with targets containing wikilinks
9408 {{[[{{echo|foo}}]]}}
9410 {{{{echo|[[foo}}]]}}
9412 <p>{{<a href="/wiki/Foo" title="Foo">foo</a>}}
9413 </p><p>{{<a href="/wiki/Foo" title="Foo">foo</a>}}
9421 ''None'' of '''this''' should be
9423 but rather passed unmodified
9430 # hmm, fix this or just deprecate msgnw and document its behavior?
9434 {{msgnw:MSGNW test}}
9436 <p>''None'' of '''this''' should be
9438  but rather passed unmodified
9439 {{test}}
9449 {{int:youhavenewmessages|lots of money|not!}}
9451 <p>You have lots of money (not!).
9458 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
9462 <includeonly> and <noinclude> being included
9473 <onlyinclude>Foo</onlyinclude>bar
9477 <onlyinclude> being included
9489 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
9493 <onlyinclude> and <includeonly> being included
9502 <includeonly> and <noinclude> on a page
9504 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
9511 Un-closed <noinclude>
9518 <onlyinclude> on a page
9520 <onlyinclude>Foo</onlyinclude>bar
9527 Un-closed <onlyinclude>
9534 Self-closed noinclude, includeonly, onlyinclude tags
9545 Unbalanced includeonly and noinclude tags
9549 |b</noinclude></noinclude>
9550 |c</noinclude></includeonly>
9551 |d</includeonly></includeonly>
9560 <td>c</includeonly>
9562 <td>d</includeonly></includeonly>
9568 Template:Includeonly section
9571 ==Includeonly section==
9577 Bug 6563: Edit link generation for section shown by <includeonly>
9579 {{includeonly section}}
9581 <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>
9582 <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>
9586 # Uses same input as the contents of [[Template:Includeonly section]]
9588 Bug 6563: Section extraction for section shown by <includeonly>
9593 ==Includeonly section==
9601 Bug 6563: Edit link generation for section suppressed by <includeonly>
9604 ==Includeonly section==
9608 <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>
9613 Bug 6563: Section extraction for section suppressed by <includeonly>
9618 ==Includeonly section==
9626 Un-closed <includeonly>
9633 Includes and comments at SOL
9635 <!-- comment --><noinclude><!-- comment --></noinclude><!-- comment -->== hu ==
9642 <includeonly>can have stuff</includeonly>=== here ===
9645 <h2><span class="mw-headline" id="hu">hu</span></h2>
9650 <h3><span class="mw-headline" id="here">here</span></h3>
9653 <!-- 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>
9655 <meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/>
9657 <meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/><ul><li> stuff</li>
9660 <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>
9664 # TODO: test with DOM fragment reuse!
9666 Parsoid: DOM fragment reuse
9668 parsoid=wt2wt,wt2html
9670 a{{echo|b<table></table>c}}d
9682 <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>
9684 <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">
9685 </span><table about="#mwt2" data-parsoid='{"stx":"html"}'></table><span about="#mwt2">
9686 </span><p about="#mwt2">cd</p>
9688 <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">
9690 </span><table about="#mwt3" data-parsoid='{"stx":"html"}'></table><span about="#mwt3">
9692 </span><p about="#mwt3">b</p>
9696 Parsoid: Merge double tds (bug 50603)
9705 <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>
9710 Parsoid: Merge double tds in nested transclusion content (bug 50603)
9720 <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}}]}'>
9722 <tr><td data-mw='{"parts":["|"]}'> foo</td></tr>
9728 ### <includeonly> and <noinclude> in attributes
9731 0. includeonly around the entire attribute
9733 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
9735 <p><span id="v2">bar</span>
9740 1. includeonly in html attr key
9742 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
9744 <p><span id="foo">bar</span>
9749 2. includeonly in html attr value
9751 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
9752 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
9754 <p><span id="v1">bar</span>
9755 <span id="v1">bar</span>
9760 3. includeonly in part of an attr value
9762 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
9764 <p><span style="color:red;">bar</span>
9769 4. includeonly in table attributes
9793 ### Token Stream Patcher tests
9795 ### These tests won't always pass wt2wt and other modes because
9796 ### on serialization, the table will be output on a new line.
9797 ### For now, we are blacklisting them, and using this to test selser.
9801 1. Table tag in SOL posn. should get reparsed correctly with valid TSR
9803 parsoid=wt2html,wt2wt
9805 {{echo|}}{| width = '100%'
9809 <span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":""}},"i":0}}]}'></span><table width="100%">
9810 <tbody><tr><td>foo</td></tr>
9815 2. Table tag in SOL posn. should get reparsed correctly with valid TSR
9817 parsoid=wt2html,wt2wt
9819 <includeonly>a</includeonly>{| {{{b}}}
9823 <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}}}":""}}'>
9824 <tbody><tr><td>c</td></tr>
9830 ### Testing parsing of templates where a template arg
9831 ### has the same name as the template itself.
9841 Templates: Template Name/Arg clash: 1. Use of positional param
9850 Templates: Template Name/Arg clash: 2. Use of named param
9859 Templates: Template Name/Arg clash: 3. Use of named param with empty input
9868 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
9872 Templates: 1. Simple use
9881 Templates: 2. Inside a block tag
9883 <div>{{echo|Foo}}</div>
9884 <blockquote>{{echo|Foo}}</blockquote>
9887 <blockquote>Foo</blockquote>
9897 Templates: P-wrapping: 1a. Templates on consecutive lines
9908 Templates: P-wrapping: 1b. Templates on consecutive lines
9922 Templates: P-wrapping: 1c. Templates on consecutive lines
9925 {{echo|bar}} <div>baz</div>
9938 Templates: P-wrapping: 1d. Template preceded by comment-only line
9947 <p about="#mwt223" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Bar"}},"i":0}}]}'>Bar</p>
9951 Templates: Inline Text: 1. Multiple template uses
9953 {{echo|Foo}}bar{{echo|baz}}
9960 Templates: Inline Text: 2. Back-to-back template uses
9962 {{echo|Foo}}{{echo|bar}}
9969 Templates: Block Tags: 1. Multiple template uses
9971 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
9973 <div>Foo</div><div>bar</div><div>baz</div>
9978 Templates: Block Tags: 2. Back-to-back template uses
9980 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
9982 <div>Foo</div><div>bar</div>
9986 # This is an edge case relating to paragraph wrapping.
9988 Templates: Correctly encapsulate templates producing </p> tag without a corresponding <p> tag
9993 <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
9998 Templates: Links: 1. Simple example
10000 {{echo|[[Foo|bar]]}}
10002 <p><a href="/wiki/Foo" title="Foo">bar</a>
10007 Templates: Links: 2. Generation of link href
10009 [[{{echo|Foo}}|bar]]
10011 <p><a href="/wiki/Foo" title="Foo">bar</a>
10016 Templates: Links: 3. Generation of part of a link href
10018 [[Fo{{echo|o}}|bar]]
10020 [[Foo{{echo|bar}}]]
10022 [[Foo{{echo|bar}}baz]]
10024 [[Foo{{echo|bar}}|bar]]
10026 [[:Foo{{echo|bar}}]]
10028 [[:Foo{{echo|bar}}|bar]]
10030 <p><a href="/wiki/Foo" title="Foo">bar</a>
10031 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
10032 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
10033 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
10034 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
10035 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
10040 Templates: Links: 4. Multiple templates generating link href
10042 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
10044 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
10049 Templates: Links: 5. Generation of link text
10051 [[Foo|{{echo|bar}}]]
10053 <p><a href="/wiki/Foo" title="Foo">bar</a>
10058 Templates: Links: 5. Nested templates (only outermost template should be marked)
10060 {{echo|[[{{echo|Foo}}|bar]]}}
10062 <p><a href="/wiki/Foo" title="Foo">bar</a>
10067 Templates: HTML Tag: 1. Generation of HTML attr. key
10069 <div {{echo|style}}="color:red;">foo</div>
10071 <div style="color:red;">foo</div>
10076 Templates: HTML Tag: 2. Generation of HTML attr. value
10078 <div style={{echo|'color:red;'}}>foo</div>
10080 <div style="color:red;">foo</div>
10085 Templates: HTML Tag: 3. Generation of HTML attr key and value
10087 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
10089 <div style="color:red;">foo</div>
10094 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
10096 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
10098 <div title="This is a long title with just one piece templated">foo</div>
10103 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
10105 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
10107 <div title="This is a long title with just one piece templated">foo</div>
10112 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
10114 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
10116 <div title="This is a long title with just one piece templated">foo</div>
10121 Templates: HTML Tag: 7. Generation of partial attribute key string
10123 <div st{{echo|yle}}="color:red;">foo</div>
10125 <div style="color:red;">foo</div>
10130 Templates: HTML Tables: 1. Generating start of a HTML table
10132 {{echo|<table><tr><td>foo</td>}}</tr></table>
10134 <table><tr><td>foo</td></tr></table>
10139 Templates: HTML Tables: 2a. Generating middle of a HTML table
10141 <table><tr>{{echo|<td>foo</td>}}</tr></table>
10143 <table><tr><td>foo</td></tr></table>
10148 Templates: HTML Tables: 2b. Generating middle of a HTML table
10150 <table>{{echo|<tr><td>foo</td></tr>}}</table>
10152 <table><tr><td>foo</td></tr></table>
10157 Templates: HTML Tables: 3. Generating end of a HTML table
10159 <table><tr>{{echo|<td>foo</td></tr></table>}}
10161 <table><tr><td>foo</td></tr></table>
10166 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
10168 {{echo|<table>}}<tr><td>foo</td></tr></table>
10170 <table><tr><td>foo</td></tr></table>
10175 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
10177 <table>{{echo|<tr>}}<td>foo</td></tr></table>
10179 <table><tr><td>foo</td></tr></table>
10184 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
10186 <table><tr>{{echo|<td>}}foo</td></tr></table>
10188 <table><tr><td>foo</td></tr></table>
10193 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
10195 <table><tr><td>foo{{echo|</td>}}</tr></table>
10197 <table><tr><td>foo</td></tr></table>
10202 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
10204 <table><tr><td>foo</td>{{echo|</tr>}}</table>
10206 <table><tr><td>foo</td></tr></table>
10211 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
10213 <table><tr><td>foo</td></tr>{{echo|</table>}}
10215 <table><tr><td>foo</td></tr></table>
10220 Templates: HTML Tables: 5. Proper fostering of categories from inside
10222 parsoid=wt2html,wt2wt
10224 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
10225 <!--Two categories (Bug 50330)-->
10226 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
10228 <link rel="mw:PageProp/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
10229 <!--Two categories (Bug 50330)-->
10230 <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>
10234 Templates: Wiki Tables: 1a. Fostering of entire template content
10242 <tr><td></td></tr></table>
10254 Templates: Wiki Tables: 1b. Fostering of entire template content
10267 <tr><td></td></tr></table>
10281 Templates: Wiki Tables: 2. Fostering of partial template content
10291 <tr><td></td></tr></table>
10304 Templates: Wiki Tables: 3. td-content via multiple templates
10307 {{echo|{{pipe}}a}}{{echo|b}}
10318 Templates: Wiki Tables: 4. Templated tags, no content
10324 <tr><td></td></tr></table>
10329 Templates: Wiki Tables: 5. Templated tags, regular td-tags
10343 Templates: Wiki Tables: 6. Templated tags, templated td-tags
10357 Templates: Lists: Multi-line list-items via templates
10359 *{{echo|a {{nonexistent|
10361 *{{echo|b {{nonexistent|
10364 <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>
10365 <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>
10370 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
10372 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
10374 <p><i>ab</i>c<i>d</i>e
10379 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
10380 (PHP parser generates misnested html)
10382 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
10384 <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>
10388 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
10389 (PHP parser generates misnested html; Parsoid html2wt mode adds newlines between {{echo}}s)
10391 parsoid=wt2html,wt2wt
10393 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
10395 <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>
10396 <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>
10397 <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>
10401 Templates: Ugly nesting: 4. Divs opened/closed across templates
10403 a<div>b{{echo|c</div>d}}e
10414 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
10420 |{{echo|foo</table>}}
10424 <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|}"]}'>
10428 <td>foo</td></tr></tbody></table><span about="#mwt1">
10429 </span><span about="#mwt1">|bar</span><span about="#mwt1">
10434 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
10444 <td>1. {{echo|foo </table>}}</td>
10446 <td>2. {{echo|baz </table>}}</td>
10459 <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>"]}'>
10464 <td>1. foo </td></tr></tbody></table></td>
10466 <td>2. baz </td></tr></tbody></table><span about="#mwt2">
10467 </span><span about="#mwt2">
10468 </span><span about="#mwt2">
10469 </span><span about="#mwt2">abc</span><span about="#mwt2">
10470 </span><span about="#mwt2">
10471 </span><span about="#mwt2">
10472 </span><span about="#mwt2">
10473 </span><span about="#mwt2">
10474 </span><span about="#mwt2">
10475 </span><span about="#mwt2">xyz</span><span about="#mwt2">
10476 </span><span about="#mwt2">
10481 Templates: Ugly templates: 3. newline-only template parameter
10490 # This looks like a bug: a single newline triggers p/br for some reason.
10492 Templates: Ugly templates: 4. newline-only template parameter inconsistency
10501 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges that
10502 # have a true overlap (T1-start - T2-start - T1-end - T2-end).
10504 Templates: Ugly templates: 5. Template encapsulation test: Non-trivial overlap of template ranges is properly handled
10510 <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
10511 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
10515 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges
10516 # that are "identical" and generate nesting cycles in the algorithm
10518 Templates: Ugly templates: 6. Template encapsulation test: Cyclical nesting of template ranges is properly handled
10520 {{echo|<table><tr><td><table>}}
10524 <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"}'>
10525 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
10526 </table></td></tr></tbody></table>
10530 Parser Functions: 1. Simple example
10539 Parser Functions: 2. Nested use (only outermost should be marked up)
10548 ### Pre-save transform tests
10551 pre-save transform: subst:
10557 This is a test template
10561 pre-save transform: normal template
10571 pre-save transform: nonexistent template
10575 {{thistemplatedoesnotexist}}
10577 {{thistemplatedoesnotexist}}
10582 pre-save transform: subst magic variables
10591 # This is bug 89, which I fixed. -- wtm
10593 pre-save transform: subst: templates with parameters
10597 {{subst:paramtest|param="something else"}}
10599 This is a test template with parameter "something else"
10603 Template:nowikitest
10605 <nowiki>'''not wiki'''</nowiki>
10609 pre-save transform: nowiki in subst (bug 1188)
10613 {{subst:nowikitest}}
10615 <nowiki>'''not wiki'''</nowiki>
10620 Template:commenttest
10622 This template has <!-- a comment --> in it.
10626 pre-save transform: comment in subst (bug 1936)
10630 {{subst:commenttest}}
10632 This template has <!-- a comment --> in it.
10636 pre-save transform: unclosed tag
10640 <nowiki>'''not wiki'''
10642 <nowiki>'''not wiki'''
10646 pre-save transform: mixed tag case
10650 <NOwiki>'''not wiki'''</noWIKI>
10652 <NOwiki>'''not wiki'''</noWIKI>
10656 pre-save transform: unclosed comment in <nowiki>
10660 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
10662 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
10665 # Leading @ in this template definition works around a limitation
10666 # in parsoid's parserTests which otherwise strips the <span> from the
10667 # result (confusing it for a template wrapper)
10671 @<span onmouseover="alert('crap')">Oh no</span>
10675 (confirming safety of fix for subst bug 1936)
10677 {{Template:dangerous}}
10679 <p>@<span>Oh no</span>
10684 pre-save transform: comment containing gallery (bug 5024)
10688 <!-- <gallery>data</gallery> -->
10690 <!-- <gallery>data</gallery> -->
10694 pre-save transform: comment containing extension
10698 <!-- <tag>data</tag> -->
10700 <!-- <tag>data</tag> -->
10704 pre-save transform: comment containing nowiki
10708 <!-- <nowiki>data</nowiki> -->
10710 <!-- <nowiki>data</nowiki> -->
10714 pre-save transform: <noinclude> in subst (bug 3298)
10724 pre-save transform: <onlyinclude> in subst (bug 3298)
10728 {{subst:Includes2}}
10736 {{<includeonly>subst:</includeonly>Includes}}
10740 Template:SafeSubstTest
10742 {{<includeonly>safesubst:</includeonly>Includes}}
10746 bug 22297: safesubst: works during PST
10750 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
10756 bug 22297: safesubst: works during normal parse
10765 subst: does not work during normal parse
10769 <p>{{subst:Includes}}
10774 pre-save transform: context links ("pipe trick")
10778 [[Article (context)|]]
10781 [[Bar:Article (context)|]]
10782 [[:Bar:Article (context)|]]
10784 [[|Article (context)]]
10788 [[Article (context)|Article]]
10789 [[Bar:Article|Article]]
10790 [[:Bar:Article|Article]]
10791 [[Bar:Article (context)|Article]]
10792 [[:Bar:Article (context)|Article]]
10794 [[Article (context)]]
10795 [[Bar:X (Y) Z|X (Y) Z]]
10796 [[:Bar:X (Y) Z|X (Y) Z]]
10800 pre-save transform: context links ("pipe trick") with interwiki prefix
10804 [[interwiki:Article|]]
10805 [[:interwiki:Article|]]
10806 [[interwiki:Bar:Article|]]
10807 [[:interwiki:Bar:Article|]]
10809 [[interwiki:Article|Article]]
10810 [[:interwiki:Article|Article]]
10811 [[interwiki:Bar:Article|Bar:Article]]
10812 [[:interwiki:Bar:Article|Bar:Article]]
10816 pre-save transform: context links ("pipe trick") with parens in title
10818 pst title=[[Somearticle (context)]]
10822 [[Article (context)|Article]]
10826 pre-save transform: context links ("pipe trick") with comma in title
10828 pst title=[[Someplace, Somewhere]]
10831 [[Otherplace, Elsewhere|]]
10832 [[Otherplace, Elsewhere, Anywhere|]]
10834 [[Otherplace, Somewhere|Otherplace]]
10835 [[Otherplace, Elsewhere|Otherplace]]
10836 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
10840 pre-save transform: context links ("pipe trick") with parens and comma
10842 pst title=[[Someplace (IGNORED), Somewhere]]
10845 [[Otherplace (place), Elsewhere|]]
10847 [[Otherplace, Somewhere|Otherplace]]
10848 [[Otherplace (place), Elsewhere|Otherplace]]
10852 pre-save transform: context links ("pipe trick") with comma and parens
10854 pst title=[[Who, me? (context)]]
10857 [[Me, Myself, and I (1937 song)|]]
10859 [[Yes, you. (context)|Yes, you.]]
10860 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
10864 pre-save transform: context links ("pipe trick") with namespace
10866 pst title=[[Ns:Somearticle]]
10870 [[Ns:Article|Article]]
10874 pre-save transform: context links ("pipe trick") with namespace and parens
10876 pst title=[[Ns:Somearticle (context)]]
10880 [[Ns:Article (context)|Article]]
10884 pre-save transform: context links ("pipe trick") with namespace and comma
10886 pst title=[[Ns:Somearticle, Context, Whatever]]
10890 [[Ns:Article, Context, Whatever|Article]]
10894 pre-save transform: context links ("pipe trick") with namespace, comma and parens
10896 pst title=[[Ns:Somearticle, Context (context)]]
10900 [[Ns:Article (context)|Article]]
10904 pre-save transform: context links ("pipe trick") with namespace, parens and comma
10906 pst title=[[Ns:Somearticle (IGNORED), Context]]
10910 [[Ns:Article, Context|Article]]
10914 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
10918 [[Article(context)|]]
10919 [[Bar:Article(context)|]]
10920 [[:Bar:Article(context)|]]
10921 [[|Article(context)]]
10925 [[Article(context)|Article]]
10926 [[Bar:Article(context)|Article]]
10927 [[:Bar:Article(context)|Article]]
10928 [[Article(context)]]
10929 [[Bar:X(Y)Z|X(Y)Z]]
10930 [[:Bar:X(Y)Z|X(Y)Z]]
10934 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
10938 [[Article (context)|]]
10939 [[Bar:Article (context)|]]
10940 [[:Bar:Article (context)|]]
10941 [[|Article (context)]]
10945 [[Article (context)|Article]]
10946 [[Bar:Article (context)|Article]]
10947 [[:Bar:Article (context)|Article]]
10948 [[Article (context)]]
10949 [[Bar:X (Y) Z|X (Y) Z]]
10950 [[:Bar:X (Y) Z|X (Y) Z]]
10954 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
10958 [[Article(context)|]]
10959 [[Bar:Article(context)|]]
10960 [[:Bar:Article(context)|]]
10961 [[|Article(context)]]
10965 [[Article(context)|Article]]
10966 [[Bar:Article(context)|Article]]
10967 [[:Bar:Article(context)|Article]]
10968 [[Article(context)]]
10969 [[Bar:X(Y)Z|X(Y)Z]]
10970 [[:Bar:X(Y)Z|X(Y)Z]]
10974 pre-save transform: context links ("pipe trick") with commas (bug 21660)
10978 [[Article (context), context|]]
10979 [[Article (context),context|]]
10980 [[Bar:Article (context), context|]]
10981 [[Bar:Article (context),context|]]
10982 [[:Bar:Article (context), context|]]
10983 [[:Bar:Article (context),context|]]
10985 [[Article (context), context|Article]]
10986 [[Article (context),context|Article]]
10987 [[Bar:Article (context), context|Article]]
10988 [[Bar:Article (context),context|Article]]
10989 [[:Bar:Article (context), context|Article]]
10990 [[:Bar:Article (context),context|Article]]
10994 pre-save transform: trim trailing empty lines
10998 Empty lines are trimmed
11004 Empty lines are trimmed
11008 pre-save transform: Signature expansion
11013 * <noinclude>~~~</noinclude>
11014 * <includeonly>~~~</includeonly>
11015 * <onlyinclude>~~~</onlyinclude>
11017 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
11018 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
11019 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
11020 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
11025 pre-save transform: Signature expansion in nowiki tags (bug 93)
11031 <nowiki>~~~~</nowiki>
11033 <includeonly><nowiki>~~~~</nowiki></includeonly>
11035 <noinclude><nowiki>~~~~</nowiki></noinclude>
11037 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
11039 {{subst:Foo}} shall be converted to FOO
11041 As well as inside noinclude/onlyinclude
11042 <noinclude>{{subst:Foo}}</noinclude>
11043 <onlyinclude>{{subst:Foo}}</onlyinclude>
11045 But not inside includeonly
11046 <includeonly>{{subst:Foo}}</includeonly>
11050 <nowiki>~~~~</nowiki>
11052 <includeonly><nowiki>~~~~</nowiki></includeonly>
11054 <noinclude><nowiki>~~~~</nowiki></noinclude>
11056 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
11058 FOO shall be converted to FOO
11060 As well as inside noinclude/onlyinclude
11061 <noinclude>FOO</noinclude>
11062 <onlyinclude>FOO</onlyinclude>
11064 But not inside includeonly
11065 <includeonly>{{subst:Foo}}</includeonly>
11069 Parsoid: Recognize nowiki with trailing space in tags
11073 <nowiki ><div>[[foo]]</nowiki >
11081 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
11088 Parsoid: Recognize nowiki with odd capitalization
11092 <noWikI ><div>[[foo]]</Nowiki >
11094 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
11099 Parsoid: Escape nowiki with trailing space in tags
11103 <nowiki > foo </nowiki >
11109 <p><nowiki > foo </nowiki ></p>
11110 <p>a<nowiki />b</p>
11111 <p>c<nowiki/ >d</p>
11115 Parsoid: Escape weird noWikI capitalizations
11119 <noWikI > foo </NoWikI >
11121 <p><noWikI > foo </NoWikI ></p>
11125 ### Message transform tests
11128 message transform: magic variables
11138 message transform: should not transform wiki markup
11148 message transform: <noinclude> in transcluded template (bug 4926)
11158 message transform: <onlyinclude> in transcluded template (bug 4926)
11168 {{#special:}} page name, known
11172 {{#special:Recentchanges}}
11174 Special:RecentChanges
11178 {{#special:}} page name with subpage, known
11182 {{#special:Recentchanges/param}}
11184 Special:RecentChanges/param
11188 {{#special:}} page name, unknown
11192 {{#special:foobar nonexistent}}
11194 Special:Foobar nonexistent
11198 {{#speciale:}} page name, known
11202 {{#speciale:Recentchanges}}
11204 Special:RecentChanges
11208 {{#speciale:}} page name with subpage, known
11212 {{#speciale:Recentchanges/param}}
11214 Special:RecentChanges/param
11218 {{#speciale:}} page name, unknown
11222 {{#speciale:foobar nonexistent}}
11224 Special:Foobar_nonexistent
11230 ### For Parsoid-specific tests, see
11231 #### https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
11236 parsoid=wt2html,wt2wt,html2html
11238 [[Image:foobar.jpg]]
11240 <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>
11243 <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>
11247 Simple image (using File: namespace, now canonical)
11249 [[File:Foobar.jpg]]
11251 <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>
11254 <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>
11258 Right-aligned image
11260 [[File:Foobar.jpg|right]]
11262 <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>
11265 <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>
11271 [[File:Foobar.jpg|right|Caption text]]
11273 <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>
11276 <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>
11280 Image with caption, bug 53312 #1
11282 [[File:Foobar.jpg|right|Caption page stuff]]
11284 <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>
11287 <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>
11291 Image with caption, bug 53312 #2
11293 [[File:Foobar.jpg|right|Caption page=]]
11295 <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>
11298 <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>
11302 Image with caption, bug 53312 #3
11304 [[File:Foobar.jpg|right|Caption page=stuff]]
11306 <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>
11309 <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>
11313 Allow empty links in image captions (Bug 60753)
11317 [[File:Foobar.jpg|thumb|Caption [[Link1]]
11322 <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>
11325 <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>
11327 <a rel="mw:WikiLink" href="./Link2" title="Link2" data-parsoid='{"stx":"simple","a":{"href":"./Link2"},"sa":{"href":"Link2"}}'>Link2</a>
11328 </figcaption></figure>
11332 Titles in unlinked images (T23454)
11334 [[File:Foobar.jpg|link=|stuff]]
11336 <p><img alt="stuff" src="http://example.com/images/3/3a/Foobar.jpg" title="stuff" width="1941" height="220" />
11341 Link with empty target
11350 Image with empty attribute
11352 parsoid=wt2html,wt2wt,html2html
11354 [[File:Foobar.jpg|right||Caption text]]
11356 <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>
11359 <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>
11363 1. Block image with individual attributes from templates
11365 [[File:Foobar.jpg|thumb|{{echo|137px}}|This is a caption]]
11367 <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>
11370 <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>
11374 2. Block Image with individual attributes from templates
11376 [[File:Foobar.jpg|{{echo|thumb}}|{{echo|137px}}|This is a caption]]
11378 <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>
11381 <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>
11385 3. Inline image with individual attributes from templates
11387 [[File:Foobar.jpg|{{echo|50px}}]]
11389 <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>
11392 <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>
11395 ## Parsoid does not provide editing support for images where templates produce multiple image attributes.
11396 ## To signal this, we add a 'mw:Placeholder' type to such images. This could change in the future.
11398 Image with multiple attributes from the same template
11400 [[File:Foobar.jpg|{{image_attribs}}]]
11402 <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>
11405 <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>
11409 Image with link tails
11413 123[[File:Foobar.jpg]]456
11414 123[[File:Foobar.jpg|right]]456
11415 123[[File:Foobar.jpg|thumb]]456
11417 <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
11419 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
11420 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
11423 <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>
11425 <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>
11427 <div class="thumb tright">
11428 <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>
11429 <div class="thumbcaption">
11430 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
11436 <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>
11437 <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>
11438 <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>
11442 Image with multiple captions -- only last one is accepted
11444 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
11446 <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>
11449 <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>
11453 Image with multiple widths -- use last
11455 [[File:Foobar.jpg|200px|300px|caption]]
11457 <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>
11460 <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>
11464 Image with multiple alignments -- use first (bug 48664)
11468 [[File:Foobar.jpg|thumb|left|right|center|caption]]
11470 [[File:Foobar.jpg|middle|text-top|caption]]
11472 <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>
11473 <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>
11476 <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>
11477 <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>
11481 Image with width attribute at different positions
11483 [[File:Foobar.jpg|200px|right|Caption]]
11484 [[File:Foobar.jpg|right|200px|Caption]]
11485 [[File:Foobar.jpg|right|Caption|200px]]
11487 <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>
11488 <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>
11489 <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>
11492 <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>
11493 <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>
11494 <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>
11497 # a sad bit of backward-compatibility
11499 Image with size specified with pxpx (bug 13500, 51628)
11501 parsoid=wt2html,wt2wt,html2html
11503 [[File:Foobar.jpg|20pxpx]]
11504 [[File:Foobar.jpg|200x20pxpx]]
11506 <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>
11507 <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>
11510 <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>
11514 Image with link parameter, wiki target
11516 [[File:Foobar.jpg|link=Main Page]]
11518 <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>
11521 <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>
11524 # parsoid bug 49293 (part 1)
11526 Image with link parameter, URL target
11528 [[File:Foobar.jpg|link=http://example.com/]]
11530 <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>
11533 <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>
11536 # parsoid bug 49293 (part 2)
11538 Image with link parameter, protocol-less URL target
11540 [[File:Foobar.jpg|link=//example.com/]]
11542 <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>
11545 <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>
11549 Image with link parameter, wgExternalLinkTarget
11551 [[Image:foobar.jpg|link=http://example.com/]]
11553 wgExternalLinkTarget='foobar'
11555 <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>
11560 Image with link parameter, wgNoFollowLinks set to false
11562 [[Image:foobar.jpg|link=http://example.com/]]
11564 wgNoFollowLinks=false
11566 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11571 Image with link parameter, wgNoFollowDomainExceptions
11573 [[Image:foobar.jpg|link=http://example.com/]]
11575 wgNoFollowDomainExceptions='example.com'
11577 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11582 Image with link parameter, wgExternalLinkTarget, unnamed parameter
11584 [[Image:foobar.jpg|link=http://example.com/|Title]]
11586 wgExternalLinkTarget='foobar'
11588 <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>
11593 Image with empty link parameter
11595 [[File:Foobar.jpg|link=]]
11597 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
11600 <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>
11604 Image with link parameter (wiki target) and unnamed parameter
11606 [[File:Foobar.jpg|link=Main_Page|Title]]
11608 <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>
11611 <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>
11615 Image with link parameter (URL target) and unnamed parameter
11617 [[File:Foobar.jpg|link=http://example.com/|Title]]
11619 <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>
11622 <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>
11626 Thumbnail image with link parameter
11629 parsoid=wt2html,wt2wt,html2html
11631 [[File:Foobar.jpg|thumb|link=http://example.com/|Title]]
11633 <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>
11636 <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>
11640 Manually-specified thumbnail image
11644 [[File:Foobar.jpg|thumb=Thumb.png|Title]]
11646 <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>
11649 <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>
11653 Manually-specified thumbnail image with explicit link to wiki page
11656 parsoid=wt2html,wt2wt,html2html
11658 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|Title]]
11660 <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>
11663 <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>
11667 Manually-specified thumbnail image with explicit link to url
11670 parsoid=wt2html,wt2wt,html2html
11672 [[File:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
11674 <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>
11677 <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>
11681 Manually-specified thumbnail image with explicit no link
11684 parsoid=wt2html,wt2wt,html2html
11686 [[File:Foobar.jpg|thumb=Thumb.png|link=|Title]]
11688 <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>
11691 <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>
11695 Manually-specified thumbnail image with explicit link and alt text
11698 parsoid=wt2html,wt2wt,html2html
11700 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|alt=alttext|Title]]
11702 <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>
11705 <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>
11709 Image with frame and link
11711 parsoid=wt2html,wt2wt,html2html
11713 [[File:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
11715 <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>
11718 <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>
11722 Image with frame and link and explicit alt
11724 parsoid=wt2html,wt2wt,html2html
11726 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
11728 <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>
11731 <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>
11735 Image with wiki markup in implicit alt
11737 parsoid=wt2html,wt2wt,html2html
11739 [[Image:Foobar.jpg|testing '''bold''' in alt]]
11741 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
11743 <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>
11744 </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>
11747 <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>
11748 <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>
11751 ###################
11752 # Conflicting image format options.
11753 # First option specified should 'win'.
11754 # All three cases in each test should be identical.
11757 Image with 'frameless' first.
11759 parsoid=wt2html,wt2wt,html2html
11761 [[File:Foobar.jpg|frameless|caption]]
11763 [[File:Foobar.jpg|frameless|frame|caption]]
11765 [[File:Foobar.jpg|frameless|thumb|caption]]
11767 <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>
11768 </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>
11769 </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>
11772 <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>
11773 <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>
11774 <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>
11778 Image with 'frame' first.
11780 parsoid=wt2html,wt2wt,html2html
11782 [[File:Foobar.jpg|frame|caption]]
11783 [[File:Foobar.jpg|frame|frameless|caption]]
11784 [[File:Foobar.jpg|frame|thumb|caption]]
11786 <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>
11787 <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>
11788 <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>
11791 <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>
11792 <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>
11793 <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>
11797 Image with 'thumb' first.
11799 parsoid=wt2html,wt2wt,html2html
11801 [[File:Foobar.jpg|thumb|caption]]
11802 [[File:Foobar.jpg|thumb|frameless|caption]]
11803 [[File:Foobar.jpg|thumb|frame|caption]]
11805 <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>
11806 <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>
11807 <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>
11810 <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>
11811 <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>
11812 <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>
11815 ###################
11817 # See https://www.mediawiki.org/wiki/Help:Images#Size_and_frame
11818 # and https://bugzilla.wikimedia.org/show_bug.cgi?id=62258
11819 # Foobar has actual size of 1941x220
11820 # 1. Thumbs & frameless always reduce, can't be enlarged unless it's
11821 # a scalable format.
11822 # 2. Framed images always ignore size options; always render at default size.
11823 # 3. "Unspecified format" and border are the only types which can be
11827 Image: "unspecified format" and border enlarge
11829 parsoid=wt2html,wt2wt,html2html
11831 [[File:Foobar.jpg|2000px]]
11833 [[File:Foobar.jpg|border|2000px]]
11835 <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>
11836 </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>
11839 <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>
11840 <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>
11844 Image: "unspecified format" and border reduce
11846 parsoid=wt2html,wt2wt,html2html
11848 [[File:Foobar.jpg|1000px]]
11850 [[File:Foobar.jpg|border|1000px]]
11852 <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>
11853 </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>
11856 <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>
11857 <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>
11861 Image: thumbs reduce
11863 parsoid=wt2html,wt2wt,html2html
11865 [[File:Foobar.jpg|thumb|50px]]
11867 <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>
11870 <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>
11874 Image: bitmap thumbs can't be enlarged past original size, but vector can.
11876 parsoid=wt2html,wt2wt,html2html
11878 [[File:Foobar.jpg|thumb|2000px]]
11880 [[File:Foobar.svg|thumb|2000px]]
11882 <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>
11883 <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>
11886 <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>
11887 <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>
11891 Image: frameless can reduce in size
11893 parsoid=wt2html,wt2wt,html2html
11895 [[File:Foobar.jpg|frameless|50px]]
11897 <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>
11900 <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>
11904 Image: bitmap frameless can't be enlarged past original size, but vector can
11906 parsoid=wt2html,wt2wt,html2html
11908 [[File:Foobar.jpg|frameless|2000px]]
11910 [[File:Foobar.svg|frameless|2000px]]
11912 <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>
11913 </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>
11916 <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>
11917 <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>
11921 Image: framed images are always unscaled.
11923 parsoid=wt2html,wt2wt,html2html
11925 [[File:Foobar.jpg|frame]]
11927 [[File:Foobar.jpg|frame|50px]]
11929 [[File:Foobar.jpg|frame|50x50px]]
11931 [[File:Foobar.jpg|frame|2000px]]
11933 <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>
11934 <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>
11935 <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>
11936 <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>
11939 <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>
11940 <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>
11941 <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>
11942 <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>
11945 ###################
11948 Link to image page- image page normally doesn't exists, hence edit link
11949 Add test with existing image page
11950 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
11954 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
11959 bug 18784 Link to non-existent image page with caption should use caption as link text
11961 [[:Image:test|caption]]
11963 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
11968 Frameless image caption with a free URL
11970 [[File:Foobar.jpg|http://example.com]]
11972 <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>
11975 <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>
11979 Thumbnail image caption with a free URL
11983 [[File:Foobar.jpg|thumb|http://example.com]]
11985 <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>
11988 <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>
11992 Thumbnail image caption with a free URL and explicit alt
11995 parsoid=wt2html,wt2wt,html2html
11997 [[File:Foobar.jpg|thumb|http://example.com|alt=Alteration]]
11999 <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>
12002 <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>
12006 SVG thumbnails with no language set
12009 [[File:Foobar.svg|thumb|caption]]
12011 <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>
12014 <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>
12018 SVG thumbnails with language de
12020 parsoid=wt2html,wt2wt,html2html
12022 [[File:Foobar.svg|thumb|caption|lang=de]]
12024 <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>
12027 <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>
12031 SVG thumbnails with invalid language code
12033 parsoid=wt2html,wt2wt,html2html
12035 [[File:Foobar.svg|thumb|caption|lang=invalid.language.code]]
12037 <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>
12040 <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>
12044 BUG 1887: A ISBN with a thumbnail
12046 [[File:Foobar.jpg|thumb|ISBN 1235467890]]
12048 <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>
12051 <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>
12055 BUG 1887: A RFC with a thumbnail
12057 [[File:Foobar.jpg|thumb|This is RFC 12354]]
12059 <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>
12062 <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>
12066 BUG 1887: A mailto link with a thumbnail
12068 [[File:Foobar.jpg|thumb|Please mailto:nobody@example.com]]
12070 <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>
12073 <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>
12076 # Pending resolution to bug 368
12078 BUG 648: Frameless image caption with a link
12080 [[File:Foobar.jpg|text with a [[link]] in it]]
12082 <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>
12085 <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>
12089 BUG 648: Frameless image caption with a link (suffix)
12091 [[File:Foobar.jpg|text with a [[link]]foo in it]]
12093 <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>
12096 <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>
12100 BUG 648: Frameless image caption with an interwiki link
12102 [[File:Foobar.jpg|text with a [[MeatBall:Link]] in it]]
12104 <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>
12107 <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>
12111 BUG 648: Frameless image caption with a piped interwiki link
12113 [[File:Foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
12115 <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>
12118 <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>
12122 Escape HTML special chars in image alt text
12124 [[File:Foobar.jpg|& < > "]]
12126 <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>
12129 <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>
12133 BUG 499: Alt text should have Ӓ, not &1234;
12135 [[File:Foobar.jpg|♀]]
12137 <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>
12140 <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>
12144 Broken image caption with link
12146 parsoid=wt2html,wt2wt,html2html
12148 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
12150 <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.
12153 <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>
12157 Image caption containing another image
12159 [[File:Foobar.jpg|thumb|This is a caption with another [[File:Thumb.png|image]] inside it!]]
12161 <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>
12164 <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>
12168 Image: caption containing a newline
12170 [[File:Foobar.jpg|This
12173 <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>
12176 <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>
12180 Image: caption containing leading space
12181 (The leading space should not trigger nowiki escaping in wt2wt mode)
12183 [[File:Foobar.jpg|thumb| bar]]
12185 <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>
12188 <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>
12192 Image: caption containing a table
12194 parsoid=wt2html,wt2wt,html2html
12196 [[Image:Foobar.jpg|thumb|200px|This is an example image thumbnail caption with a table
12202 and some more text.]]
12204 <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>
12207 <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
12210 <tr><th>Foo </th><th>Bar</th></tr>
12213 <td>Bar1</td></tr></tbody></table>and some more text.</figcaption></figure>
12217 Bug 3090: External links other than http: in image captions
12219 [[File:Foobar.jpg|thumb|200x200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
12221 <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>
12224 <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>
12230 parsoid=wt2html,wt2wt,html2html
12232 [[Image:foobar.jpg|a|class=b]]
12234 <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>
12237 <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>
12241 Localized image handling (1).
12243 parsoid=wt2html,wt2wt,html2html
12246 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
12248 <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>
12251 <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>
12255 Localized image handling (2).
12258 parsoid=wt2html,wt2wt,html2html
12261 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
12263 <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>
12266 <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>
12270 "border", "frameless" and "class" attributes on an image.
12273 parsoid=wt2html,wt2wt,html2html
12275 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
12277 <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>
12280 <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>
12283 # Note that 'right' is the default alignment, despite the misspelled 'righ' below
12285 Invalid image attributes (bug 62500)
12288 parsoid=wt2html,wt2wt,html2html
12290 [[File:Foobar.jpg|thumb|float|left|caption]]
12292 [[File:Foobar.jpg|thumb|righ|caption]]
12294 [[File:Foobar.jpg|bogus1|thumb|bogus2|left|bogus3|caption]]
12296 <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>
12297 <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>
12298 <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>
12301 <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>
12302 <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>
12303 <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>
12309 #REDIRECT [[File:Barfoo.jpg]]
12312 # FIXME: Parsoid should run this test -- but we'd need to teach the
12313 # mockAPI about the redirected Barfoo.jpg image.
12317 [[Image:Barfoo.jpg]]
12319 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
12324 Missing image with uploads disabled
12328 [[File:Foobaz.jpg]]
12330 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
12333 <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>
12336 # Parsoid-specific testing for images
12337 # https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
12338 # Currently imperfect due to a flaw in the Parsoid testrunner
12340 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
12344 Parsoid-specific image handling - simple image with size and middle alignment
12346 [[File:Foobar.jpg|middle|50px]]
12348 <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>
12352 Parsoid-specific image handling - simple image with size, middle alignment,
12353 non-standard namespace alias
12355 parsoid=wt2wt,wt2html,html2html
12357 [[Image:Foobar.jpg|middle|50px]]
12359 <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>
12363 Parsoid-specific image handling - simple image with size and middle alignment
12366 [[File:Foobar.jpg|50px|middle]]
12368 <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>
12372 Parsoid-specific image handling - simple image with size and middle alignment
12373 and non-standard namespace name
12375 parsoid=wt2html,wt2wt,html2html
12377 [[Image:Foobar.jpg|50px|middle]]
12379 <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>
12383 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
12385 [[File:Foobar.jpg|500x10px|baseline|caption]]
12387 <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>
12391 Parsoid-specific image handling - simple image with border and size spec
12393 [[File:Foobar.jpg|50px|border|caption]]
12395 <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>
12399 Parsoid-specific image handling - thumbnail with halign, valign, and caption
12401 [[File:Foobar.jpg|left|baseline|thumb|caption content]]
12403 <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>
12407 Parsoid-specific image handling - thumbnail with halign, valign, and caption
12410 [[File:Foobar.jpg|thumb|left|baseline|caption content]]
12412 <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>
12416 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
12418 [[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
12420 <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>
12424 Parsoid-specific image handling - thumbnail with specific size, halign,
12425 valign, and caption (existing content)
12427 [[File:Foobar.jpg|thumb|50x50px|right|middle|caption]]
12429 <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>
12433 Parsoid-specific image handling - framed image with specific size and caption
12436 parsoid=wt2html,wt2wt,html2html
12438 [[File:Foobar.jpg|frame|500x50px|caption]]
12440 <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>
12444 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
12447 parsoid=wt2html,wt2wt,html2html
12449 [[File:Foobar.jpg|left|baseline|frame|500x50px|caption]]
12451 <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>
12455 Parsoid-specific image handling - frameless image with specific size, border, and caption
12457 [[File:Foobar.jpg|frameless|442x50px|border|caption]]
12459 <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>
12463 Parsoid-specific image handling - simple image with a formatted caption
12465 [[File:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
12467 <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>
12471 Parsoid-specific image handling - caption with a template in it
12473 [[File:Foobar.jpg|thumb|200x23px|This caption has a {{echo|transclusion}} in it.]]
12475 <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>
12479 Parsoid-specific image handling - caption with unbalanced tags in it
12481 parsoid=wt2html,wt2wt,html2html
12484 [[File:Foobar.jpg|thumb|200x200px|This caption has a <center>unbalanced tag in it.]]
12488 <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>
12493 Parsoid-specific image handling - empty caption (1)
12495 parsoid=wt2html,wt2wt
12497 [[File:Foobar.jpg|thumb|]]
12499 <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>
12502 # empty captions don't get serialized unless we're in the "round trip" case
12504 Parsoid-specific image handling - empty caption (2)
12508 <figure class="mw-default-size" typeof="mw:Image/Thumb">
12509 <a href="File:Foobar.jpg">
12510 <img resource="./File:Foobar.jpg"
12511 src="//example.com/images/3/3a/Foobar.jpg"
12512 height="25" width="220"/>
12514 <figcaption></figcaption>
12517 [[File:Foobar.jpg|thumb]]
12521 Parsoid-specific image handling - whitespace caption
12523 [[File:Foobar.jpg|thumb| ]]
12525 <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>
12529 Parsoid-specific image handling - lang option
12532 [[File:Foobar.svg|lang=de|caption]]
12536 <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>
12545 Subpage test/subpage
12553 subpage title=[[Subpage test]]
12557 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
12562 Subpage noslash link
12564 subpage title=[[Subpage test]]
12568 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
12573 Subpage test/1/2/subpage
12579 Relative subpage noslash link
12581 parsoid=wt2wt,wt2html,html2html
12582 subpage title=[[Subpage test/1/2/3/4]]
12588 <p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a>
12589 </p><p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage test/1/2/subpage</a>
12592 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a></p>
12593 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
12597 Parsoid: dot-slash prefixed wikilinks
12607 </p><p>[[././baz/]]
12612 </p><p>[[././baz/]]
12617 Render invalid page names as plain text (bug 51090)
12630 [[{{echo|./../foo}}|bar]]
12631 [[{{echo|foo/.}}|bar]]
12632 [[{{echo|foo/..}}|bar]]
12633 [[{{echo|foo~~~~bar}}]]
12634 [[{{echo|foo>bar}}]]
12635 [[{{echo|foo././bar}}]]
12636 [[{{echo|foo{bar}}]]
12637 [[{{echo|foo}bar}}]]
12638 [[{{echo|foo[bar}}]]
12639 [[{{echo|foo]bar}}]]
12640 [[{{echo|foo<bar}}]]
12642 <p>[[./../foo|bar]]
12652 </p><p>[[./../foo|bar]]
12665 <p>[[./../foo|bar]]
12676 <p>[[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"./../foo"}},"i":0}}]}'>./../foo</span>|bar]]
12677 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/."}},"i":0}}]}'>foo/.</span>|bar]]
12678 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/.."}},"i":0}}]}'>foo/..</span>|bar]]
12679 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo~~~~bar"}},"i":0}}]}'>foo~~~~bar</span>]]
12680 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo>bar"}},"i":0}}]}'>foo>bar</span>]]
12681 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo././bar"}},"i":0}}]}'>foo././bar</span>]]
12682 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo{bar"}},"i":0}}]}'>foo{bar</span>]]
12683 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo}bar"}},"i":0}}]}'>foo}bar</span>]]
12684 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo[bar"}},"i":0}}]}'>foo[bar</span>]]
12685 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo]bar"}},"i":0}}]}'>foo]bar</span>]]
12686 [[<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>
12694 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
12699 BUG 561: {{/Subpage}}
12701 subpage title=[[Page]]
12705 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
12713 Category:MediaWiki User's Guide
12721 [[:Category:MediaWiki User's Guide]]
12723 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
12732 [[Category:MediaWiki User's Guide]]
12734 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
12738 PAGESINCATEGORY invalid title fatal (r33546 fix)
12740 {{PAGESINCATEGORY:<bogus>}}
12747 Category with different sort key
12751 [[Category:MediaWiki User's Guide|Foo]]
12753 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
12757 Category with identical sort key
12761 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
12763 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
12767 Category with empty sort key
12772 [[Category:MediaWiki User's Guide|]]
12774 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
12778 Category with empty sort key and parentheses
12783 [[Category:Foo (bar)|]]
12785 [[Category:Foo (bar)|Foo]]
12789 Category with link tail
12794 123[[Category:Foo]]456
12796 123[[Category:Foo]]456
12800 Category with template
12805 [[Category:{{echo|Foo}}]]
12807 [[Category:{{echo|Foo}}]]
12811 Category with template in sort key
12816 [[Category:Foo|{{echo|Bar}}]]
12818 [[Category:Foo|{{echo|Bar}}]]
12822 Category with template in sort key and title
12827 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
12829 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
12833 Category / paragraph interactions
12835 Foo [[Category:Baz]] Bar
12837 Foo [[Category:Baz]]
12845 [[Category:Baz]] Bar
12858 {{echo|[[Category:Baz]]}}
12873 Parsoid: Serialize link to category page with colon escape
12879 [[:Category:Foo|Bar]]
12882 <a rel="mw:WikiLink" href="Category:Foo" title="Category:Foo">Category:Foo</a>
12883 <a rel="mw:WikiLink" href="Category:Foo" title="Category:Foo">Bar</a>
12888 Parsoid: Link prefix/suffixes aren't applied to category links
12890 parsoid=wt2html,wt2wt,html2html
12895 <p>x<link rel="mw:PageProp/Category" href="Category:Foo">y</p>
12899 Parsoid: Serialize link to file page with colon escape
12905 [[:File:Foo.png|Bar]]
12908 <a rel="mw:WikiLink" href="File:Foo.png" title="File:Foo.png">File:Foo.png</a>
12909 <a rel="mw:WikiLink" href="File:Foo.png" title="File:Foo.png">Bar</a>
12914 Parsoid: Serialize a genuine category link without colon escape
12919 [[Category:Foo|Bar]]
12921 <link rel="mw:PageProp/Category" href="Category:Foo">
12922 <link rel="mw:PageProp/Category" href="Category:Foo#Bar">
12926 Normalize hrefs properly before testing for invalid link targets (bug 70894)
12930 <link rel="mw:PageProp/Category" href="./Category:Toxine_bactérienne"/>
12932 [[Category:Toxine bactérienne]]
12936 Parsoid: Defaultsort
12940 {{DEFAULTSORT:Foo}}
12942 <meta property="mw:PageProp/categorydefaultsort" content="Foo"/>
12946 ### Inter-language links
12949 Interlanguage links
12957 es:Alimento fr:Nourriture zh:食品
12959 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Alimento"/>
12960 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/Nourriture"/>
12961 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/食品"/>
12965 Duplicate interlanguage links (bug 24502)
12976 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/1"/>
12977 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/2"/>
12978 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/1"/>
12979 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/2"/>
12986 Basic section headings
12993 ===Smaller headline===
12996 <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>
12999 <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>
13002 <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>
13008 Section headings with TOC
13011 === Subheadline 1 ===
13012 ===== Skipping a level =====
13013 ====== Skipping a level ======
13017 ===Another headline===
13019 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13021 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
13023 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
13025 <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>
13027 <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>
13034 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
13036 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
13042 <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>
13043 <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>
13044 <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>
13045 <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>
13046 <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>
13049 <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>
13053 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
13055 Handling of sections up to level 6 and beyond
13058 == Level 2 Heading==
13059 === Level 3 Heading===
13060 ==== Level 4 Heading====
13061 ===== Level 5 Heading=====
13062 ====== Level 6 Heading======
13063 ======= Level 7 Heading=======
13064 ======== Level 8 Heading========
13065 ========= Level 9 Heading=========
13066 ========== Level 10 Heading==========
13068 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13070 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
13072 <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>
13074 <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>
13076 <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>
13078 <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>
13080 <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>
13081 <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>
13082 <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>
13083 <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>
13084 <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>
13098 <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>
13099 <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>
13100 <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>
13101 <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>
13102 <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>
13103 <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>
13104 <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>
13105 <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>
13106 <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>
13107 <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>
13112 TOC regression (bug 9764)
13116 ==== title 1.1.1 ====
13121 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13123 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
13125 <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>
13127 <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>
13130 <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>
13133 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
13135 <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>
13141 <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>
13142 <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>
13143 <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>
13144 <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>
13145 <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>
13146 <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>
13151 TOC with wgMaxTocLevel=3 (bug 6204)
13157 ==== title 1.1.1 ====
13162 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13164 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
13166 <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>
13167 <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>
13170 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
13172 <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>
13178 <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>
13179 <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>
13180 <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>
13181 <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>
13182 <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>
13183 <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>
13188 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
13194 ====Section 1.1.1====
13195 ====Section 1.1.1.1====
13198 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13200 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
13202 <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>
13205 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
13209 <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>
13210 <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>
13211 <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>
13212 <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>
13213 <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>
13219 Resolving duplicate section names
13224 <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>
13225 <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>
13230 Resolving duplicate section names with differing case (bug 10721)
13235 <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>
13236 <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>
13248 Template with sections, __NOTOC__
13255 <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>
13256 <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>
13257 <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>
13258 <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>
13263 __NOEDITSECTION__ keyword
13269 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
13270 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
13275 Link inside a section heading
13277 ==Section with a [[Main Page|link]] in it==
13279 <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>
13284 TOC regression (bug 12077)
13291 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13293 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
13295 <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>
13298 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
13302 <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>
13303 <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>
13304 <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>
13309 BUG 1219 URL next to image (good)
13311 http://example.com [[Image:foobar.jpg]]
13313 <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>
13318 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
13321 The line above must have a trailing space!
13324 But just in case it doesn't...
13326 <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>
13327 <p>The line above must have a trailing space!
13329 <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>
13330 <p>But just in case it doesn't...
13335 Header with special characters (bug 25462)
13337 The tooltips shall not show entities to the user (ie. be double escaped)
13354 <p>The tooltips shall not show entities to the user (ie. be double escaped)
13356 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13358 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
13359 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
13360 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
13361 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
13362 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
13366 <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>
13369 <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>
13372 <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>
13375 <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>
13378 <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>
13384 Header with space, plus and underscore as entity
13386 Id should not contain + for spaces
13388 == Space between Text ==
13391 == Space-Entity between Text ==
13394 == Plus+between+Text ==
13397 == Plus-Entity+between+Text ==
13400 == Underscore_between_Text ==
13403 == Underscore-Entity_between_Text ==
13406 [[#Space between Text]]
13407 [[#Space-Entity between Text]]
13408 [[#Plus+between+Text]]
13409 [[#Plus-Entity+between+Text]]
13410 [[#Underscore_between_Text]]
13411 [[#Underscore-Entity_between_Text]]
13413 <p>Id should not contain + for spaces
13415 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13417 <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>
13418 <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>
13419 <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>
13420 <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>
13421 <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>
13422 <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>
13426 <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>
13429 <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>
13432 <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>
13435 <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>
13438 <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>
13441 <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>
13443 </p><p><a href="#Space_between_Text">#Space between Text</a>
13444 <a href="#Space-Entity_between_Text">#Space-Entity between Text</a>
13445 <a href="#Plus.2Bbetween.2BText">#Plus+between+Text</a>
13446 <a href="#Plus-Entity.2Bbetween.2BText">#Plus-Entity+between+Text</a>
13447 <a href="#Underscore_between_Text">#Underscore_between_Text</a>
13448 <a href="#Underscore-Entity_between_Text">#Underscore-Entity_between_Text</a>
13453 Headers with excess '=' characters
13454 (Are similar tests necessary beyond the 1st level?)
13458 =''italic'' heading==
13459 ==''italic'' heading=
13461 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13463 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
13464 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
13465 <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>
13466 <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>
13470 <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>
13471 <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>
13472 <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>
13473 <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>
13478 HTML headers vs TOC (bug 23393)
13479 (__NOEDITSECTION__ for clearer output, doesn't matter here)
13491 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13493 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
13495 <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>
13496 <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>
13499 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
13501 <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>
13502 <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>
13508 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
13509 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
13510 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
13511 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
13512 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
13513 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
13518 Single-line or multiline-comments can follow headings
13520 parsoid=wt2html,wt2wt
13528 <h2><span class="mw-headline" id="foo">foo</span></h2>
13529 <h2><span class="mw-headline" id="bar">bar</span></h2>
13530 <h2><span class="mw-headline" id="baz">baz</span></h2>
13535 BUG 1219 URL next to image (broken)
13537 http://example.com[[Image:foobar.jpg]]
13539 <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>
13544 Bug 1186 news: in the middle of text
13546 http://en.wikinews.org/wiki/Wikinews:Workplace
13548 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
13554 Namespaced link must have a title
13563 Namespaced link must have a title (bad fragment version)
13565 [[Project:#fragment]]
13567 <p>[[Project:#fragment]]
13573 ### HTML tags and HTML attributes
13577 div with no attributes
13579 <div>HTML rocks</div>
13581 <div>HTML rocks</div>
13586 div with double-quoted attribute
13588 <div id="rock">HTML rocks</div>
13590 <div id="rock">HTML rocks</div>
13595 div with single-quoted attribute
13597 <div id='rock'>HTML rocks</div>
13599 <div id="rock">HTML rocks</div>
13604 div with unquoted attribute
13606 <div id=rock>HTML rocks</div>
13608 <div id="rock">HTML rocks</div>
13613 div with illegal double attributes
13615 <div id="a" id="b">HTML rocks</div>
13617 <div id="b">HTML rocks</div>
13621 # FIXME: produce empty string instead of "class" in the PHP parser, following
13624 div with empty attribute value, space before equals
13628 <div class =>HTML rocks</div>
13630 <div class="">HTML rocks</div>
13635 div with multiple empty attribute values
13639 <div id= title=>HTML rocks</div>
13641 <div id="" title="">HTML rocks</div>
13646 table with multiple empty attribute values
13654 <table title="" id="">
13655 <tbody><tr><td> hi</td></tr>
13660 div with braces in attribute value
13662 <div title="{}">Foo</div>
13664 <div title="{}">Foo</div>
13667 <div title="{}">Foo</div>
13670 # This it very inconsistent in the PHP parser: it returns
13671 # class="class" if there is a space between the name and the equal sign (see
13672 # 'div with empty attribute value, space before equals'), but strips the
13673 # attribute completely if the space is missing. We hope that not much content
13674 # depends on this, so are implementing the behavior below in Parsoid for
13675 # consistencies' sake.
13676 # FIXME: fix this behavior in the PHP parser?
13678 div with empty attribute value, no space before equals
13680 parsoid=wt2html,html2html
13682 <div class=>HTML rocks</div>
13684 <div>HTML rocks</div>
13687 <div class="">HTML rocks</div>
13691 HTML multiple attributes correction
13693 <p class="error" class="awesome">Awesome!</p>
13695 <p class="awesome">Awesome!</p>
13700 Table multiple attributes correction
13703 !+ class="error" class="awesome"| status
13708 <th class="awesome"> status
13716 <DIV ID="x">HTML ROCKS</DIV>
13718 <div id="x">HTML ROCKS</div>
13723 Non-ASCII pseudo-tags are rendered as text
13732 Pseudo-tag with URL 'name' renders as url link
13734 <http://example.com/>
13736 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
13741 text with amp in the middle of nowhere
13745 <p>Remember AT&T?
13750 text with character entity: eacute
13752 I always thought é was a cute letter.
13754 <p>I always thought é was a cute letter.
13757 <p>I always thought é was a cute letter.</p>
13761 text with entity-escaped character entity-like string: eacute
13763 I always thought &eacute; was a cute letter.
13765 <p>I always thought &eacute; was a cute letter.
13770 text with undefined character entity: xacute
13772 I always thought &xacute; was a cute letter.
13774 <p>I always thought &xacute; was a cute letter.
13778 # TODO: generalize to PHP parser?
13784 <data value="5">five</data>
13785 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
13786 <mark>This highlighted text</mark>
13788 <p><data value="5">five</data>
13789 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
13790 <mark>This highlighted text</mark></p>
13794 HTML tag with leading space is parsed as text
13798 <p>< div>foo< /div>
13803 ### Nesting tests (see bug 41545, 50604, 51081)
13806 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
13807 # Note that html2wt is considerably more difficult if we use <b> in
13808 # the test case, instead of <big>
13810 Ensure that HTML adoption agency algorithm is properly implemented.
13812 <big>X<big>Y</big>Z</big>
13814 <p><big>X<big>Y</big>Z</big>
13818 # This was bug 41545 in the PHP parser.
13819 # Note that tidy doesn't handle this correctly.
13823 <kbd>X<kbd>Y</kbd>Z</kbd>
13825 <p><kbd>X<kbd>Y</kbd>Z</kbd>
13829 # The following cases were bug 51081 in the PHP parser.
13830 # Note that there are some other nestable tags (b, i, etc) which are
13831 # not covered; see bug 51081 for discussion.
13833 # Note that tidy doesn't handle this correctly.
13837 <em>X<em>Y</em>Z</em>
13839 <p><em>X<em>Y</em>Z</em>
13843 # Note that tidy doesn't handle this correctly.
13845 Nesting of <strong>
13847 <strong>X<strong>Y</strong>Z</strong>
13849 <p><strong>X<strong>Y</strong>Z</strong>
13858 <p><q>X<q>Y</q>Z</q></p>
13861 # Note that tidy doesn't handle this correctly.
13865 <ruby>X<ruby>Y</ruby>Z</ruby>
13867 <p><ruby>X<ruby>Y</ruby>Z</ruby>
13871 # Note that tidy doesn't handle this correctly.
13875 <bdo>X<bdo>Y</bdo>Z</bdo>
13877 <p><bdo>X<bdo>Y</bdo>Z</bdo>
13889 [[Media:Foobar.jpg]]
13891 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
13896 Media link with text
13898 [[Media:Foobar.jpg|A neat file to look at]]
13900 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
13904 # FIXME: this is still bad HTML tag nesting
13906 Media link with nasty text
13907 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
13909 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
13911 <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>
13914 <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>
13918 Media link to nonexistent file (bug 1702)
13920 [[Media:No such.jpg]]
13922 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
13927 Image link to nonexistent file (bug 1850 - good)
13929 [[File:No_such.jpg]]
13931 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
13934 <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>
13938 :Image link to nonexistent file (bug 1850 - bad)
13940 [[:Image:No such.jpg]]
13942 <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>
13945 <p><a rel="mw:WikiLink" href="./File:No_such.jpg" title="File:No such.jpg">Image:No such.jpg</a></p>
13951 Character reference normalization in link text (bug 1938)
13953 [[Main Page|this&that]]
13955 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
13962 Test for unicode normalization
13964 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
13968 (bug 19451) Links should refer to the normalized form.
13976 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13977 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13978 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13979 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13980 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
13985 Empty attribute crash test (bug 2067)
13987 <font color="">foo</font>
13989 <p><font color="">foo</font>
13994 Empty attribute crash test single-quotes (bug 2067)
13996 <font color=''>foo</font>
13998 <p><font color="">foo</font>
14003 Attribute test: equals, then nothing
14005 <font color=>foo</font>
14007 <p><font>foo</font>
14012 Attribute test: unquoted value
14014 <font color=x>foo</font>
14016 <p><font color="x">foo</font>
14021 Attribute test: unquoted but illegal value (hash)
14023 <font color=#x>foo</font>
14025 <p><font color="#x">foo</font>
14030 Attribute test: no value
14032 <font color>foo</font>
14034 <p><font color="color">foo</font>
14039 Bug 2095: link with three closing brackets
14043 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
14046 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a>]</p>
14050 Bug 2095: link with pipe and three closing brackets
14052 [[Main Page|link]]]
14054 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
14057 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">link</a>]</p>
14061 Bug 2095: link with pipe and three closing brackets, version 2
14063 [[Main Page|[http://example.com/]]]
14065 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
14068 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">[http://example.com/]</a></p>
14077 Template:Dangerous attribute
14079 " onmouseover="alert(document.cookie)
14083 Template:Dangerous style attribute
14085 border-size: expression(alert(document.cookie))
14091 <div style="float: right; {{{1}}}">Magic div</div>
14095 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
14097 <div title="{{test}}"></div>
14099 <div title="This is a test template"></div>
14103 # Parsoid has enough context to handle this case
14105 Bug 2304: HTML attribute safety (dangerous template; 2309)
14107 <div title="{{dangerous attribute}}"></div>
14109 <div title=""></div>
14112 <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>
14116 Bug 2304: HTML attribute safety (dangerous style template; 2309)
14118 <div style="{{dangerous style attribute}}"></div>
14120 <div style="/* insecure input */"></div>
14125 Bug 2304: HTML attribute safety (safe parameter; 2309)
14127 {{div style|width: 200px}}
14129 <div style="float: right; width: 200px">Magic div</div>
14134 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
14136 {{div style|width: expression(alert(document.cookie))}}
14138 <div style="/* insecure input */">Magic div</div>
14143 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
14145 {{div style|"><script>alert(document.cookie)</script>}}
14147 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
14152 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
14154 {{div style|" ><script>alert(document.cookie)</script>}}
14156 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
14161 Bug 2304: HTML attribute safety (link)
14163 <div title="[[Main Page]]"></div>
14165 <div title="[[Main Page]]"></div>
14170 Bug 2304: HTML attribute safety (italics)
14172 <div title="''foobar''"></div>
14174 <div title="''foobar''"></div>
14179 Bug 2304: HTML attribute safety (bold)
14181 <div title="'''foobar'''"></div>
14183 <div title="'''foobar'''"></div>
14189 Bug 2304: HTML attribute safety (ISBN)
14191 <div title="ISBN 1234567890"></div>
14193 <div title="ISBN 1234567890"></div>
14198 Bug 2304: HTML attribute safety (RFC)
14200 <div title="RFC 1234"></div>
14202 <div title="RFC 1234"></div>
14207 Bug 2304: HTML attribute safety (PMID)
14209 <div title="PMID 1234567890"></div>
14211 <div title="PMID 1234567890"></div>
14216 Bug 2304: HTML attribute safety (web link)
14218 <div title="http://example.com/"></div>
14220 <div title="http://example.com/"></div>
14225 Bug 2304: HTML attribute safety (named web link)
14227 <div title="[http://example.com/ link]"></div>
14229 <div title="[http://example.com/ link]"></div>
14234 Bug 3244: HTML attribute safety (extension; safe)
14236 <div style="<nowiki>background:blue</nowiki>"></div>
14238 <div style="background:blue"></div>
14243 Bug 3244: HTML attribute safety (extension; unsafe)
14245 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
14247 <div style="/* insecure input */"></div>
14251 # More MSIE fun discovered by Tom Gilder
14254 MSIE CSS safety test: spurious slash
14256 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
14258 <div style="/* insecure input */">evil</div>
14263 MSIE CSS safety test: hex code
14265 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
14267 <div style="/* insecure input */">evil</div>
14272 MSIE CSS safety test: comment in url
14274 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
14276 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
14281 MSIE CSS safety test: comment in expression
14283 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
14285 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
14290 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
14292 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
14294 <p style="/* invalid control char */">A</p>
14299 MSIE 6 CSS safety test: Fullwidth (bug 55332)
14301 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
14302 <div style="top:EXPRESSION(alert())">B</div>
14304 <p style="/* insecure input */">A</p>
14305 <div style="/* insecure input */">B</div>
14310 MSIE 6 CSS safety test: IPA extensions (bug 55332)
14312 <div style="background-image:uʀʟ(javascript:alert())">A</div>
14313 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
14315 <div style="/* insecure input */">A</div>
14316 <p style="/* insecure input */">B</p>
14321 MSIE 6 CSS safety test: sup/sub script (bug 55332)
14323 <div style="background-image:url⁽javascript:alert())">A</div>
14324 <div style="background-image:url₍javascript:alert())">B</div>
14325 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
14327 <div style="/* insecure input */">A</div>
14328 <div style="/* insecure input */">B</div>
14329 <p style="/* insecure input */">C</p>
14337 title="data:text/html,<img src=1 onerror=alert(1)>"
14338 style="-o-link:attr(title);-o-link-source:current">X</div>
14340 <div title="data:text/html,<img src=1 onerror=alert(1)>" style="/* insecure input */">X</div>
14345 MSIE 6 CSS safety test: Repetition markers (bug 55332)
14347 <p style="font-size: 100px; color: expres〱ion((title='XSSed'),'red')">A</p>
14348 <p style="font-size: 100px; color: expresゝion((title='XSSed'),'red')">B</p>
14349 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">C</p>
14350 <p style="font-size: 100px; color: expresヽion((title='XSSed'),'red')">D</p>
14351 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
14352 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
14353 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
14355 <p style="/* insecure input */">A</p>
14356 <p style="/* insecure input */">B</p>
14357 <p style="/* insecure input */">C</p>
14358 <p style="/* insecure input */">D</p>
14359 <p style="/* insecure input */">E</p>
14360 <p style="/* insecure input */">F</p>
14361 <p style="/* insecure input */">G</p>
14366 Table attribute legitimate extension
14369 !+ style="<nowiki>color:blue</nowiki>"| status
14374 <th style="color:blue"> status
14380 Table attribute safety
14383 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
14388 <th style="/* insecure input */"> status
14394 CSS line continuation 1
14396 <div style="background-image: u\ rl(test.jpg);"></div>
14398 <div style="/* insecure input */"></div>
14403 CSS line continuation 2
14405 <div style="background-image: u\ rl(test.jpg); "></div>
14407 <div style="/* insecure input */"></div>
14418 Expansion of multi-line templates in attribute values (bug 6255)
14420 <div style="background: {{identity|#00FF00}}">-</div>
14422 <div style="background: #00FF00">-</div>
14428 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
14430 <div style="background:
14433 <div style="background: #00FF00">-</div>
14436 <div style="background:
14441 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
14443 <div style="background: #00FF00">-</div>
14445 <div style="background: #00FF00">-</div>
14450 evil <math>-wiki-tags without Extension:Math enabled
14452 <math><img src="some evil external link"><script>some_evil_javascript();</script></math>
14454 <p><math><img src="some evil external link"><script>some_evil_javascript();</script></math></p>
14458 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
14461 Parser hook: empty input
14474 Parser hook: empty input using terminated empty elements
14487 Parser hook: empty input using terminated empty elements (space before)
14500 Parser hook: basic input
14514 Parser hook: case insensitive
14528 Parser hook: case insensitive, redux
14541 Parser hook: nested tags
14545 <tag><tag></tag></tag>
14556 Parser hook: basic arguments
14558 <tag width=200 height = "100" depth = '50' square></tag>
14566 'square' => 'square',
14573 Parser hook: argument containing a forward slash (bug 5344)
14575 <tag filename='/tmp/bla'></tag>
14580 'filename' => '/tmp/bla',
14587 Parser hook: empty input using terminated empty elements (bug 2374)
14600 # </tag> should be output literally since there is no matching tag that begins it
14602 Parser hook: basic arguments using terminated empty elements (bug 2374)
14604 <tag width=200 height = "100" depth = '50' square/>
14614 'square' => 'square',
14623 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
14627 Parser hook: static parser hook not inside a comment
14629 <statictag>hello, world</statictag>
14630 <statictag action=flush/>
14638 Parser hook: static parser hook inside a comment
14640 <!-- <statictag>hello, world</statictag> -->
14641 <statictag action=flush/>
14647 # Nested template calls; this case was broken by Parser.php rev 1.506,
14651 Template:One-parameter
14653 (My parameter is: {{{1}}})
14657 Template:Map-one-parameter
14659 {{{{{1}}}|{{{2}}}}}
14663 Nested template calls
14665 {{Map-one-parameter|One-parameter|param}}
14667 <p>(My parameter is: param)
14676 # HTML+Tidy effectively strips out the empty tags completely
14677 # But since Parsoid doesn't it wraps the <s></s> tags in p-tags
14678 # which Tidy would have done for the PHP parser had there been content inside it.
14680 Sanitizer: Closing of open tags
14682 <s></s><table></table>
14684 <s></s><table></table>
14687 <p><s></s></p><table></table>
14691 Sanitizer: Closing of open but not closed tags
14700 Sanitizer: Closing of closed but not open tags
14709 Sanitizer: Closing of closed but not open table tags
14711 Table not started</td></tr></table>
14713 <p>Table not started</td></tr></table>
14718 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
14720 <span id="æ: v">byte</span>[[#æ: v|backlink]]
14722 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
14726 # In HTML5, the restrictions are that id must contain at least one character,
14727 # and must not contain any space characters.
14729 Sanitizer: Validating the contents of the id attribute (bug 4515)
14733 <br id="" /><br id="a space" />
14738 # In HTML5, id must be unique amongst all the ids in the element's home subtree.
14740 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
14744 <br id="foo" /><br id="foo" />
14746 Something need to be done. foo-2 ?
14750 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
14753 <meta itemprop="hello" content="world">
14754 <meta http-equiv="refresh" content="5">
14755 <meta itemprop="hello" http-equiv="refresh" content="5">
14756 <link itemprop="hello" href="{{SERVER}}">
14757 <link rel="stylesheet" href="{{SERVER}}">
14758 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
14761 <div itemscope="itemscope">
14762 <p> <meta itemprop="hello" content="world" />
14763 <meta http-equiv="refresh" content="5">
14764 <meta itemprop="hello" content="5" />
14766 <link itemprop="hello" href="http://example.org" />
14767 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
14768 <link itemprop="hello" href="http://example.org" />
14774 Language converter: output gets cut off unexpectedly (bug 5757)
14778 this bit is safe: }-
14780 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
14782 then we get cut off here: }-
14784 all additional text is vanished
14786 <p>this bit is safe: }-
14787 </p><p>but if we add a conversion instance: xxx
14788 </p><p>then we get cut off here: }-
14789 </p><p>all additional text is vanished
14794 Self closed html pairs (bug 5487)
14797 <center><font id="bug" />Centered text</center>
14798 <div><font id="bug2" />In div text</div>
14800 <center><font id="bug" />Centered text</center>
14801 <div><font id="bug2" />In div text</div>
14810 Punctuation: nbsp before exclamation
14814 <p>C'est grave !
14819 Punctuation: CSS !important (bug 11874)
14821 <div style="width:50% !important">important</div>
14823 <div style="width:50% !important">important</div>
14828 Punctuation: CSS ! important (bug 11874; with space after)
14830 <div style="width:50% ! important">important</div>
14832 <div style="width:50% ! important">important</div>
14838 HTML bullet list, closed tags (bug 5497)
14851 <ul data-parsoid='{"stx":"html"}'>
14852 <li data-parsoid='{"stx":"html"}'>One</li>
14853 <li data-parsoid='{"stx":"html"}'>Two</li>
14859 HTML bullet list, unclosed tags (bug 5497)
14871 <ul data-parsoid='{"stx":"html"}'>
14872 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>One</li>
14873 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>Two</li>
14879 HTML ordered list, closed tags (bug 5497)
14892 <ol data-parsoid='{"stx":"html"}'>
14893 <li data-parsoid='{"stx":"html"}'>One</li>
14894 <li data-parsoid='{"stx":"html"}'>Two</li>
14900 HTML ordered list, unclosed tags (bug 5497)
14913 <ol data-parsoid='{"stx":"html"}'>
14914 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>One</li>
14915 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>Two</li>
14921 HTML nested bullet list, closed tags (bug 5497)
14946 HTML nested bullet list, open tags (bug 5497)
14983 HTML nested ordered list, closed tags (bug 5497)
15008 HTML nested ordered list, open tags (bug 5497)
15045 HTML ordered list item with parameters oddity
15047 <ol><li id="fragment">One</li>
15050 <ol><li id="fragment">One</li>
15055 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
15057 bug 5918: autonumbering
15059 [http://first/] [http://second] [ftp://ftp]
15063 [mailto:enclosed@mail.tld With target]
15065 [mailto:enclosed@mail.tld]
15067 mailto:inline@mail.tld
15069 <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>
15070 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
15071 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
15072 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
15073 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
15076 <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>
15077 <p><a rel="mw:ExtLink" href="ftp://inlineftp">ftp://inlineftp</a></p>
15078 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld">With target</a></p>
15079 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld"></a></p>
15080 <p><a rel="mw:ExtLink" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a></p>
15085 # Security and HTML correctness
15086 # From Nick Jenkins' fuzz testing
15090 Fuzz testing: Parser13
15105 Fuzz testing: Parser14
15110 <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 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15113 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
15119 <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>
15121 <div id="toc" class="toc">
15122 <div id="toctitle">
15126 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
15132 Fuzz testing: Parser14-table
15137 <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>
15138 <table style="__TOC__">
15143 <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>
15144 <table style="__TOC__">
15151 # Known to produce bogus xml (extra </td>)
15153 Fuzz testing: Parser16
15182 Fuzz testing: Parser21
15185 ! irc://{{ftp://a" onmouseover="alert('hello world');"
15190 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
15200 Fuzz testing: Parser22
15202 http://===r:::https://b
15206 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
15214 # Known to produce bad XML for now
15216 Fuzz testing: Parser24
15223 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
15224 <br style="onmouseover='alert(document.cookie);' " />
15226 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
15231 <u class="|">}}}} >
15232 <br style="onmouseover='alert(document.cookie);'" />
15234 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
15243 # Note: the current result listed for this is not what the original one was,
15244 # but the original bug was JavaScript injection, which is fixed in any case.
15245 # It's not clear that the original result listed was any more correct than the
15246 # current one. Original result:
15249 # <li class="||">
15250 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
15252 Fuzz testing: Parser25 (bug 6055)
15258 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
15260 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
15265 Fuzz testing: URL adjacent extension (with space, clean)
15267 http://example.com <nowiki>junk</nowiki>
15269 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
15274 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
15276 http://example.com<nowiki>junk</nowiki>
15278 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
15283 Fuzz testing: URL adjacent extension (no space, dirty; pre)
15285 http://example.com<pre>junk</pre>
15287 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
15290 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></p>
15297 Fuzz testing: image with bogus manual thumbnail
15299 [[Image:foobar.jpg|thumbnail= ]]
15301 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
15304 <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>
15308 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
15310 <pre dir=" "></pre>
15312 <pre dir=" "></pre>
15317 Parsing optional HTML elements (Bug 6171)
15322 <td> Some tabular data</td>
15323 <td> More tabular data ...
15324 <td> And yet som tabular data</td>
15330 <td> Some tabular data</td>
15331 <td> More tabular data ...
15332 </td><td> And yet som tabular data</td>
15339 Correct handling of <td>, <tr> (Bug 6171)
15344 <td> Some tabular data</td>
15345 <td> More tabular data ...</td>
15346 <td> And yet som tabular data</td>
15352 <td> Some tabular data</td>
15353 <td> More tabular data ...</td>
15354 <td> And yet som tabular data</td>
15362 Parsing crashing regression (fr:JavaScript)
15366 <p></body></x>
15371 Inline wiki vs wiki block nesting
15377 <p><b>Bold paragraph</b>
15378 </p><p>New wiki paragraph
15382 # FIXME: The current php output is documented
15383 # and desired output is the parsoid target.
15385 Inline HTML vs wiki block nesting
15391 <p><b>Bold paragraph
15392 </p><p>New wiki paragraph</b>
15395 <p><b>Bold paragraph</b>
15396 </p><p>New wiki paragraph
15400 # Original result was this:
15401 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
15403 # While that might be marginally more intuitive, maybe, the six-apostrophe
15404 # construct is clearly pathological and the result stated here (which is what
15405 # the parser actually does) is about as reasonable as anything.
15407 Mixing markup for italics and bold
15410 '''bold''''''bold''bolditalics'''''
15412 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
15420 Article for special page transclusion test
15424 Special page transclusion
15427 {{Special:Prefixindex/Xyzzyx}}
15429 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
15434 Special page transclusion twice (bug 5021)
15437 {{Special:Prefixindex/Xyzzyx}}
15438 {{Special:Prefixindex/Xyzzyx}}
15440 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
15441 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
15446 Transclusion of default MediaWiki message
15448 {{MediaWiki:Mainpage}}
15455 Transclusion of nonexistent MediaWiki message
15457 {{MediaWiki:Mainpagexxx}}
15459 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
15464 Transclusion of MediaWiki message with underscore
15466 {{MediaWiki:history_short}}
15473 Transclusion of MediaWiki message with space
15475 {{MediaWiki:history short}}
15482 Invalid header with following text
15492 Section extraction test (section 0)
15512 Section extraction test (section 1)
15534 Section extraction test (section 2)
15555 Section extraction test (section 3)
15575 Section extraction test (section 4)
15599 Section extraction test (section 5)
15619 Section extraction test (section 6)
15640 Section extraction test (section 7)
15660 Section extraction test (section 8)
15680 Section extraction test (section 9)
15701 Section extraction test (section 10)
15721 Section extraction test (nonexistent section 11)
15740 Section extraction test with bogus heading (section 1)
15745 ==bogus== not a legal section
15749 ==bogus== not a legal section
15753 Section extraction test with bogus heading (section 2)
15758 ==bogus== not a legal section
15765 Section extraction test with comment after heading (section 1)
15777 Section extraction test with comment after heading (section 2)
15789 Section extraction test with bogus <nowiki> heading (section 1)
15794 ==bogus== <nowiki>not a legal section</nowiki>
15798 ==bogus== <nowiki>not a legal section</nowiki>
15802 Section extraction test with bogus <nowiki> heading (section 2)
15807 ==bogus== <nowiki>not a legal section</nowiki>
15814 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
15815 # instead of respecting commented sections
15817 Section extraction prefixed by comment (section 1)
15828 Section extraction prefixed by comment (section 2)
15839 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
15840 # instead of respecting HTML-style headings
15842 Section extraction, mixed wiki and html (section 1)
15858 Section extraction, mixed wiki and html (section 2)
15874 # Formerly testing for bug 3342
15876 Section extraction, heading surrounded by <noinclude>
15880 <noinclude>==unmarked==</noinclude>
15886 # Test behavior of bug 19910
15888 Sectiion with all-equals
15893 The line above must have a trailing space
15896 But just in case it doesn't...
15900 But just in case it doesn't...
15904 Section replacement test (section 0)
15935 Section replacement test (section 1)
15964 Section replacement test (section 2)
15994 Section replacement test (section 3)
16025 Section replacement test (section 4)
16052 Section replacement test (section 5)
16083 Section replacement test (section 6)
16113 Section replacement test (section 7)
16144 Section replacement test (section 8)
16175 Section replacement test (section 9)
16204 Section replacement test (section 10)
16234 Section replacement test with initial whitespace (bug 13728)
16238 Preformatted initial line
16242 Preformatted initial line
16249 Section extraction, heading followed by pre with 20 spaces (bug 6398)
16261 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
16274 Section extraction, <pre> around bogus header (bug 10309)
16291 Section replacement, <pre> around bogus header (bug 10309)
16293 noxml replace=2,"xxx"
16314 Handling of 
 in URLs
16318 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
16321 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://
16323 a</a></li></ul></li></ul>
16327 Handling of %0A in URLs
16331 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
16334 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
16338 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
16340 5 quotes, code coverage +1 line
16347 <p><b><i></i></b></p>
16350 # same html as previous, but wikitext adjusted to match parsoid html2wt
16351 # note that wt2html and html2html will put the <i> before the <b>
16353 5 quotes, code coverage +1 line w/ nowiki (1)
16355 parsoid=wt2wt,html2wt
16357 '''''<nowiki/>'''''
16362 <p><b><i></i></b></p>
16365 # same as previous, just swapping the <i> and <b>
16367 5 quotes, code coverage +1 line w/ nowiki (2)
16369 '''''<nowiki/>'''''
16374 <p><i><b></b></i></p>
16378 Special:Search page linking.
16382 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
16387 {{!}} is a magic word
16389 {{!}} is a magic word there and {{!}} is still a magic word here
16391 <p>| is a magic word there and | is still a magic word here
16394 <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>
16400 title=[[Parser test]]
16405 * {{FULLPAGENAMEE}}
16407 * {{BASEPAGENAMEE}}
16411 * {{ROOTPAGENAMEE}}
16413 * {{TALKPAGENAMEE}}
16414 * {{SUBJECTPAGENAME}}
16415 * {{SUBJECTPAGENAMEE}}
16418 * {{NAMESPACENUMBER}}
16422 * {{SUBJECTSPACEE}}
16423 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
16425 <ul><li> Parser test</li>
16426 <li> Parser_test</li>
16427 <li> Parser test</li>
16428 <li> Parser_test</li>
16429 <li> Parser test</li>
16430 <li> Parser_test</li>
16431 <li> Parser test</li>
16432 <li> Parser_test</li>
16433 <li> Parser test</li>
16434 <li> Parser_test</li>
16435 <li> Talk:Parser test</li>
16436 <li> Talk:Parser_test</li>
16437 <li> Parser test</li>
16438 <li> Parser_test</li>
16446 <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>
16449 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
16459 image4 |300px| centre
16460 image5.svg| http://///////
16465 <ul class="gallery mw-gallery-traditional">
16466 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16467 <div class="thumb" style="height: 150px;">Image1.png</div>
16468 <div class="gallerytext">
16471 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16472 <div class="thumb" style="height: 150px;">Image2.gif</div>
16473 <div class="gallerytext">
16478 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16479 <div class="thumb" style="height: 150px;">Image3</div>
16480 <div class="gallerytext">
16483 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16484 <div class="thumb" style="height: 150px;">Image4</div>
16485 <div class="gallerytext">
16490 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16491 <div class="thumb" style="height: 150px;">Image5.svg</div>
16492 <div class="gallerytext">
16493 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
16497 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16498 <div class="thumb" style="height: 150px;">* image6</div>
16499 <div class="gallerytext">
16507 Gallery (with options)
16509 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
16510 File:Nonexistent.jpg|caption
16511 File:Nonexistent.jpg
16512 image:foobar.jpg|some '''caption''' [[Main Page]]
16514 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
16517 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
16518 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
16519 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16520 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
16521 <div class="gallerytext">
16526 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16527 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
16528 <div class="gallerytext">
16531 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16532 <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>
16533 <div class="gallerytext">
16534 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
16538 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16539 <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>
16540 <div class="gallerytext">
16543 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
16544 <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>
16545 <div class="gallerytext">
16555 Gallery with link that has fragment
16558 image:foobar.jpg|link=Main_Page
16559 image:foobar.jpg|link=Main_Page#section
16560 image:foobar.jpg|link=Main Page#section|caption
16563 <ul class="gallery mw-gallery-traditional">
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"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
16566 <div class="gallerytext">
16569 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16570 <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>
16571 <div class="gallerytext">
16574 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16575 <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>
16576 <div class="gallerytext">
16586 Gallery with wikitext inside caption
16589 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
16590 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
16593 <ul class="gallery mw-gallery-traditional">
16594 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16595 <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>
16596 <div class="gallerytext">
16597 <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>
16601 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16602 <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>
16603 <div class="gallerytext">
16604 <p>This is a test template
16613 gallery (with showfilename option)
16615 <gallery showfilename>
16616 File:Nonexistent.jpg|caption
16617 File:Nonexistent.jpg
16618 image:foobar.jpg|some '''caption''' [[Main Page]]
16622 <ul class="gallery mw-gallery-traditional">
16623 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16624 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16625 <div class="gallerytext">
16626 <p><a href="/wiki/File:Nonexistent.jpg" title="File:Nonexistent.jpg">Nonexistent.jpg</a><br />
16631 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16632 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16633 <div class="gallerytext">
16634 <p><a href="/wiki/File:Nonexistent.jpg" title="File:Nonexistent.jpg">Nonexistent.jpg</a><br />
16638 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16639 <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>
16640 <div class="gallerytext">
16641 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
16642 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
16646 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16647 <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>
16648 <div class="gallerytext">
16649 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
16658 Gallery (with namespace-less filenames)
16661 File:Nonexistent.jpg
16667 <ul class="gallery mw-gallery-traditional">
16668 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16669 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16670 <div class="gallerytext">
16673 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16674 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
16675 <div class="gallerytext">
16678 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16679 <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>
16680 <div class="gallerytext">
16683 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
16684 <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>
16685 <div class="gallerytext">
16693 HTML Hex character encoding (spells the word "JavaScript")
16695 parsoid=wt2html,wt2wt,html2html
16697 JavaScript
16699 <p>JavaScript
16704 <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>
16708 HTML Hex character encoding bogus encoding (bug 26437 regression check)
16712 <p>&#xsee;&#XSEE;
16715 <p>&#xsee;&#XSEE;</p>
16719 HTML Hex character encoding mixed case
16721 parsoid=wt2html,wt2wt,html2html
16730 <p><span typeof="mw:Entity">î</span><span typeof="mw:Entity">î</span></p>
16734 __FORCETOC__ override
16746 ISBN 978-0-1234-56 789
16748 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
16751 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789</p>
16755 ISBN followed by 5 spaces
16766 ISBN ISBN 1234567890
16768 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
16777 <p><a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-X</a>
16782 ISBN with empty prefix (parsoid test)
16786 <p><a href="Special:BookSources/1234567890" rel="mw:ExtLink">ISBN 1234567890</a></p>
16790 Bug 22905: <abbr> followed by ISBN followed by </a>
16792 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
16794 <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>
16803 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
16808 Double RFC with a wiki link
16812 <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>
16821 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
16824 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987</p>
16828 Centre-aligned image
16830 [[Image:foobar.jpg|centre]]
16832 <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>
16839 [[Image:foobar.jpg|none]]
16841 <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>
16846 Width + Height sized image (using px) (height is ignored)
16848 [[Image:foobar.jpg|640x480px]]
16850 <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>
16855 Width-sized image (using px, no following whitespace)
16857 [[Image:foobar.jpg|640px]]
16859 <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>
16864 Width-sized image (using px, with following whitespace - test regression from r39467)
16866 [[Image:foobar.jpg|640px ]]
16868 <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>
16873 Width-sized image (using px, with preceding whitespace - test regression from r39467)
16875 [[Image:foobar.jpg| 640px]]
16877 <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>
16882 Image with page parameter
16886 [[File:LoremIpsum.djvu|page=2]]
16888 <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>
16891 <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>
16895 Another italics / bold test
16903 # FIXME: The php output seems broken. It's interleaving some open/close tags.
16909 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd></dt></dl></dd></dl></dd></dl></dd></dl></dd></dl></dd></dl>
16912 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd></dd></dl></dd></dl></dt></dl></dt></dl></dt></dl></dd></dl>
16917 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
16919 Images with the "|" character in the comment
16921 [[File:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
16923 <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>
16926 <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>
16930 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
16932 <html><script>alert(1);</script></html>
16934 <p><html><script>alert(1);</script></html>
16939 HTML with raw HTML ($wgRawHtml==true)
16943 <html><script>alert(1);</script></html>
16945 <p><script>alert(1);</script>
16950 Parents of subpages, one level up
16952 subpage title=[[Subpage test/L1/L2/L3]]
16956 <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>
16962 Parents of subpages, one level up, not named
16964 subpage title=[[Subpage test/L1/L2/L3]]
16968 <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>
16975 Parents of subpages, two levels up
16977 subpage title=[[Subpage test/L1/L2/L3]]
16983 <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
16984 </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>
16989 Parents of subpages, two levels up, without trailing slash or name.
16991 subpage title=[[Subpage test/L1/L2/L3]]
17000 Parents of subpages, two levels up, with lots of extra trailing slashes.
17002 subpage title=[[Subpage test/L1/L2/L3]]
17006 <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>
17011 Subpage test/L1/L2/L3Sibling
17017 Transclusion of a sibling page (one level up)
17019 subpage title=[[Subpage test/L1/L2/L3]]
17028 Transclusion of a child page
17030 subpage title=[[Subpage test/L1/L2]]
17039 Non-transclusion because of too many up levels
17041 subpage title=[[Subpage test/L1/L2/L3]]
17043 {{../../../../More than parent}}
17045 <p>{{../../../../More than parent}}
17050 Definition list code coverage
17056 <dl><dt> title  </dt>
17058 <dt> title </dt>
17064 <dl><dt> title <span typeof="mw:Placeholder"> </span></dt><dd> def</dd>
17065 <dt> title<span typeof="mw:Placeholder"> </span></dt><dd> def</dd>
17066 <dt>title</dt><dd> def</dd></dl>
17070 Don't fall for the self-closing div
17072 <div>hello world</div/>
17074 <div>hello world</div>
17083 <p>[[:Template:Msg]]
17092 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
17096 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
17098 Always escape literal '>' in output, not just after '<'
17112 <p>This is a test template
17113 This is a test template
17125 Inclusion of !userCanEdit() content
17129 <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>
17135 Out-of-order TOC heading levels
17144 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17146 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
17148 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
17149 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
17152 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
17154 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
17155 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
17161 <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>
17162 <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>
17163 <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>
17164 <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>
17165 <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>
17166 <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>
17172 ISBN with a dummy number
17182 ISBN with space-delimited number
17186 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
17192 ISBN with multiple spaces, no number
17211 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
17212 </p><p>ISBN 12345678901
17218 ISBN with trailing year (bug 8110)
17220 ISBN 1-234-56789-0 - 2006
17222 ISBN 1 234 56789 0 - 2006
17224 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
17225 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
17233 {{anchorencode:foo bar©#%n}}
17235 <p>foo_bar.C2.A9.23.25n
17240 anchorencode trims spaces
17242 {{anchorencode: __pretty__please__}}
17249 anchorencode deals with links
17251 {{anchorencode: [[hello|world]] [[hi]]}}
17258 anchorencode deals with templates
17260 {{anchorencode: {{Foo}} }}
17267 anchorencode encodes like the TOC generator: (bug 18431)
17269 === _ +:.3A%3A&&]] ===
17270 {{anchorencode: _ +:.3A%3A&&]] }}
17273 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
17274 <p>.2B:.3A.253A.26.26.5D.5D
17279 Bug 6200: blockquotes and paragraph formatting
17300 Bug 8293: Use of center tag ruins paragraph formatting
17321 Parsing of overlapping (improperly nested) inline html tags
17323 <span><s>x</span></s>
17325 <p><span><s>x</span></s></span>
17328 <p><span><s>x</s></span>
17333 ### Language variants related tests
17336 Self-link in language variants
17338 title=[[Dunav]] language=sr
17340 Both [[Dunav]] and [[Дунав]] are names for this river.
17342 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
17353 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
17355 title=[[Duna]] language=sr
17357 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
17359 <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.
17364 Link to a section of a variant of this title shouldn't be parsed as self-link
17366 title=[[Duna]] language=sr
17368 [[Dуна]] is a self-link while [[Dunа#Foo]] and [[Dуна#Foo]] are not self-links.
17370 <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.
17375 Link to pages in language variants
17379 Main Page can be written as [[Маин Паге]]
17381 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
17387 Multiple links to pages in language variants
17391 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
17393 <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>.
17399 Simple template in language variants
17405 <p>This is a test template
17411 Template with explicit namespace in language variants
17417 <p>This is a test template
17423 Basic test for template parameter in language variants
17427 {{парамтест|param=foo}}
17429 <p>This is a test template with parameter foo
17435 Simple category in language variants
17439 [[Category:МедиаWики Усер'с Гуиде]]
17441 <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>
17458 Don't convert blue categorylinks to another variant (bug 33210)
17462 [[A]][[Category:分类]]
17464 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
17469 Stripping -{}- tags (language variants)
17473 Latin proverb: -{Ne nuntium necare}-
17475 <p>Latin proverb: Ne nuntium necare
17481 Prevent conversion with -{}- tags (language variants)
17483 language=sr variant=sr-ec
17485 Latinski: -{Ne nuntium necare}-
17487 <p>Латински: Ne nuntium necare
17493 Prevent conversion of text with -{}- tags (language variants)
17495 language=sr variant=sr-ec
17497 Latinski: -{Ne nuntium necare}-
17499 <p>Латински: Ne nuntium necare
17505 Prevent conversion of links with -{}- tags (language variants)
17507 language=sr variant=sr-ec
17511 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
17517 -{}- tags within headlines (within html for parserConvert())
17519 language=sr variant=sr-ec
17523 <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>
17529 Explicit definition of language variant alternatives
17531 language=zh variant=zh-tw
17533 -{zh:China;zh-tw:Taiwan}-, not China
17535 <p>Taiwan, not China
17541 Conversion around HTML tags
17543 language=sr variant=sr-ec
17545 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
17546 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
17549 <span title="ЛаCтин">ски</span>
17555 Explicit session-wise language variant mapping (A flag and - flag)
17557 language=zh variant=zh-tw
17559 Taiwan is not China.
17560 But -{A|zh:China;zh-tw:Taiwan}- is China,
17561 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
17562 and -{China}- is China.
17564 <p>Taiwan is not China.
17565 But Taiwan is Taiwan,
17566 (This should be stripped!)
17567 and China is China.
17572 Explicit session-wise language variant mapping (H flag for hide)
17574 language=zh variant=zh-tw
17576 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
17579 <p>(This should be stripped!)
17585 Adding explicit conversion rule for title (T flag)
17587 language=zh variant=zh-tw showtitle
17589 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
17592 <p>Should be stripped!
17597 Testing that changing the language variant here in the tests actually works
17599 language=zh variant=zh showtitle
17601 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
17604 <p>Should be stripped!
17609 Recursive conversion of alt and title attrs shouldn't clear converter state
17611 language=zh variant=zh-cn showtitle
17613 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
17614 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
17618 Should be stripped<span title="Exclamation">!</span>
17623 Bug 24072: more test on conversion rule for title
17625 language=zh variant=zh-tw showtitle
17627 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
17628 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
17631 <p>This should be stripped!
17632 This won't take interferes with the title rule.
17637 Partly disable title conversion if variant == main language code
17639 language=zh variant=zh title=[[ZH]] showtitle
17641 -{T|zh-cn:CN;zh-tw:TW}-
17649 Partly disable title conversion if variant == main language code, more
17651 language=zh variant=zh title=[[ZH]] showtitle
17661 Raw output of variant escape tags (R flag)
17663 language=zh variant=zh-tw
17665 Raw: -{R|zh:China;zh-tw:Taiwan}-
17667 <p>Raw: zh:China;zh-tw:Taiwan
17672 Nested using of manual convert syntax
17674 language=zh variant=zh-hk
17676 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
17678 <p>Nested: Hello Hong Kong!
17683 Proper conversion of text in external links
17685 language=sr variant=sr-ec
17687 http://www.google.com
17688 gopher://www.google.com
17689 [http://www.google.com http://www.google.com]
17690 [gopher://www.google.com gopher://www.google.com]
17691 [https://www.google.com irc://www.google.com]
17692 [ftp://www.google.com www.google.com/ftp://dir]
17693 [//www.google.com www.google.com]
17695 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
17696 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
17697 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
17698 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
17699 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
17700 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
17701 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
17706 Do not convert roman numbers to language variants
17708 language=sr variant=sr-ec
17712 <p>Фридрих IV је цар.
17717 Unclosed language converter markup "-{"
17728 Don't convert raw rule "-{R|=>}-" to "=>"
17739 Don't break link parsing if language converter markup is in the caption.
17741 language=sr variant=sr-ec
17743 [[Main Page|-{R|main page}-]]
17745 <p><a href="/wiki/Main_Page" title="Маин Паге">main page</a>
17749 # FIXME: This test is currently broken in the PHP parser (bug 52661)
17751 Don't break image parsing if language converter markup is in the caption.
17755 [[File:Foobar.jpg|-{R|caption}-]]
17757 <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>
17761 # FIXME: This test is currently broken in the PHP parser (bug 52661)
17763 Don't break list handling if language converter markup is in the item.
17765 language=zh variant=zh-cn
17767 ;-{zh-cn:AAA;zh-tw:BBB}-
17769 <dl><dt><span class="error">在手动语言转换规则中检测到错误</span></dd></dl>
17776 # FIXME: This test is currently broken in the PHP parser (bug 52661)
17778 Don't break table handling if language converter markup is in the cell.
17780 language=sr variant=sr-ec
17803 Bug 529: Uncovered bullet
17812 # Plain MediaWiki does not remove empty lists, but tidy actually does.
17813 # Templates in Wikipedia rely on this behavior, as tidy has always been
17814 # enabled there. These tests are normally run *without* tidy, so specify the
17815 # full output here.
17816 # To test realistic parsing behavior, apply a tidy-like transformation to both
17817 # the expected output and your parser's output.
17819 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
17821 ******* Foo {{bullet}}
17823 <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>
17829 Bug 529: Uncovered table already at line-start
17852 Bug 529: Uncovered bullet in parser function result
17854 * Foo {{lc:{{bullet}} }}
17862 Bug 5678: Double-parsed template argument
17864 {{lc:{{{1}}}|hello}}
17871 Bug 5678: Double-parsed template invocation
17873 {{lc:{{paramtest {{!}} param = hello }} }}
17875 <p>{{paramtest | param = hello }}
17880 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
17883 title=[[Main Page]]
17885 {{PRVNÍVELKÉ:ěščř}}
17886 {{prvnívelké:ěščř}}
17906 Morwen/13: Unclosed link followed by heading
17913 <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>
17918 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
17925 <h1><span class="mw-headline" id="heading">heading</span></h1>
17930 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
17937 <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>
17952 Paragraphs inside divs (no extra line breaks)
17964 Paragraphs inside divs (extra line break on open)
17979 Paragraphs inside divs (extra line break on close)
17994 Paragraphs inside divs (extra line break on open and close)
18011 Nesting tags, paragraphs on lines which begin with <div>
18013 <div></div><strong>A
18016 <p><strong>A</strong></p>
18017 <p><strong>B</strong></p>
18025 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
18027 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
18029 <blockquote>Line one
18031 Line two</blockquote>
18033 <blockquote>Line one
18034 Line two</blockquote>
18038 <p>Line one Line two</p>
18043 Bug 6200: paragraphs inside blockquotes (extra line break on open)
18048 Line two</blockquote>
18053 Line two</blockquote>
18058 Line two</blockquote>
18062 Bug 6200: paragraphs inside blockquotes (extra line break on close)
18064 <blockquote>Line one
18069 <blockquote>Line one
18082 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
18104 Paragraphs inside blockquotes/divs (no extra line breaks)
18106 <blockquote><div>Line one
18108 Line two</div></blockquote>
18110 <blockquote><div>Line one
18111 Line two</div></blockquote>
18116 Paragraphs inside blockquotes/divs (extra line break on open)
18121 Line two</div></blockquote>
18126 Line two</div></blockquote>
18131 Paragraphs inside blockquotes/divs (extra line break on close)
18133 <blockquote><div>Line one
18136 </div></blockquote>
18138 <blockquote><div>Line one
18141 </div></blockquote>
18146 Paragraphs inside blockquotes/divs (extra line break on open and close)
18152 </div></blockquote>
18158 </div></blockquote>
18163 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
18165 wgLinkHolderBatchSize=0
18171 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
18172 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
18173 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
18178 Free external link invading image caption
18180 [[Image:Foobar.jpg|thumb|http://x|hello]]
18182 <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>
18187 Bug 15196: localised external link numbers
18191 [http://en.wikipedia.org/]
18193 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
18196 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/"></a></p>
18200 Multibyte character in padleft
18202 {{padleft:-Hello|7|Æ}}
18209 Multibyte character in padright
18211 {{padright:Hello-|7|Æ}}
18218 formatdate parser function
18220 {{#formatdate:2009-03-24}}
18222 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
18227 formatdate parser function, with default format
18229 {{#formatdate:2009-03-24|mdy}}
18231 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
18236 Spacing of numbers in formatted dates
18238 {{#formatdate:January 15}}
18240 <p><span class="mw-formatted-date" title="01-15">January 15</span>
18245 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
18247 language=nl title=[[MediaWiki:Common.css]]
18249 {{#formatdate:2009-03-24|dmy}}
18251 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
18264 Edit comment with link
18268 I like the [[Main Page]] a lot
18270 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
18274 Edit comment with link and link text
18278 I like the [[Main Page|best pages]] a lot
18280 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
18284 Edit comment with link and link text with suffix
18288 I like the [[Main Page|best page]]s a lot
18290 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
18294 Edit comment with section link (non-local, eg in history list)
18296 comment title=[[Main Page]]
18298 /* External links */ removed bogus entries
18300 <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 and text before it (non-local, eg in history list)
18306 comment title=[[Main Page]]
18308 pre-comment text /* External links */ removed bogus entries
18310 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>
18314 Edit comment with section link (local, eg in diff view)
18316 comment local title=[[Main Page]]
18318 /* External links */ removed bogus entries
18320 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
18324 Edit comment with subpage link (bug 14080)
18328 title=[[Subpage test]]
18330 Poked at a [[/subpage]] here...
18332 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
18336 Edit comment with subpage link and link text (bug 14080)
18340 title=[[Subpage test]]
18342 Poked at a [[/subpage|neat little page]] here...
18344 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
18348 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
18351 title=[[Subpage test]]
18353 Poked at a [[/subpage]] here...
18355 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
18359 Edit comment with bare anchor link (local, as on diff)
18363 title=[[Main Page]]
18367 <a href="#section">#section</a>
18371 Edit comment with bare anchor link (non-local, as on history)
18374 title=[[Main Page]]
18378 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
18382 Anchor starting with underscore
18386 <p><a href="#_ref">One</a>
18391 Id starting with underscore
18393 <div id="_ref"></div>
18395 <div id="_ref"></div>
18400 Space normalisation on autocomment (bug 22784)
18403 title=[[Main Page]]
18405 /* __hello__world__ */
18407 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
18411 percent-encoding and + signs in comments (Bug 26410)
18415 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
18417 <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>
18420 # Parsoid doesn't support this yet: see bug 73581
18421 # but it *should* omit the 'src' attribute if the image is bad.
18422 # PHP side of tests was disabled in
18423 # mediawiki/core:6bd31e7d95161a6e88fa86df60871051da997c3c
18424 # because of issues in the PHP parserTests infrastructure
18425 # (but the output below is indeed what the PHP side emits)
18427 Bad images - basic functionality
18430 !! DISABLED/html/php
18432 <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>
18436 Bad images - bug 16039: text after bad image disappears
18441 !! DISABLED/html/php
18447 <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>
18452 Verify that displaytitle works (bug #22501) no displaytitle
18456 wgAllowDisplayTitle=true
18457 wgRestrictDisplayTitle=false
18459 this is not the the title
18462 <p>this is not the the title
18467 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
18472 wgAllowDisplayTitle=true
18473 wgRestrictDisplayTitle=false
18475 this is not the the title
18476 {{DISPLAYTITLE:whatever}}
18479 <p>this is not the the title
18484 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
18489 wgAllowDisplayTitle=true
18490 wgRestrictDisplayTitle=true
18492 this is not the the title
18493 {{DISPLAYTITLE:whatever}}
18496 <p>this is not the the title
18501 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
18506 wgAllowDisplayTitle=true
18507 wgRestrictDisplayTitle=true
18509 this is not the the title
18510 {{DISPLAYTITLE:screen}}
18513 <p>this is not the the title
18518 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
18523 wgAllowDisplayTitle=false
18525 this is not the the title
18526 {{DISPLAYTITLE:screen}}
18529 <p>this is not the the title
18530 <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>
18535 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
18540 wgAllowDisplayTitle=false
18542 this is not the the title
18545 <p>this is not the the title
18550 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
18555 wgAllowDisplayTitle=true
18556 wgRestrictDisplayTitle=true
18558 this is not the the title
18559 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
18561 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
18562 <p>this is not the the title
18567 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
18572 wgAllowDisplayTitle=true
18573 wgRestrictDisplayTitle=true
18575 this is not the the title
18576 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
18578 <span style="color: red;">s</span>creen
18579 <p>this is not the the title
18584 preload: check <noinclude> and <includeonly>
18588 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
18594 preload: check <onlyinclude>
18598 Goodbye <onlyinclude>Hello world</onlyinclude>
18604 preload: can pass tags through if we want to
18608 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
18610 <includeonly>Hello world</includeonly>
18614 preload: check that it doesn't try to do tricks
18618 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
18620 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
18624 Play a bit with r67090 and bug 3158
18626 <div style="width:50% !important"> </div>
18627 <div style="width:50% !important"> </div>
18628 <div style="width:50% !important"> </div>
18629 <div style="border : solid;"> </div>
18631 <div style="width:50% !important"> </div>
18632 <div style="width:50% !important"> </div>
18633 <div style="width:50% !important"> </div>
18634 <div style="border : solid;"> </div>
18637 <div style="width:50% !important" data-parsoid='{"stx":"html"}'><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></div>
18638 <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>
18639 <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>
18640 <div style="border : solid;" data-parsoid='{"stx":"html"}'><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></div>
18645 HTML5 data attributes
18647 <span data-foo="bar">Baz</span>
18648 <p data-abc-def_hij="">Quuz</p>
18650 <p><span data-foo="bar">Baz</span>
18652 <p data-abc-def_hij="">Quuz</p>
18657 percent-encoding and + signs in internal links (Bug 26410)
18659 [[User:+%]] [[Page+title%]]
18660 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
18661 [[%]] [[+]] [[File:%+abc%39|foo|[[bar]]]]
18662 [[%33%45]] [[%33%45+]]
18664 <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>
18665 <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>
18666 <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>
18667 <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>
18670 <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>
18674 Special characters in embedded file links (bug 27679)
18676 [[File:Contains & ampersand.jpg]]
18677 [[File:Does not exist.jpg|Title with & ampersand]]
18679 <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>
18680 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
18683 <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>
18684 <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>
18688 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
18690 Text's been normalized?
18692 <p>Text's been normalized?
18697 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
18699 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
18701 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
18706 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
18708 [http://www.example.org/ ideograms]
18710 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
18715 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
18717 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
18719 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
18743 Bug 31098 Template which includes system messages which includes the template
18747 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
18748 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
18753 Bug31490 Turkish: ucfirst 'blah'
18764 Bug31490 Turkish: ucfirst 'ix'
18775 Bug31490 Turkish: lcfirst 'BLAH'
18786 Bug31490 Turkish: ucfırst (with a dotless i)
18792 <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>
18797 Bug31490 ucfırst (with a dotless i) with English language
18803 <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>
18808 Bug 26375: TOC with italics
18810 title=[[Main Page]]
18813 == ''Lost'' episodes ==
18815 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18817 <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>
18821 <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>
18826 Bug 26375: TOC with bold
18828 title=[[Main Page]]
18831 == '''should be bold''' then normal text ==
18833 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18835 <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>
18839 <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>
18844 Bug 33845: Headings become cursive in TOC when they contain an image
18846 title=[[Main Page]]
18849 == Image [[Image:foobar.jpg]] ==
18851 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18853 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
18857 <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>
18862 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
18864 title=[[Main Page]]
18867 == <blockquote>Quote</blockquote> ==
18869 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18871 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
18875 <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>
18878 <div id="toc" class="toc">
18879 <div id="toctitle">
18883 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
18886 <h2><span class="mw-headline" id="Quote"></span></h2>
18888 <p><span class="mw-headline" id="Quote">Quote</span></p>
18890 <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>
18894 Unclosed tags in TOC
18896 title=[[Main Page]]
18900 <small>Hanc marginis exiguitas non caperet.</small>
18903 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18905 <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>
18909 <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>
18910 <p><small>Hanc marginis exiguitas non caperet.</small>
18916 Multiple tags in TOC
18919 == <i>Foo</i> <b>Bar</b> ==
18921 == <i>Foo</i> <blockquote>Bar</blockquote> ==
18923 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18925 <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>
18926 <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>
18930 <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>
18931 <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>
18934 <div id="toc" class="toc">
18935 <div id="toctitle">
18939 <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>
18940 <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>
18943 <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>
18944 <h2><span class="mw-headline" id="Foo_Bar_2"><i>Foo</i></span></h2>
18946 <p><span class="mw-headline" id="Foo_Bar_2">Bar</span></p>
18948 <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>
18952 Tags with parameters in TOC
18955 == <sup class="in-h2">Hello</sup> ==
18957 == <sup class="a > b">Evilbye</sup> ==
18959 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18961 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
18962 <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>
18966 <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>
18967 <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>
18972 span tags with directionality in TOC
18975 == <span dir="ltr">C++</span> ==
18977 == <span dir="rtl">זבנג!</span> ==
18979 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
18981 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
18983 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
18985 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
18987 <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>
18988 <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>
18989 <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>
18990 <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>
18991 <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>
18995 <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>
18996 <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>
18997 <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>
18998 <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>
18999 <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>
19006 == {{int:headline_sample}} ==
19010 Bug 32057: Title needed when expanding <h> nodes.
19012 title=[[Main Page]]
19016 <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>
19021 Strip marker in urlencode
19023 {{urlencode:x<nowiki/>y}}
19024 {{urlencode:x<nowiki/>y|wiki}}
19025 {{urlencode:x<nowiki/>y|path}}
19052 Strip marker in formatNum
19054 {{formatnum:1<nowiki/>2}}
19055 {{formatnum:1<nowiki/>2|R}}
19063 Check noCommafy in formatNum
19067 {{formatnum:123456.78}}
19068 {{formatnum:123456.78|NOSEP}}
19076 Wrong option for formatNum (bug 56199)
19078 {{formatnum:1,234.56|Random}}
19079 {{formatnum:1,234.56|EVERYTHING}}
19080 {{formatnum:1234.56|any argument that has the string 'NOSEP'}}
19089 Strip marker in grammar
19093 {{grammar:elative|foo<nowiki/>bar}}
19100 Strip marker in padleft
19102 {{padleft:|2|x<nowiki/>y}}
19109 Strip marker in padright
19111 {{padright:|2|x<nowiki/>y}}
19118 Strip marker in anchorencode
19120 {{anchorencode:x<nowiki/>y}}
19127 nowiki inside link inside heading (bug 18295)
19129 ==[[foo|x<nowiki>y</nowiki>z]]==
19131 <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>
19136 new support for bdi element (bug 31817)
19138 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
19140 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
19145 Ignore pipe between table row attributes
19149 |- id=foo | style='color: red'
19157 <tr id="foo" style="color: red">
19164 Gallery override link with WikiLink (bug 34852)
19167 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
19170 <ul class="gallery mw-gallery-traditional">
19171 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19172 <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>
19173 <div class="gallerytext">
19183 Gallery override link with absolute external link (bug 34852)
19186 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
19189 <ul class="gallery mw-gallery-traditional">
19190 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19191 <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>
19192 <div class="gallerytext">
19202 Gallery override link with malicious javascript (bug 34852)
19205 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
19208 <ul class="gallery mw-gallery-traditional">
19209 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19210 <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>
19211 <div class="gallerytext">
19221 Gallery with invalid title as link (bug 43964)
19224 File:foobar.jpg|link=<
19227 <ul class="gallery mw-gallery-traditional">
19228 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19229 <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>
19230 <div class="gallerytext">
19238 Language parser function
19247 Padleft and padright as substr
19249 {{padleft:|3|abcde}}
19250 {{padright:|3|abcde}}
19258 Special parser function
19260 {{#special:RandomPage}}
19261 {{#special:BaDtItLe}}
19262 {{#special:Foobar}}
19271 Bug 34939 - Case insensitive link parsing ([HttP://])
19273 [HttP://MediaWiki.Org/]
19275 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
19278 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/"></a></p>
19282 Bug 34939 - Case insensitive link parsing ([HttP:// title])
19284 [HttP://MediaWiki.Org/ MediaWiki]
19286 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
19291 Bug 34939 - Case insensitive link parsing (HttP://)
19293 HttP://MediaWiki.Org/
19295 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
19298 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a></p>
19316 <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>
19317 <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>
19318 <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>
19319 <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>
19320 <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>
19326 ### Parsoid-specific tests
19327 ### Parsoid-PHP parser incompatibilities
19330 1. SOL-sensitive wikitext tokens as template-args
19332 parsoid=wt2html,wt2wt
19338 <span about="#mwt1" typeof="mw:Transclusion">
19339 </span><ul about="#mwt1"><li>a</li>
19341 <span about="#mwt2" typeof="mw:Transclusion">
19342 </span><ol about="#mwt2"><li>a</li>
19344 <span about="#mwt3" typeof="mw:Transclusion">
19345 </span><dl about="#mwt3"><dd>a</dd>
19349 #### -----------------------------------------------------------------
19350 #### Parsoid-specific functionality tests
19351 #### -----------------------------------------------------------------
19353 # Bug 63642/66749: Formatting elt fixup around images is cleaned up.
19354 # We know wt2wt will fail, but we expect selser to pass.
19355 # Due to the nature of our testing, wt2wt and selser tests will enter the
19356 # blacklist and we'll catch selser regressions based on changes to the
19357 # blacklist entries for selser tests.
19359 1. Bad treebuilder fixup of formatting elt is cleaned up
19361 parsoid=wt2html,wt2wt
19366 [[Image:Foobar.jpg|right|Test]]
19373 <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>
19380 2. Bad treebuilder fixup of formatting elt is cleaned up
19382 parsoid=wt2html,wt2wt
19384 '''foo[[File:Foobar.jpg|thumb|caption]]bar'''
19386 <small>[[Image:Foobar.jpg|right|300px]]</small>
19389 <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>
19391 <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>
19394 #### ----------------------------------------------------------------
19395 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
19396 #### tags. Parsoid's output for these tags differs from that of the
19398 #### ----------------------------------------------------------------
19401 Ref: 1. ref-location should be replaced with an index span
19406 B <ref name="x">foo</ref>
19409 <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>
19410 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>
19411 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>
19415 Ref: 2. ref-tags with identical names should all get the same index
19419 A <ref name="x">foo</ref>
19422 <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>
19423 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>
19427 Ref: 3. spaces in ref-names should be ignored
19431 A <ref name="x">foo</ref>
19432 B <ref name=" x " />
19435 <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>
19436 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>
19437 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>
19440 # NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
19442 Ref: 4. 'constructor' should be accepted as a valid ref-name
19446 A <ref name="constructor">foo</ref>
19448 <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>
19452 Ref: 5. body should accept generic wikitext
19457 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
19462 <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>
19464 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
19465 <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>
19471 Ref: 6. indent-pres should not be output in ref-body
19483 <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>
19485 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19486 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
19494 Ref: 7. No p-wrapping in ref-body
19513 <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>
19515 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19516 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
19531 Ref: 8. transclusion wikitext has lower precedence
19535 A <ref> foo {{echo|</ref> B C}}
19539 <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>
19540 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19541 <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>
19546 Ref: 9. unclosed comments should not leak out of ref-body
19550 A <ref> foo <!--</ref> B C
19553 <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>
19554 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19555 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <!----></li>
19560 Ref: 10. Unclosed HTML tags should not leak out of ref-body
19564 A <ref> <b> foo </ref> B C
19568 <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>
19571 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19572 <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>
19577 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
19584 <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
19585 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>
19589 Ref: 12. ref-tags act as trailing newline migration barrier
19593 <!--the newline at the end of this line moves out of the p-tag-->a
19595 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
19600 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
19603 <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>
19604 <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>
19610 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
19618 <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
19619 <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>
19623 Ref: 14. A nested ref-tag should be emitted as plain text
19627 <ref>foo <ref>bar</ref> baz</ref>
19631 <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>
19633 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
19634 <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>
19639 Ref: 15. ref-tags with identical names should get identical indexes
19643 A1 <ref name="a">foo</ref> A2 <ref name="a" />
19644 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
19648 <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>
19649 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>
19651 <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>
19655 ## We don't bother wt2wt-ing non-standard whitespace
19657 Ref: 16. Tokenizer should accept non-standard whitespace in <ref> and </ref> tags
19665 <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>
19667 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19668 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
19672 Ref: 17. Generate valid HTML5 id/about attributes
19676 <ref name="a b">foo</ref>
19680 <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>
19683 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
19684 <li id="cite_note-a_b-1"><span rel="mw:referencedBy"><a href="#cite_ref-a_b-1-0">↑</a></span> foo</li>
19688 References: 1. references tag without any refs should be handled properly
19694 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'></ol>
19698 References: 2. references tag with group only outputs references from that group
19702 A <ref group="a">foo</ref>
19703 B <ref group="b">bar</ref>
19705 <references group="a" />
19707 <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>
19708 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>
19710 <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>
19715 References: 3. ref list should be cleared after processing references
19727 <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>
19729 <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>
19732 <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>
19734 <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>
19739 References: 4. only referenced group should be cleared after processing references
19743 A <ref group="a">afoo</ref>
19746 <references group="a" />
19752 <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>
19753 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>
19755 <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>
19758 <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>
19760 <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>
19765 References: 5. ref tags in references should be processed while ignoring all other content
19770 B <ref name="b">bar</ref>
19773 <ref name="a">foo</ref>
19774 This should just get lost.
19777 <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>
19778 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>
19781 <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>
19786 References: 6. <references /> from a transclusion
19790 <ref>Foo</ref> {{echo|<references />}}
19792 <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>
19796 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
19800 A <ref>foo bar for a</ref>
19801 B <ref group="X" name="b" />
19805 <references group="X">
19806 <ref name="b">foo</ref>
19809 <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>
19810 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>
19812 <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>
19814 <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>
19818 Entities in ref name
19822 <ref name="test & me">hi</ref>
19824 <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>
19827 # This test is wt2html only because we're permitting the serializer to produce
19828 # dirty diffs, normalizing the unclosed references to the self-closed version.
19830 Generate references for unclosed references tag
19838 <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>
19841 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
19842 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
19846 New reference serializes on its own line
19848 parsoid=wt2wt,html2wt
19853 foo<ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
19856 #--------- Test stripping of empty nodes in template content ----------
19858 Empty LI and TR nodes should be stripped from template content
19863 <ul typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyLITest","href":"./Template:EmptyLITest"},"params":{},"i":0}}]}'>
19867 <table typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyTRTest","href":"./Template:EmptyTRTest"},"params":{},"i":0}}]}'>
19880 Empty LI and TR nodes should not be stripped from top-level content
19907 Empty TR nodes should not be stripped if they have any attributes set
19909 {{EmptyTRWithHTMLAttrTest}}
19911 <table typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyTRWithHTMLAttrTest","href":"./Template:EmptyTRWithHTMLAttrTest"},"params":{},"i":0}}]}'>
19912 <tr align="center"></tr>
19913 <tr><td>foo</td></tr>
19914 <tr align="center"></tr>
19915 <tr><td>bar</td></tr>
19919 #### ----------------------------------------------------------------
19920 #### The following section of tests are primarily to test
19921 #### wikitext escaping capabilities of Parsoid. Given that
19922 #### escaping can be done any number of ways, the wikitext (input)
19923 #### is always adjusted to reflect how Parsoid adds nowiki
19926 #### We are marking several tests as parsoid-only since the
19927 #### HTML in the result section is different from what the
19928 #### PHP parser generates for it.
19929 #### ----------------------------------------------------------------
19932 #### --------------- Headings ---------------
19934 #### 1. Nested inside html <h1>=foo=</h1>
19935 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
19936 #### 3. Nested inside html with wikitext split by html tags
19937 #### 4. No escape needed
19938 #### 5. Empty headings <h1></h1>
19939 #### 6. Heading chars in SOL context
19940 #### ----------------------------------------
19942 Headings: 0. Unnested
19946 <nowiki>=foo=</nowiki>
19948 <nowiki> =foo= </nowiki>
19950 <nowiki>=foo=</nowiki>
19952 =foo''a''<nowiki>=</nowiki>
19954 <p><span typeof="mw:Nowiki">=foo=</span></p>
19956 <p><span typeof="mw:Nowiki"> =foo= </span>
19958 <span typeof="mw:Nowiki">=foo=</span></p>
19960 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
19963 # New headings and existing headings are handled differently
19965 Headings: 1. Nested inside html
19975 =<nowiki>=foo=</nowiki>=
19976 ==<nowiki>=foo=</nowiki>==
19977 ===<nowiki>=foo=</nowiki>===
19978 ====<nowiki>=foo=</nowiki>====
19979 =====<nowiki>=foo=</nowiki>=====
19980 ======<nowiki>=foo=</nowiki>======
19987 <h1 data-parsoid=''>=foo=</h1>
19988 <h2 data-parsoid=''>=foo=</h2>
19989 <h3 data-parsoid=''>=foo=</h3>
19990 <h4 data-parsoid=''>=foo=</h4>
19991 <h5 data-parsoid=''>=foo=</h5>
19992 <h6 data-parsoid=''>=foo=</h6>
19996 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
20001 <nowiki>*</nowiki>bar
20007 <nowiki>=bar=</nowiki>
20015 Headings: 3. Nested inside html with wikitext split by html tags
20017 parsoid=html2wt,wt2wt
20019 = ='''bold'''<nowiki>foo=</nowiki> =
20021 <h1>=<b>bold</b>foo=</h1>
20025 Headings: 4a. No escaping needed (testing just h1 and h2)
20051 Headings: 4a'. No escaping needed (Parsoid bug T84903)
20055 <h1><span class="mw-headline" id=".3Dfoo.3D"><i>=</i>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>
20058 <h1><i>=</i>foo=</h1>
20062 Headings: 4b. No escaping needed (inside p-tags)
20077 Headings: 5. Empty headings
20089 =====<nowiki/>=====
20091 ======<nowiki/>======
20102 Headings: 6a. Heading chars in SOL context (with trailing spaces)
20106 <nowiki>=a=</nowiki>
20108 <nowiki>=a=</nowiki>
20110 <nowiki>=a=</nowiki>
20112 <nowiki>=a=</nowiki>
20121 Headings: 6b. Heading chars in SOL context (with trailing newlines)
20149 Headings: 6c. Heading chars in SOL context (leading newline break)
20154 <nowiki>=b=</nowiki>
20161 Headings: 6d. Heading chars in SOL context (with interspersed comments)
20165 <!--c0--><nowiki>=a=</nowiki>
20167 <!--c1--><nowiki>=a=</nowiki> <!--c2--> <!--c3-->
20169 <p><!--c0-->=a=</p>
20170 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
20174 Headings: 6d. Heading chars in SOL context (No escaping needed)
20183 #### --------------- Lists ---------------
20184 #### 0. Outside nests (*foo, etc.)
20185 #### 1. Nested inside html <ul><li>*foo</li></ul>
20186 #### 2. Inside definition lists
20187 #### 3. Only bullets at start should be escaped
20188 #### 4. No escapes needed
20189 #### 5. No unnecessary escapes
20190 #### 6. Escape bullets in SOL position
20191 #### 7. Escape bullets in a multi-line context
20192 #### ----------------------------------------
20195 Lists: 0. Outside nests
20197 <nowiki>*</nowiki>foo
20199 <nowiki>#</nowiki>foo
20201 <nowiki>;Foo:</nowiki>bar
20210 Lists: 1. Nested inside html
20212 *<nowiki>*foo</nowiki>
20214 *<nowiki>#foo</nowiki>
20216 *<nowiki>:foo</nowiki>
20218 *<nowiki>;foo</nowiki>
20220 #<nowiki>*foo</nowiki>
20222 #<nowiki>#foo</nowiki>
20224 #<nowiki>:foo</nowiki>
20226 #<nowiki>;foo</nowiki>
20228 <ul><li>*foo</li></ul>
20229 <ul><li>#foo</li></ul>
20230 <ul><li>:foo</li></ul>
20231 <ul><li>;foo</li></ul>
20232 <ol><li>*foo</li></ol>
20233 <ol><li>#foo</li></ol>
20234 <ol><li>:foo</li></ol>
20235 <ol><li>;foo</li></ol>
20240 Lists: 2. Inside definition lists
20242 ;<nowiki>;foo</nowiki>
20244 ;<nowiki>:foo</nowiki>
20246 ;<nowiki>:foo</nowiki>
20249 :<nowiki>:foo</nowiki>
20251 <dl><dt>;foo</dt></dl>
20252 <dl><dt>:foo</dt></dl>
20255 <dl><dd>:foo</dd></dl>
20260 Lists: 3. Only bullets at start of text should be escaped
20262 *<nowiki>*foo*bar</nowiki>
20264 *<nowiki>*foo</nowiki>''it''*bar
20266 <ul><li>*foo*bar</li></ul>
20267 <ul><li>*foo<i>it</i>*bar</li></ul>
20272 Lists: 4. No escapes needed
20293 <li><a rel="mw:WikiLink" href="Foo" title="Foo">Foo</a>: bar
20297 <li><a rel="mw:WikiLink" href="Foo" title="Foo">Foo</a>*bar
20303 Lists: 5. No unnecessary escapes
20305 * bar <span><nowiki>[[foo]]</nowiki></span>
20307 * =bar <span><nowiki>[[foo]]</nowiki></span>
20309 * [[bar <span><nowiki>[[foo]]</nowiki></span>
20311 * ]]bar <span><nowiki>[[foo]]</nowiki></span>
20313 * =bar <span>foo]]</span>=
20319 <ul><li> bar <span>[[foo]]</span></li></ul>
20320 <ul><li> =bar <span>[[foo]]</span></li></ul>
20321 <ul><li> [[bar <span>[[foo]]</span></li></ul>
20322 <ul><li> ]]bar <span>[[foo]]</span></li></ul>
20323 <ul><li> =bar <span>foo]]</span>=</li></ul>
20324 <ul><li> <s></s>: a</li></ul>
20325 <ul><li> <i>* foo</i></li></ul>
20330 Lists: 6. Escape bullets in SOL position
20334 <!--cmt--><nowiki>*</nowiki>foo
20336 <p><!--cmt-->*foo</p>
20340 Lists: 7. Escape bullets in a multi-line context
20343 <nowiki>*</nowiki>b
20351 Lists: 8. Escape colons only if not present in tags
20355 ; <nowiki>a:b</nowiki>''c:d''
20357 <dl><dt>a:b<i>c:d</i></dt></dl>
20360 #### --------------- HRs ---------------
20361 #### 1. Single line
20362 #### -----------------------------------
20365 HRs: 1. Single line
20367 ----<nowiki>----</nowiki>
20379 #### --------------- Tables ---------------
20380 #### 1a. Simple example
20381 #### 1b. No escaping needed (!foo)
20382 #### 1c. No escaping needed (|foo)
20383 #### 1d. No escaping needed (|}foo)
20385 #### 2a. Nested in td (<td>foo|bar</td>)
20386 #### 2b. Nested in td (<td>foo||bar</td>)
20387 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
20389 #### 3a. Nested in th (<th>foo!bar</th>)
20390 #### 3b. Nested in th (<th>foo!!bar</th>)
20391 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
20395 #### 4c. No escaping needed
20396 #### --------------------------------------
20399 Tables: 1a. Simple example
20410 Tables: 1b. No escaping needed
20419 Tables: 1c. No escaping needed
20428 Tables: 1d. No escaping needed
20437 Tables: 2a. Nested in td
20442 <td>foo|bar</td></tr>
20443 <tr><td>x<div>a|b</div></td>
20447 |<nowiki>foo|bar</nowiki>
20449 |x<div><nowiki>a|b</nowiki></div>
20465 Tables: 2b. Nested in td
20471 <td>a<i>b||c</i></td>
20472 <td>a<i><div>b||c</div></i></td>
20473 </tr></tbody></table>
20476 |<nowiki>foo||bar</nowiki>
20477 |a''<nowiki>b||c</nowiki>''
20478 |a''<div><nowiki>b||c</nowiki></div>''
20487 <td>a<i><div>b||c</div></i>
20493 Tables: 2c. Nested in td -- no escaping needed
20509 Tables: 3a. Nested in th
20525 Tables: 3b. Nested in th
20530 <tr><th>foo!!bar</th>
20531 <th><i>foo|bar</i></th>
20532 <th><i>foo!!bar</i></th>
20533 <th><i><span>foo!!bar</span></i></th>
20534 </tr></tbody></table>
20537 !<nowiki>foo!!bar</nowiki>
20538 !''<nowiki>foo|bar</nowiki>''
20539 !''<nowiki>foo!!bar</nowiki>''
20540 !''<span><nowiki>foo!!bar</nowiki></span>''
20549 <th><i>foo!!bar</i>
20551 <th><i><span>foo!!bar</span></i>
20557 Tables: 3c. Nested in th
20562 <tr><th>foo||bar</th>
20563 <th><span typeof="mw:Nowiki">foo||bar</span></th>
20564 </tr></tbody></table>
20567 !<nowiki>foo||bar</nowiki>
20568 !<nowiki>foo||bar</nowiki>
20581 Tables: 4a. Escape -
20590 |<nowiki>-bar</nowiki>
20605 Tables: 4b. Escape +
20614 |<nowiki>+bar</nowiki>
20629 Tables: 4c. No escaping needed
20672 <tr><td>foo-bar</td><td>foo+bar</td></tr>
20673 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
20679 <div>a|b</div></td>
20684 Tables: 4d. No escaping needed
20694 <td><a href="/wiki/Foo" title="Foo">Foo</a>-bar
20703 <tbody><tr><td><a rel="mw:WikiLink" href="./Foo" title="Foo">Foo</a>-bar</td>
20704 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>+1</td>
20705 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>-2</td></tr>
20710 Tables: Digest broken attributes on table and tr tag
20726 #### --------------- Links ----------------
20727 #### 1. Quote marks in link text
20728 #### 2. Wikilinks: Escapes needed
20729 #### 3. Wikilinks: No escapes needed
20730 #### 4. Extlinks: Escapes needed
20731 #### 5. Extlinks: No escapes needed
20732 #### --------------------------------------
20734 Links 1. Quote marks in link text
20738 [[Foo|Foo<nowiki>''boo''</nowiki>]]
20740 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
20744 Links 2. WikiLinks: Escapes needed
20749 [[Foo|<nowiki>Foobar]</nowiki>]]
20750 [[Foo|x [Foobar] x]]
20751 [[Foo|x <nowiki>[http://google.com g]</nowiki> x]]
20752 [[Foo|<nowiki>[[Bar]]</nowiki>]]
20753 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
20754 [[Foo|<nowiki>|Bar</nowiki>]]
20755 [[Foo|<nowiki>]]bar</nowiki>]]
20756 [[Foo|<nowiki>[[bar</nowiki>]]
20757 [[Foo|<nowiki>x [[ y</nowiki>]]
20758 [[Foo|<nowiki>x ]] y</nowiki>]]
20759 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
20761 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
20762 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
20763 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
20764 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
20765 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
20766 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
20767 <a href="Foo" rel="mw:WikiLink">|Bar</a>
20768 <a href="Foo" rel="mw:WikiLink">]]bar</a>
20769 <a href="Foo" rel="mw:WikiLink">[[bar</a>
20770 <a href="Foo" rel="mw:WikiLink">x [[ y</a>
20771 <a href="Foo" rel="mw:WikiLink">x ]] y</a>
20772 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
20776 Links 3. WikiLinks: No escapes needed
20783 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
20784 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
20788 Links 4. ExtLinks: Escapes needed
20792 [http://google.com <nowiki>[google]</nowiki>]
20793 [http://google.com <nowiki>google]</nowiki>]
20795 <nowiki>[http://google.com]</nowiki>
20797 <nowiki>[http://google.com google]</nowiki>
20800 <p><a href="http://google.com" rel="mw:ExtLink">[google]</a>
20801 <a href="http://google.com" rel="mw:ExtLink">google]</a></p>
20802 <p>[http://google.com]</p>
20803 <p>[http://google.com google]</p>
20807 Links 5. ExtLinks: No escapes needed
20811 [http://google.com [google]
20813 <a href="http://google.com" rel="mw:ExtLink">[google</a>
20817 Links 6. Add <nowiki/>s between text-nodes and url-links when required (bug 64300)
20819 <p>x<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>y
20820 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>?x
20821 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>&x
20822 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>'x
20823 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,x
20824 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.x
20825 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
20826 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>:x
20827 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
20828 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>!x
20829 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>=x
20830 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>(x)
20831 <a rel="mw:ExtLink" href="http://example.com(x" data-parsoid='{"stx":"url"}'>http://example.com(x</a>)
20834 x<nowiki/>http://example.com<nowiki/>y
20835 http://example.com<nowiki/>?x
20836 http://example.com<nowiki/>&x
20837 http://example.com<nowiki/>'x
20838 http://example.com<nowiki/>,x
20839 http://example.com<nowiki/>.x
20840 http://example.com<nowiki/>;x
20841 http://example.com<nowiki/>:x
20842 http://example.com<nowiki/>;x
20843 http://example.com<nowiki/>!x
20844 http://example.com<nowiki/>=x
20845 http://example.com<nowiki/>(x)
20846 http://example.com(x<nowiki/>)
20850 Links 7a. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
20853 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>
20855 "<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>"
20856 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>)
20857 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>) foo
20858 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,
20859 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>, foo
20865 "http://example.com"
20866 (http://example.com)
20867 (http://example.com) foo
20868 http://example.com,
20869 http://example.com, foo
20872 ## Parsoid currently fails wt2html on this one!
20874 Links 7b. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
20876 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.,;:!?</p>
20878 http://example.com.,;:!?
20882 Links 8. Add <nowiki/>s between text-nodes and RFC-links when required (bug 64300)
20884 <p><a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>4</p>
20890 Links 9. Don't add spurious <nowiki/>s between text-nodes and RFC-links (bug 64300)
20892 <p>x<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
20893 X<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
20894 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>?foo
20895 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>&foo
20905 Links 10. Add <nowiki/>s between text-nodes and PMID-links when required (bug 64300)
20907 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>4
20913 Links 11. Don't add spurious <nowiki/>s between text-nodes and PMID-links (bug 64300)
20915 <p>x<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
20916 X<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
20917 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>?foo
20918 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>&foo
20928 Links 12. Add <nowiki/>s between text-nodes and ISBN-links when required (bug 64300)
20930 <p><a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>1
20931 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>x
20932 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>b
20935 ISBN 1234567890<nowiki/>1
20936 ISBN 1234567890<nowiki/>x
20937 ISBN 1234567890<nowiki/>b
20941 Links 12. Don't add spurious <nowiki/>s between text-nodes and ISBN-links (bug 64300)
20943 <p><a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>'s
20949 Links 13: Protect link-like plain text. (Parsoid bug T78425)
20953 <p>this is not a link: http://example.com
20956 this is not a link: <nowiki>http://example.com</nowiki>
20960 #### --------------- Quotes ---------------
20961 #### 1. Quotes inside <b> and <i>
20962 #### 2. Link fragments separated by <i> and <b> tags
20963 #### 3. Link fragments inside <i> and <b>
20964 #### 4. No escaping needed
20965 #### --------------------------------------
20967 1a. Quotes inside <b> and <i>
20969 parsoid=html2wt,wt2wt
20971 ''<nowiki/>'foo'<nowiki/>''
20972 ''<nowiki>''foo''</nowiki>''
20973 ''<nowiki>'''foo'''</nowiki>''
20975 '''<nowiki/>'foo'<nowiki/>'''
20976 '''<nowiki>''foo''</nowiki>'''
20977 '''<nowiki>'''foo'''</nowiki>'''
20978 '''foo'<nowiki/>''bar'<nowiki/>''baz'''
20979 '''foo'''<nowiki/>'s
20982 ''foo'<nowiki/>''<nowiki/>'
20983 '<nowiki/>''foo''<nowiki/>'
20985 '''foo'''<nowiki/>'
20986 '<nowiki/>'''foo'''<nowiki/>'
20987 ''fools'<span> errand</span>''
20988 ''<span>fool</span>'s errand''
20989 a|!*#-:;+-~[]{}b'''x''
20998 <b>foo'<i>bar'</i>baz</b>
21007 <i>fools'<span> errand</span></i>
21008 <i><span>fool</span>'s errand</i>
21009 a|!*#-:;+-~[]{}b'<i>x</i>
21014 1b. Quotes inside <b> and <i> with other chars
21016 parsoid=html2wt,wt2wt
21018 '''a'' foo ''[[bar]]''
21019 ''a''' foo ''[[bar]]''
21020 ''a''' foo '''{{echo|[[bar]]}}'''
21021 [[foo]] x'''[[bar]]''
21023 '<i>a</i> foo <i><a rel="mw:WikiLink" href="Bar" title="Bar">bar</a></i>
21024 <i>a'</i> foo <i><a rel="mw:WikiLink" href="Bar" title="Bar">bar</a></i>
21025 <i>a'</i> foo <b><a rel="mw:WikiLink" href="Bar" title="Bar" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[bar]]"}},"i":0}}]}'>bar</a></b>
21026 <a rel="mw:WikiLink" href="Foo" title="Foo">foo</a> x'<i><a href="Bar" rel="mw:WikiLink" title="Bar">bar</a></i>
21030 2. Link fragments separated by <i> and <b> tags
21032 [[''foo''<nowiki>hello]]</nowiki>
21034 [['''foo'''<nowiki>hello]]</nowiki>
21036 <p>[[<i>foo</i>hello]]
21037 </p><p>[[<b>foo</b>hello]]
21041 # FIXME: Escaping one or both of [[ and ]] is also acceptable --
21042 # this is one of the shortcomings of this format
21044 3. Link fragments inside <i> and <b>
21046 ''[[foo''<nowiki>]]</nowiki>
21048 '''[[foo'''<nowiki>]]</nowiki>
21051 </p><p><b>[[foo</b>]]
21056 4. No escaping needed
21058 '<span>''bar''</span>'
21059 '<span>'''bar'''</span>'
21062 <p>'<span><i>bar</i></span>'
21063 '<span><b>bar</b></span>'
21068 #### ----------- Paragraphs ---------------
21069 #### 1. No unnecessary escapes
21070 #### --------------------------------------
21073 1. No unnecessary escapes
21075 bar <span><nowiki>[[foo]]</nowiki></span>
21077 =bar <span><nowiki>[[foo]]</nowiki></span>
21079 [[bar <span><nowiki>[[foo]]</nowiki></span>
21081 ]]bar <span><nowiki>[[foo]]</nowiki></span>
21083 =bar <span>foo]]</span><nowiki>=</nowiki>
21085 <p>bar <span>[[foo]]</span>
21086 </p><p>=bar <span>[[foo]]</span>
21087 </p><p>[[bar <span>[[foo]]</span>
21088 </p><p>]]bar <span>[[foo]]</span>
21089 </p><p>=bar <span>foo]]</span>=
21093 #### ----------------------- PRE --------------------------
21094 #### 1. Leading whitespace in SOL context should be escaped
21095 #### ------------------------------------------------------
21097 1. Leading whitespace in SOL context should be escaped
21101 <nowiki> </nowiki>a
21103 <nowiki> </nowiki> a
21105 <nowiki> </nowiki>a(tab)
21107 <nowiki> </nowiki> a
21109 <nowiki> </nowiki> a
21112 <nowiki> </nowiki>b
21115 <nowiki> </nowiki>b
21118 <nowiki> </nowiki> b
21124 <p><!--cmt--> a</p>
21134 2. Leading whitespace in non-indent-pre contexts should not be escaped
21141 <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>
21145 3. Leading whitespace in indent-pre suppressing contexts should not be escaped
21164 4. Leading whitespace in indent-pre suppressing contexts should not be escaped
21168 [[File:Foobar.jpg|thumb|caption]]
21171 <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>
21175 5. Nowiki escaping should account for indent-pres
21184 #### --------------- Behavior Switches --------------------
21186 1. Valid behavior switches should be escaped
21190 <nowiki>__TOC__</nowiki>
21191 ''<nowiki>__TOC__</nowiki>''
21198 2. Invalid behavior switches should not be escaped
21209 #### --------------- HTML tags ---------------
21212 #### 3. multi-line html tag
21213 #### 4. extension tags
21214 #### -----------------------------------------
21220 <a href="http://google.com">google</a>
21222 <a href="http://google.com">google</a>
21228 <nowiki><div>foo</div>
21229 <div style="color:red">foo</div></nowiki>
21231 <p><div>foo</div>
21232 <div style="color:red">foo</div>
21237 3. multi-line html tag
21252 <nowiki><ref>foo</ref></nowiki>
21254 <nowiki><ref>bar</nowiki>
21256 baz<nowiki></ref></nowiki>
21258 <p><ref>foo</ref>
21259 </p><p><ref>bar
21260 </p><p>baz</ref>
21264 #### --------------- Others ---------------
21268 <nowiki>foo</nowiki>
21270 <p><nowiki>foo</nowiki>
21274 ## The quote-char in the input is necessary for triggering the bug
21276 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
21278 parsoid=wt2wt,html2wt
21287 Tag-like HTML structures are passed through as text
21309 </p><p>1<d e>f
21314 # This was a bug in the PHP parser (see bug 17663 and its dups,
21315 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
21317 Tag names followed by punctuation should not be recognized as tags
21321 <p><s.ome> text
21326 HTML tag with necessary entities in attributes
21328 <span title="&amp;">foo</span>
21330 <p><span title="&amp;">foo</span>
21335 HTML tag with 'unnecessary' entity encoding in attributes
21337 <span title="&">foo</span>
21339 <p><span title="&">foo</span>
21344 HTML tag with broken attribute value quoting
21346 <span title="Hello world>Foo</span>
21348 <p><span>Foo</span>
21351 <p><span title="Hello world">Foo</span>
21356 Parsoid-only: HTML tag with broken attribute value quoting
21360 <span title="Hello world>Foo</span>
21362 <p><span title="Hello world">Foo</span>
21367 Table with broken attribute value quoting
21370 | title="Hello world|Foo
21381 <td title="Hello world">Foo
21387 Table with broken attribute value quoting on consecutive lines
21390 | title="Hello world|Foo
21391 | style="color:red|Bar
21404 <td title="Hello world">Foo
21405 </td><td style="color: red">Bar
21406 </td></tr></tbody></table>
21411 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
21421 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
21431 Accept empty td cell attribute
21434 | align="center" | foo || |
21439 <td align="center"> foo </td>
21446 Non-empty attributes in th-cells
21449 ! Foo !! style="color: red" | Bar
21455 <th style="color: red"> Bar
21461 Accept empty attributes in th-cells
21476 Empty table rows go away
21497 ### Parsoid-centric tests for testing RTing of inter-element separators
21498 ### Edge cases not tested by existing parser tests and specific to
21499 ### Parsoid-specific serialization strategies.
21503 RT-ed inter-element separators should be valid separators
21515 # Parsoid-only since PHP parser relies on Tidy for correct output
21517 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
21531 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'><small data-parsoid='{"stx":"html","autoInsertedEnd":true}'>foo
21532 <p>bar</p></small></td></tr>
21536 <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>
21541 Empty TD followed by TD with tpl-generated attribute
21546 |{{echo|style='color:red'}}|foo
21560 Indented table with an empty td
21579 Indented block & table
21593 <div data-parsoid='{"stx":"html"}'>foo</div>
21595 <tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>foo</td></tr>
21600 Indent and comment before table row
21615 <!--hi--><tbody><tr data-parsoid='{"startTagSrc":"|-","autoInsertedEnd":true}'>
21616 <td data-parsoid='{"autoInsertedEnd":true}'> there</td></tr>
21620 # Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext
21622 Empty TR followed by a template-generated TR
21628 {{echo|<tr><td>foo</td></tr>}}
21634 <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}}]}'>
21639 ## PHP and parsoid output differ for this, and since this is primarily
21640 ## for testing Parsoid's serializer, marking this Parsoid only
21642 Empty TR followed by mixed-ws-comment line should RT correctly
21658 <!--c--> </tr><!--d-->
21664 Multi-line image caption generated by templates with/without trailing newlines
21666 [[File:Foobar.jpg|thumb|300x300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
21667 [[File:Foobar.jpg|thumb|300x300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
21669 <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>
21670 <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>
21674 New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
21678 <includeonly>foo</includeonly>
21685 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>foo</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><p>new para</p>
21687 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid=''/><h1>new heading</h1>
21690 ## PHP emits broken html for this, and since this is primarily
21691 ## a Parsoid serializer test, marking this Parsoid only
21693 Improperly nested inline or quotes tags with whitespace in between
21697 <span> <s>x</span> </s>
21700 <p><span> <s>x</s></span><s> </s>
21701 <b> <i>x</i></b><i> </i>
21706 Encapsulate protected attributes from wt
21710 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
21712 <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>
21716 ## Currently the p-wrapper is fragile in how it adds / removes transformations.
21717 ## Having nested or stray pre tags results in the attempt to add duplicates,
21718 ## causing an assertion fail. This test tries to prevent that situation.
21720 Ensure ParagraphWrapper can deal with stray closing pre tags
21730 1. Ensure fostered text content is wrapped in element nodes
21734 <table>hi</table><table>ho</table>
21743 2. Ensure fostered text content is wrapped in element nodes (traps regressions around fostered marker on the element getting lost)
21745 parsoid=wt2html,wt2wt
21754 <tbody><tr><td> a</td></tr>
21759 Encapsulation properly handles null DSR information from foster box
21761 parsoid=wt2html,wt2wt
21763 {{echo|<table>foo<tr><td>bar</td></tr></table>}}
21765 <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>
21769 1. Encapsulate foster-parented transclusion content
21771 parsoid=wt2wt,wt2html
21773 <table>{{echo|foo<tr><td>bar</td></tr>}}</table>
21775 <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>
21785 2. Encapsulate foster-parented transclusion content
21787 parsoid=wt2wt,wt2html
21789 <table><div>{{echo|foo}}</div><tr><td>bar</td></tr></table>
21791 <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>
21802 3. Encapsulate foster-parented transclusion content
21804 parsoid=wt2wt,wt2html
21806 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
21808 <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>"]}">
21821 4. Encapsulate foster-parented transclusion content
21823 parsoid=wt2wt,wt2html
21825 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
21827 <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>"]}">
21840 5. Encapsulate foster-parented transclusion content
21842 parsoid=wt2wt,wt2html
21844 <table><tr><td><div><p>{{echo|foo</p></div></td>foo}}</tr></table>
21846 <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>
21861 6. Encapsulate foster-parented transclusion content
21863 parsoid=wt2wt,wt2html
21865 <table><tr><td><div><p>{{echo|foo</p></div></td>foo</tr></table>}}<p>ok</p>
21867 <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>
21883 7. Encapsulate foster-parented transclusion content
21885 parsoid=wt2wt,wt2html
21887 <table>{{echo|<p>foo</p>}}<td>bar</td></table>
21889 <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>
21900 8. Encapsulate foster-parented transclusion content
21902 parsoid=wt2wt,wt2html
21905 }}{|{{echo|style='color:red'}}
21910 <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>
21920 9. Encapsulate foster-parented transclusion content
21922 parsoid=wt2wt,wt2html
21924 <table>{{echo|hi</table>hello}}
21926 <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>
21930 Table in fosterable position
21932 parsoid=wt2html,wt2wt
21941 <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">
21943 <table about="#mwt1" data-parsoid='{"autoInsertedEnd":true}'></table>
21949 # Parsoid only for bug 64747
21951 Properly encapsulate empty-content transclusions in fosterable positions
21959 <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>"}'>
21965 Support <object> element with .data attribute
21969 <object data="test.swf"></object>
21971 <object data="test.swf"></object>
21975 Don't block XML namespace declaration
21977 <span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">MediaWiki</span>
21979 <p><span>MediaWiki</span>
21982 <p><span xmlns:dct="http://purl.org/dc/terms/" data-x-property="dct:title" data-parsoid='{"stx":"html"}'>MediaWiki</span></p>
21985 # -----------------------------------------------------------------
21986 # The following section of tests are primarily to spec requirements
21987 # around serialization of new/edited content.
21989 # All these tests are marked Parsoid html2wt and html2html only
21990 # ----------------------------------------------------------------
21992 # 'mi' is a localinterwiki prefix as well as a language
21994 Serialize interwiki links pointing to the current wiki as plain wiki links (bug 65869)
22000 <p><a rel="mw:ExtLink" href="http://mi.wikipedia.org/wiki/Foo">Foo</a></p>
22004 New wiki links (href variations)
22008 <a rel="mw:WikiLink" href="./Foo_bar">Foo_bar</a>
22009 <a rel="mw:WikiLink" href="Foo_bar">Foo_bar</a>
22010 <a rel="mw:WikiLink" href="Foo bar">Foo_bar</a>
22011 <a rel="mw:WikiLink" href="./Toxine_bact%C3%A9rienne">Toxine bactérienne</a>
22016 [[Toxine bactérienne]]
22020 New wiki links (content string variations)
22024 <a rel="mw:WikiLink" href="./Foo_bar">Foo_bar</a>
22025 <a rel="mw:WikiLink" href="./Foo_bar">Foo bar</a>
22026 <a rel="mw:WikiLink" href="./Foo_bar">./Foo_bar</a>
22030 [[Foo_bar|./Foo_bar]]
22034 New category links (href variations)
22038 <link rel="mw:PageProp/Category" href="./Category:Toxine_bactérienne" />
22039 <link rel="mw:PageProp/Category" href="./Category:Toxine_bact%C3%A9rienne" />
22040 <link rel="mw:PageProp/Category" href="Category:Toxine_bact%C3%A9rienne" />
22042 [[Category:Toxine bactérienne]]
22043 [[Category:Toxine bactérienne]]
22044 [[Category:Toxine bactérienne]]
22048 New interlanguage links (href variations)
22052 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine bactérienne" />
22053 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine_bactérienne" />
22054 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine_bact%C3%A9rienne" />
22056 [[es:Toxine bactérienne]]
22057 [[es:Toxine_bactérienne]]
22058 [[es:Toxine_bactérienne]]
22062 Image: Modifying size of an image (1)
22065 "modes": ["wt2wt"],
22067 ["img[height]", "attr", "height", "22"],
22068 ["img[width]", "attr", "width", "200"]
22072 [[Image:Foobar.jpg|230x230px]]
22074 [[Image:Foobar.jpg|200x200px]]
22078 Image: Modifying size of an image (2)
22081 "modes": ["wt2wt"],
22083 ["img[height]", "attr", "height", "100"],
22084 ["img[width]", "attr", "width", "500"]
22088 [[Image:Foobar.jpg|230x230px]]
22090 [[Image:Foobar.jpg|500x500px]]
22093 # Change in size is ignored so long as class='mw-default-size'
22095 Image: Modifying size of an image (3)
22098 "modes": ["wt2wt"],
22100 ["figure[class]", "removeClass", "mw-default-size"],
22101 ["figure img", "attr", "height", "19"],
22102 ["figure img", "attr", "width", "170"]
22106 [[Image:Foobar.jpg|thumb]]
22108 [[Image:Foobar.jpg|thumb|170x170px]]
22112 Image: Modifying alignment of an image (bug 48665)
22115 "modes": ["wt2wt"],
22117 ["figure[class]", "removeClass", "mw-halign-right"],
22118 ["figure[class]", "addClass", "mw-halign-left"]
22122 [[Image:Foobar.jpg|thumb|caption|right]]
22124 [[Image:Foobar.jpg|thumb|caption|left]]
22128 Image: Modifying mw-default-size of an frameless image (bug 62805)
22131 "modes": ["wt2wt"],
22133 ["figure.mw-default-size", "removeClass", "mw-default-size"]
22137 [[Image:Foobar.jpg|frameless|right]]
22139 [[Image:Foobar.jpg|frameless|right|220x220px]]
22143 Image: Modifying valign of an image (bug 49221)
22146 "modes": ["wt2wt"],
22148 ["*[typeof=\"mw:Image\"]", "removeClass", "mw-valign-middle"],
22149 ["*[typeof=\"mw:Image\"]", "addClass", "mw-valign-text-top"]
22153 [[File:Foobar.jpg|20px|middle]]
22155 [[File:Foobar.jpg|20px|text-top]]
22159 Image: Modifying alt attribute of an image (bug 56400)
22162 "modes": ["wt2wt"],
22164 ["img[alt]", "attr", "alt", "some alternate edited text"]
22168 [[File:Foobar.jpg|thumb|some caption|alt=some alternate text]]
22170 [[File:Foobar.jpg|thumb|some caption|alt=some alternate edited text]]
22174 Image: Modifying caption of an image
22177 "modes": ["wt2wt"],
22179 ["figcaption", "text", "new caption"]
22183 [[Image:Foobar.jpg|thumb|original caption]]
22185 [[Image:Foobar.jpg|thumb|new caption]]
22189 Image: empty alt attribute (bug 48924)
22193 [[File:Foobar.jpg|thumb|alt=|bar]]
22195 <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>
22199 #Image: new attributes should be serialized in wiki's language for RTL languages (bug 51852)
22204 #[[Imagen:Foobar.jpg|derecha|miniaturadeimagen]]
22206 #<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>
22210 Image: Block level image should have \n before and after
22213 [[File:Foobar.jpg|right|thumb|150x150px]]
22217 <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>
22222 Image: New block level image should have \n before and after (existing content)
22225 [[File:Foobar.jpg|right|thumb|150x150px]]
22229 <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>
22234 Image: upright option (parsoid)
22238 [[File:Foobar.jpg|thumb|upright|caption]]
22239 [[File:Foobar.jpg|thumb|upright=0.5|caption]]
22240 [[File:Foobar.jpg|thumb|500x500px|upright=0.5|caption]]
22242 <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>
22243 <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>
22244 <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>
22248 Image: upright option is ignored on inline and frame images (parsoid)
22252 [[File:Foobar.jpg|500x500px|upright=0.5|caption]]
22254 <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>
22258 Image: from basic HTML (1)
22262 <span typeof="mw:Image">
22263 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
22266 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
22270 Image: from basic HTML (2)
22274 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
22276 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
22280 Image: from basic HTML (3)
22284 <a href="Main"><img src="File:Foobar.jpg" width=100 height=100 alt="Alt"></a>
22286 [[File:Foobar.jpg|link=Main|alt=Alt|100x100px]]
22290 Image: from basic HTML (4)
22294 <img src="File:Foobar.jpg">
22296 [[File:Foobar.jpg|link=]]
22300 Lists: Serialize correctly even when list content is wrapped in p-tags (like VE does)
22307 <li><p>foo</p></li>
22312 Lists: Serialize correctly even when list tags has unneeded whitespace between tags
22318 <ul> <li>foo</li></ul>
22322 Don't strip leading whitespace when handling indent-pre suppressing tags
22330 '''This is very bold of you!'''
22334 indented cell (no pre-wrapping!)
22341 <tr><td> indented row</td></tr>
22344 <b>This is very bold of you!</b>
22347 indented cell (no pre-wrapping!)
22355 Nowiki-wrap leading whitespace when handling indent-pre inducing tags
22360 <nowiki> </nowiki><span>bar</span>
22363 <nowiki> </nowiki></span>bar2
22366 <nowiki> </nowiki><span>bar</span>
22369 <nowiki> </nowiki><span>foo</span>
22387 Lists: Add space after bullets
22393 * <span> baz</span>
22398 <li><span> baz</span></li>
22403 Lists: Dont insert newlines in a serialized list item.
22410 <ul><li>a<br>b</li><li>c</li></ul>
22414 Headings: Add space before/after == (Bug 51744)
22424 == <span> baz</span> ==
22429 <h2><span> baz</span></h2>
22433 Parsoid: Serialize positional parameters with = in them as named parameter
22439 {{echo|1 = f=oo|2 = bar}}
22441 <!--Orig params with data-parsoid has heuristics for handling = chars-->
22442 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
22443 {{echo|<nowiki>f=oo</nowiki>|bar}}
22445 <p about="#mwt1" typeof="mw:Transclusion"
22446 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}}]}'>foo</p>
22448 <p about="#mwt1" typeof="mw:Transclusion"
22449 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}, "2":{"wt":"bar"}},"i":0}}]}'>foo</p>
22451 <!--Orig params with data-parsoid has heuristics for handling = chars-->
22452 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
22453 <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>
22457 Parsoid: Correctly serialize block-node children when they are a combination of text and p-nodes
22473 <div>a<p>b</p></div>
22482 Substrings resembling wikitext in hrefs should not get nowiki escapes
22488 <a rel="mw:WikiLink" href="./Foo''bar''baz">Foo''bar''baz</a>
22491 #-----------------------------
22492 # I/B quote minimization tests
22493 #-----------------------------
22496 1. I/B quote minimization: wikitext-only tags should be combined
22516 <p><i>A</i><i>B</i></p>
22517 <p><b>A</b><b>B</b></p>
22518 <p><i>A</i><b><i>B</i></b></p>
22519 <p><b>A</b><i><b>B</b></i></p>
22520 <p><b>A</b><i><b>B</b><b>C</b></i><b>D</b></p>
22521 <p><i><b>A</b></i><i><b>B</b></i></p>
22522 <p><i><b>A</b></i><b><i>B</i></b></p>
22523 <p><b><i>A</i></b><i><b>B</b></i></p>
22527 2. I/B quote minimization: wikitext and html tags should not be combined
22533 ''A''<nowiki/>'''<i>B</i>'''
22535 <p><i>A</i><i data-parsoid='{"stx":"html"}'>B</i></p>
22536 <p><i>A</i><b><i data-parsoid='{"stx":"html"}'>B</i></b></p>
22540 3. I/B quote minimization: templated content stops minimization
22544 ''A''{{echo|''B''}}
22546 ''A''{{echo|'''''B'''''}}
22548 <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>
22549 <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>
22553 4. I/B quote minimization: new content should be mimimized with adjacent old content
22563 <p><i>A</i><i>B</i></p>
22564 <p><b>A</b><b>B</b></p>
22565 <p><i>A</i><b><i>B</i></b></p>
22569 5a. Merge adjacent quote nodes if they've been edited
22572 "modes": ["wt2wt"],
22574 ["p", "contents", "remove", ":contains('b')"]
22584 5b. Merge adjacent quote nodes if they've been edited
22587 "modes": ["wt2wt"],
22593 ''a''<span id="x">b</span>''c''
22598 #------------------------------------
22599 # End of I/B quote minimization tests
22600 #------------------------------------
22603 Bug 54262: New entities
22609 <span typeof="mw:Entity"> </span>
22612 ## Note that there is no wikitext output for 'unknownproperty' ##
22613 ## Unknown magic words are silently dropped ##
22628 __NOCONTENTCONVERT__
22630 <meta property='mw:PageProp/toc' />
22631 <meta property='mw:PageProp/notoc' />
22632 <meta property='mw:PageProp/forcetoc' />
22633 <meta property='mw:PageProp/index' />
22634 <meta property='mw:PageProp/noindex' />
22635 <meta property='mw:PageProp/nogallery' />
22636 <meta property='mw:PageProp/noeditsection' />
22637 <meta property='mw:PageProp/notitleconvert' />
22638 <meta property='mw:PageProp/nocontentconvert' />
22639 <meta property='mw:PageProp/unknownproperty' />
22643 Consecutive <pre>s should not get merged
22645 parsoid=html2wt,html2html
22661 <pre>a</pre><pre>b</pre>
22675 Edited ISBN links not serializable as ISBN links should serialize as wikilinks
22679 [[Special:BookSources/1234567890|ISBN 1234567895]]
22681 <a rel="mw:ExtLink" href="./Special:BookSources/1234567890">ISBN 1234567895</a>
22685 Edited RFC links not serializable as RFC links should serialize as extlinks
22689 [//tools.ietf.org/html/rfc123 New RFC]
22691 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink">New RFC</a>
22695 Edited PMID links not serializable as PMID links should serialize as extlinks
22699 [//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract New PMID]
22701 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink">New PMID</a>
22705 Edited Redirect link should emit a non-piped wikitext link
22711 <link rel="mw:PageProp/redirect" href="Bar" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>
22715 T75121: Infer extension name from typeOf if data-mw is not present
22721 <div typeOf="mw:Extension/foo"></div>
22724 # -----------------------------------------------------------------
22725 # End of section for Parsoid-only html2wt tests for serialization
22727 # -----------------------------------------------------------------
22734 Try for 100% code coverage