1 # MediaWiki Parser test cases
2 # Some taken from http://meta.wikimedia.org/wiki/Parser_testing
3 # All (C) their respective authors and released under the GPL
5 # The syntax should be fairly self-explanatory.
7 # Currently supported test options:
8 # One of the following three:
10 # (default) generate HTML output
11 # pst apply pre-save transform
12 # msg apply message transform
14 # Plus any combination of these:
16 # cat add category links
17 # ill add inter-language links
18 # subpage enable subpages (disabled by default)
19 # noxml don't check for XML well formdness
20 # title=[[XXX]] run test using article title XXX
21 # language=XXX set content language to XXX for this test
22 # variant=XXX set the variant of language for this test (eg zh-tw)
23 # disabled do not run test
24 # parsoid parsoid-specific options (not run by PHP parser unless
25 # the test includes an html/php section)
26 # php php-only test (not run by the parsoid parser unless
27 # the test includes an html/parsoid section)
28 # showtitle make the first line the title
29 # comment run through Linker::formatComment() instead of main parser
30 # local format section links in edit comment text as local links
31 # notoc disable table of contents
32 # thumbsize=NNN set the default thumb size to NNNpx for this test
34 # You can also set the following parser properties via test options:
35 # wgEnableUploads, wgAllowExternalImages, wgMaxTocLevel,
36 # wgLinkHolderBatchSize, wgRawHtml
38 # For testing purposes, temporary articles can created:
39 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
40 # where '/' denotes a newline.
42 # This is the standard article assumed to exist.
67 MediaWiki:bad image list
69 * [[File:Bad.jpg]] except [[Nasty page]]
97 Template:echo_with_span
103 Template:echo_with_div
115 Template:table_attribs
118 |</noinclude>style="color: red"| Foo
124 {{table_attribs}} || Bar || Baz
128 Template:image_attribs
131 [[File:foobar.jpg|</noinclude>right|Caption text<noinclude>]]</noinclude>
165 This is a simple paragraph.
167 <p>This is a simple paragraph.
172 Paragraphs with extra newline spacing
195 Paragraphs with newline spacing with comment lines in between
203 <!--foo--><!--More than 1 comment, still stripped-->
207 <!--foo--> <!----> <!-- bar -->
268 Paragraphs with newline spacing with non-empty white-space lines in between
295 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
303 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
342 Extra newlines: More paragraphs with indented comment
357 Extra newlines followed by heading
372 <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>
373 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
376 <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>
381 Extra newlines between heading and content are swallowed
389 <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>
390 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
397 http://fr.wikipedia.org/wiki/🍺
398 <!-- EasterEgg we love beer, better be able be able to link to it -->
400 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
411 <li> Item 2</li></ul>
419 * plain''italic''plain
420 * plain''italic''plain''italic''plain
421 * plain'''bold'''plain
422 * plain'''bold'''plain'''bold'''plain
423 * plain''italic''plain'''bold'''plain
424 * plain'''bold'''plain''italic''plain
425 * plain''italic'''bold-italic'''italic''plain
426 * plain'''bold''bold-italic''bold'''plain
427 * plain'''''bold-italic'''italic''plain
428 * plain'''''bold-italic''bold'''plain
429 * plain''italic'''bold-italic'''''plain
430 * plain'''bold''bold-italic'''''plain
431 * plain l'''italic''plain
432 * plain l''''bold''' plain
435 <li> plain<i>italic</i>plain</li>
436 <li> plain<i>italic</i>plain<i>italic</i>plain</li>
437 <li> plain<b>bold</b>plain</li>
438 <li> plain<b>bold</b>plain<b>bold</b>plain</li>
439 <li> plain<i>italic</i>plain<b>bold</b>plain</li>
440 <li> plain<b>bold</b>plain<i>italic</i>plain</li>
441 <li> plain<i>italic<b>bold-italic</b>italic</i>plain</li>
442 <li> plain<b>bold<i>bold-italic</i>bold</b>plain</li>
443 <li> plain<i><b>bold-italic</b>italic</i>plain</li>
444 <li> plain<b><i>bold-italic</i>bold</b>plain</li>
445 <li> plain<i>italic<b>bold-italic</b></i>plain</li>
446 <li> plain<b>bold<i>bold-italic</i></b>plain</li>
447 <li> plain l'<i>italic</i>plain</li>
448 <li> plain l'<b>bold</b> plain</li></ul>
452 # this example taken from the [[simple:Moon]] article (bug 47326)
454 Italics and possessives (1)
456 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
458 <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
462 # this example taken from [[en:Flaming Pie]] (bug 49926)
464 Italics and possessives (2)
466 '''''Flaming Pie''''' is ... released in 1997. In ''Flaming Pie'''s liner notes
468 <p><i><b>Flaming Pie</b></i> is ... released in 1997. In <i>Flaming Pie'</i>s liner notes
472 # this example taken from [[en:Dictionary]] (bug 49926)
474 Italics and possessives (3)
476 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''.
478 <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>.
484 ### 2-quote opening sequence tests
487 Italics and bold: 2-quote opening sequence: (2,2)
497 Italics and bold: 2-quote opening sequence: (2,3)
508 # same html as previous, but wikitext adjusted to match parsoid html2wt
510 Italics and bold: 2-quote opening sequence: (2,3) w/ nowiki
512 ''<nowiki>foo'</nowiki>''
520 Italics and bold: 2-quote opening sequence: (2,4)
531 # same html as previous, but wikitext adjusted to match parsoid html2wt
533 Italics and bold: 2-quote opening sequence: (2,4) w/ nowiki
535 ''<nowiki>foo''</nowiki>''
542 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
544 Italics and bold: 2-quote opening sequence: (2,5)
557 # same html as previous, but wikitext adjusted to match parsoid html2wt
559 Italics and bold: 2-quote opening sequence: (2,5+3) w/ nowiki
561 ''foo'''''<nowiki/>'''
572 ### 3-quote opening sequence tests
576 Italics and bold: 3-quote opening sequence: (3,2)
586 Italics and bold: 3-quote opening sequence: (3,3)
596 Italics and bold: 3-quote opening sequence: (3,4)
607 # same html as previous, but wikitext adjusted to match parsoid html2wt
609 Italics and bold: 3-quote opening sequence: (3,4) w/ nowiki
611 '''<nowiki>foo'</nowiki>'''
618 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
620 Italics and bold: 3-quote opening sequence: (3,5)
633 # same html as previous, but wikitext adjusted to match parsoid html2wt
635 Italics and bold: 3-quote opening sequence: (3,5+2) w/ nowiki
637 '''foo'''''<nowiki/>''
648 ### 4-quote opening sequence tests
652 Italics and bold: 4-quote opening sequence: (4,2)
663 # same html as previous, but wikitext adjusted to match parsoid html2wt
665 Italics and bold: 4-quote opening sequence: (4,2) w/ nowiki
667 <nowiki>''</nowiki>''foo''
675 Italics and bold: 4-quote opening sequence: (4,3)
685 Italics and bold: 4-quote opening sequence: (4,4)
696 # same html as previous, but wikitext adjusted to match parsoid html2wt
698 Italics and bold: 4-quote opening sequence: (4,4) w/ nowiki
700 ''''<nowiki>foo'</nowiki>'''
707 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
709 Italics and bold: 4-quote opening sequence: (4,5)
718 <p>'<b>foo</b><i></i>
722 # same html as previous, but wikitext adjusted to match parsoid html2wt
724 Italics and bold: 4-quote opening sequence: (4,5+2) w/ nowiki
726 ''''foo'''''<nowiki/>''
731 <p>'<b>foo</b><i></i>
737 ### 5-quote opening sequence tests
741 Italics and bold: 5-quote opening sequence: (5,2)
752 # same html as previous, but wikitext adjusted to match parsoid html2wt
753 # skipping wt2html and html2html because it wants to put <i> before <b>
755 Italics and bold: 5-quote opening sequence: (5,2+3)
757 parsoid=wt2wt,html2wt
766 Italics and bold: 5-quote opening sequence: (5,3)
777 # same html as previous, but wikitext adjusted to match parsoid html2wt
779 Italics and bold: 5-quote opening sequence: (5,3+2)
789 Italics and bold: 5-quote opening sequence: (5,4)
795 <p><i><b>foo'</b></i>
800 # same html as previous, but wikitext adjusted to match parsoid html2wt
802 Italics and bold: 5-quote opening sequence: (5,4+2) w/ nowiki
804 '''''<nowiki>foo'</nowiki>'''''
806 <p><i><b>foo'</b></i>
812 Italics and bold: 5-quote opening sequence: (5,5)
821 ### multiple quote sequences in a line
824 Italics and bold: multiple quote sequences: (2,4,2)
830 <p><i>foo'<b>bar</b></i>
835 # same html as previous, but wikitext adjusted to match parsoid html2wt
837 Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
839 ''<nowiki>foo'</nowiki>'''bar'''''
841 <p><i>foo'<b>bar</b></i>
847 Italics and bold: multiple quote sequences: (2,4,3)
853 <p><i>foo'<b>bar</b></i>
858 # same html as previous, but wikitext adjusted to match parsoid html2wt
860 Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
862 ''<nowiki>foo'</nowiki>'''bar'''''
864 <p><i>foo'<b>bar</b></i>
870 Italics and bold: multiple quote sequences: (2,4,4)
876 <p><i>foo'<b>bar'</b></i>
881 # same html as previous, but wikitext adjusted to match parsoid html2wt
883 Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
885 ''<nowiki>foo'</nowiki>'''<nowiki>bar'</nowiki>'''''
887 <p><i>foo'<b>bar'</b></i>
892 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
894 Italics and bold: multiple quote sequences: (3,4,2)
903 <p><b>foo'</b>bar<i></i>
907 # same html as previous, but wikitext adjusted to match parsoid html2wt
909 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
913 '''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
918 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
923 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
925 Italics and bold: multiple quote sequences: (3,4,3)
934 <p><b>foo'</b>bar<b></b>
938 # same html as previous, but wikitext adjusted to match parsoid html2wt
940 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
942 '''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
947 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
952 ### other quote tests
955 Italics and bold: other quote tests: (2,3,5)
957 ''this is about '''foo's family'''''
959 <p><i>this is about <b>foo's family</b></i>
965 Italics and bold: other quote tests: (2,(3,3),2)
967 ''this is about '''foo's''' family''
969 <p><i>this is about <b>foo's</b> family</i>
975 Italics and bold: other quote tests: (3,2,3,2)
979 '''this is about ''foo'''s family''
981 <p><b>this is about <i>foo</i></b><i>s family</i>
986 # same html as previous, but wikitext adjusted to match parsoid html2wt
987 # add 'parsoid' option to use 'parsoid' normalization of the placeholder
989 Italics and bold: other quote tests: (3,2,3+2+2,2)
993 '''this is about ''foo'''''<nowiki/>''s family''
995 <p><b>this is about <i>foo</i></b><i>s family</i>
1001 Italics and bold: other quote tests: (3,2,3,3)
1004 '''this is about ''foo'''s family'''
1006 <p>'<i>this is about </i>foo<b>s family</b>
1012 Italics and bold: other quote tests: (3,(2,2),3)
1014 '''this is about ''foo's'' family'''
1016 <p><b>this is about <i>foo's</i> family</b>
1022 Italicized possessive
1024 The ''[[Main Page]]'''s talk page.
1026 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
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
1042 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
1043 <td><i>a</i></td><td><i>b</i></td></tr>
1052 Non-html5 tags should be accepted
1054 <center>''foo''</center>
1056 <font>''foo''</font>
1057 <strike>''foo''</strike>
1060 <center><i>foo</i></center>
1061 <p><big><i>foo</i></big>
1062 <font><i>foo</i></font>
1063 <strike><i>foo</i></strike>
1069 <wbr> is valid wikitext (bug 52468)
1077 # <strike> is HTML4, <s> is HTML4/5.
1079 <s> or <strike> for strikethrough
1081 <strike>strike</strike>
1085 <p><strike>strike</strike>
1093 Text-level semantic html elements in wikitext
1096 <strong>text</strong>
1112 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1119 <strong>text</strong>
1135 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1143 # test cases taken from
1144 # http://www.w3.org/TR/html5/text-level-semantics.html#the-ruby-element
1146 Ruby markup (W3C-style)
1148 ; Mono-ruby for individual base characters
1149 : <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby>
1151 : <ruby>今日<rt>きょう</rt></ruby>
1153 : <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby>
1155 : <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby>
1157 : <ruby><rb>旧</rb><rb>金</rb><rb>山</rb><rt>jiù</rt><rt>jīn</rt><rt>shān</rt><rtc>San Francisco</rtc></ruby>
1159 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1160 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1161 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1164 <dl><dt> Mono-ruby for individual base characters</dt>
1165 <dd> <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby></dd>
1166 <dt> Group ruby</dt>
1167 <dd> <ruby>今日<rt>きょう</rt></ruby></dd>
1168 <dt> Jukugo ruby</dt>
1169 <dd> <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby></dd>
1170 <dt> Inline ruby</dt>
1171 <dd> <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby></dd>
1172 <dt> Double-sided ruby</dt>
1173 <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>
1175 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1176 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1177 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1183 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
1185 <b→> doesn't work! </b→>
1187 <bä> doesn't work! </bä>
1189 <boo> works fine </boo>
1191 <s.foo>s.foo</s.foo>
1195 <p><b→> doesn't work! </b→>
1196 </p><p><bä> doesn't work! </bä>
1197 </p><p><boo> works fine </boo>
1198 </p><p><s.foo>s.foo</s.foo>
1199 </p><p><sub-ID#1>
1204 Isolated close tags should be treated as literal text (bug 52760)
1211 </p><p><s.foo>s</s>
1216 ### Special characters
1220 Bare pipe character (bug 52363)
1229 Bare pipe character from a template (bug 52363)
1238 ### <nowiki> test cases
1242 <nowiki> unordered list
1244 <nowiki>* This is not an unordered list item.</nowiki>
1246 <p>* This is not an unordered list item.
1253 <nowiki>Lorem ipsum dolor
1261 <p>Lorem ipsum dolor
1274 :There is not nowiki.
1275 :There is <nowiki>nowiki</nowiki>.
1277 #There is not nowiki.
1278 #There is <nowiki>nowiki</nowiki>.
1280 *There is not nowiki.
1281 *There is <nowiki>nowiki</nowiki>.
1283 <dl><dd>There is not nowiki.</dd>
1284 <dd>There is nowiki.</dd></dl>
1285 <ol><li>There is not nowiki.</li>
1286 <li>There is nowiki.</li></ol>
1287 <ul><li>There is not nowiki.</li>
1288 <li>There is nowiki.</li></ul>
1293 Entities inside <nowiki>
1295 <nowiki><</nowiki>
1302 Entities inside template parameters
1308 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}}]}'>–</span>
1313 Properly escape nowiki when combined with other wiki markup
1317 <nowiki>* </nowiki></nowiki> tag
1319 <p>* </nowiki> tag</p>
1326 Comments and Indent-Pre
1328 <!-- comment 1 --> asdf
1330 <!-- comment 1 --> asdf
1333 <!-- comment 1 --> asdf
1334 <!-- comment 2 -->xyz
1336 <!-- comment 1 --> asdf
1337 <!-- comment 2 --> xyz
1393 asdf<!-- comment 1 -->jkl
1403 <!-- foo --> b <!-- bar -->
1417 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1423 Comment semantics and delimiters
1425 <!-- --><!----><!-----><!------>
1431 Comment semantics and delimiters, redux
1433 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1434 -- foo -- funky huh? ... -->
1440 Comment semantics and delimiters: directors cut
1442 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1443 everything starting with < followed by !-- until the first -- and > we see,
1444 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1452 Comment semantics: nesting
1454 <!--<!-- no, we're not going to do anything fancy here -->-->
1461 Comment semantics: unclosed comment at end
1463 <!--This comment will run out to the end of the document
1469 Comment in template title
1478 Comment on its own line post-expand
1490 Comment on its own line post-expand with non-significant whitespace
1502 Multiple comments should still parse as SOL-transparent
1504 parsoid=wt2html,wt2wt
1507 <!--c2--><!--c3--><!--c4-->*b
1518 ### paragraph wrapping tests
1533 Block tag on one line (<div>)
1545 Block tag on one line (<blockquote>)
1547 a <blockquote>foo</blockquote>
1551 a <blockquote>foo</blockquote>
1557 Block tag on both lines (<div>)
1569 Block tag on both lines (<blockquote>)
1571 a <blockquote>foo</blockquote>
1573 b <blockquote>foo</blockquote>
1575 a <blockquote>foo</blockquote>
1576 b <blockquote>foo</blockquote>
1581 Multiple lines without block tags
1599 Empty lines between lines with block tags
1628 ## PHP parser emits output which is broken
1630 Unclosed HTML p-tags should be handled properly
1637 <div data-parsoid='{"stx":"html"}'><p data-parsoid='{"stx":"html", "autoInsertedEnd":true}'>foo</p></div>
1643 ### Preformatted text
1652 And a [[Main Page|link]]
1658 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1663 Tabs don't trigger preformatted text
1667 This is preformatted text.
1673 <pre>This is preformatted text.
1679 Ident preformatting with inline content
1690 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1707 Regression with preformatted in <center>
1721 Bug 52763: Preformatted in <blockquote>
1727 indented cell (no pre-wrapping!)
1737 <p> indented cell (no pre-wrapping!)
1745 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
1762 Bug 15491: <ins>/<del> in blockquote
1765 Foo <del>bar</del> <ins>baz</ins> quux
1769 <p>Foo <del>bar</del> <ins>baz</ins> quux
1775 # Note that the p-wrapping is newline sensitive, which could be
1776 # considered a bug: tidy will wrap only the 'Foo' in the example
1777 # below in a <p> tag. (see comment 23-25 of bug #6200)
1779 Bug 15491: <ins>/<del> in blockquote (2)
1781 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1784 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1790 <pre> with attributes (bug 3202)
1792 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1794 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1799 <pre> with width attribute (bug 3202)
1801 <pre width="8">Narrow screen goodies</pre>
1803 <pre width="8">Narrow screen goodies</pre>
1808 <pre> with forbidden attribute (bug 3202)
1810 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1812 <pre width="8">Narrow screen goodies</pre>
1817 Entities inside <pre>
1826 <pre> with forbidden attribute values (bug 3202)
1828 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1830 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1835 <nowiki> inside <pre> (bug 13238)
1843 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1851 <pre><nowiki>Foo</nowiki></pre>
1856 <nowiki> and <pre> preference (first one wins)
1887 </pre> inside nowiki
1889 <nowiki></pre></nowiki>
1896 Empty pre; pre inside other HTML tags (bug 54946)
1915 HTML pre followed by indent-pre
1930 <p><pre>foo</pre></p>
1932 <p data-parsoid='{"stx":"html","autoInsertedEnd":true}'></p><pre data-parsoid='{"stx":"html"}'>foo</pre><p data-parsoid='{"autoInsertedStart":true,"stx":"html"}'></p>
1936 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1944 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1954 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1966 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1987 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1991 {{echo| foo}}{{echo| bar}}
1996 {{echo|<!--cmt--> foo}}
1998 <!--cmt-->{{echo| foo}}
2000 {{echo|{{echo| }}bar}}
2018 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
2055 Things that look like <pre> tags aren't treated as such
2057 Barack Obama <President> of the United States
2058 <President></President>
2060 <p>Barack Obama <President> of the United States
2061 <President></President>
2065 ## PHP parser discards the "<pre " string
2067 Handle broken pre-like tags (bug 64025)
2071 {{echo|<pre <pre>x</pre>}}
2073 <table><pre </table>
2076 <table><pre></pre></table>
2079 <span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<pre <pre>x</pre>"}},"i":0}}]}'><pre </span>
2082 <span><pre </span>
2087 Parsoid: handle pre with space after attribute
2091 <pre style="width:50%;" >{{echo|foo}}</pre>
2093 <pre style="width:50%;">{{echo|foo}}</pre>
2096 # TODO / maybe: fix wt2wt for this
2098 Parsoid: Don't paragraph-wrap fosterable content
2124 Parsoid: Don't paragraph-wrap fosterable content even if table syntax is unbalanced
2152 #--------------------------------------------------------------------
2153 # Transclusion parameter whitespace stripping tests
2154 # Behavior is different for positional and named parameters
2155 #--------------------------------------------------------------------
2157 Templates: Strip leading and trailing whitespace from named-param values
2161 {{echo|1= {{echo|b}} }}
2174 <ul><li> d</li></ul>
2179 Templates: Don't strip whitespace from positional-param values
2183 {{echo|{{echo|b}} }}
2215 <ul><li> f</li></ul>
2223 Templates: Handle empty comment-and-ws-only lines correctly
2226 <!--should be ignored-->
2227 <!--should be ignored as well-->
2236 Templates: Handle comments in the target
2239 <!-- should be ignored -->
2242 {{echo<!-- should be ignored -->
2245 {{echo<!-- should be ignored -->|foo}}
2247 {{<!-- should be ignored -->echo|foo}}
2249 <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>
2251 <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>
2253 <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>
2255 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2258 #--------------------------------------------------------------------
2259 # Transclusion parameter escaping tests
2260 #--------------------------------------------------------------------
2262 Templates: Parsoid parameter escaping test 1
2266 {{echo|[foo]|{{echo|[bar]}}}}
2268 <p about="#mwt1" typeof="mw:Transclusion"
2269 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}}]}'>[foo]</p>
2273 Parsoid: Pipes in external links in template parameter
2277 {{echo|[{{echo|http://example.com}} link]}}
2279 <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>
2283 Parsoid: pipe in transclusion parameter
2287 {{echo|http://foo.com/a|b}}
2289 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2290 typeof="mw:Transclusion"
2291 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>
2295 Parsoid: Pipe in external link target and content in template parameter
2297 parsoid=html2wt,wt2wt
2299 {{echo|[http://foo.com/a|b a|b]}}
2301 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2302 typeof="mw:Transclusion"
2303 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},
2304 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}}]}'>a|b</a></p>
2308 Parsoid: Pipe in template with nested template in external link target in template parameter (seriously)
2312 {{echo|[{{fullurl:{{FULLPAGENAME}}|action=edit}} bar]}}
2314 <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>
2318 Templates: Don't escape already nowiki-escaped text in template parameters
2320 parsoid=html2wt,wt2wt
2322 {{echo|foo<nowiki>|</nowiki>bar}}
2323 {{echo|<nowiki><div></nowiki>}}
2324 {{echo|<nowiki></nowiki>}}
2326 <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>
2327 <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>
2328 <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>
2334 Templates: '=' char in nested transclusions should not trigger nowiki escapes or conversion to named param
2336 parsoid=html2wt,wt2wt
2338 {{echo|{{echo|1=bar}}}}
2340 <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>
2345 Templates parameters with special tokenizing behavior dont get modified because of arg escaping
2351 <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>
2355 ### Parsoid-centric tests for testing RT edge cases for pre
2359 1a. Indent-Pre and Comments
2372 1b. Indent-Pre and Comments
2385 1c. Indent-Pre and Comments
2398 1d. Indent-Pre and Comments
2399 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
2412 2a. Indent-Pre and tables
2433 2b. Indent-Pre and tables
2449 2c. Indent-Pre and tables (bug 42252)
2466 2d. Indent-Pre and tables
2492 2e. Indent-Pre and table-line syntax
2504 2f. Indent-pre started by table-line syntax
2517 3a. Indent-Pre and block tags (single-line html)
2521 c <blockquote> foo </blockquote>
2526 c <blockquote> foo </blockquote>
2527 <pre><span> foo </span>
2532 3b. Indent-Pre and block tags (multi-line html)
2537 <pre>a <span>foo</span>
2544 3c. Indent-Pre and block tags (pre-content on separate line)
2608 4. Indent-Pre and extension tags
2614 a <ul class="gallery mw-gallery-traditional">
2615 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
2616 <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>
2617 <div class="gallerytext">
2625 Table wikitext syntax outside wiki-tables
2628 ! not a table heading
2631 | class="foo bar" | baz
2638 ! not a table heading
2641 | class="foo bar" | baz
2650 Render paragraphs when indent-pre is suppressed in blocklevels
2667 4. Multiple spaces at start-of-line
2685 ## NOTE: the leading white-space chars on empty line are significant
2687 5a. White-space in indent-pre
2699 ## NOTE: the leading white-space chars on empty line are significant
2701 5b. White-space in indent-pre
2720 5c. White-space in indent-pre
2733 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
2756 7a. Indent-pre and category links
2758 parsoid=wt2html,wt2wt
2760 [[Category:foo]] <!-- No pre-wrapping -->
2761 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
2763 <link rel="mw:PageProp/Category" href="./Category:Foo"> <!-- No pre-wrapping -->
2764 <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":" [[Category:foo]]"}},"i":0}}]}'> </span>
2765 <link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1"> <!-- No pre-wrapping -->
2769 7b. Indent-pre and category links
2771 parsoid=wt2html,wt2wt
2774 [[Category:foo]] {{echo|b}}
2777 <link rel="mw:PageProp/Category" href="./Category:Foo"> a
2779 <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>
2783 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
2787 HTML-pre: 1. embedded newlines
2821 <pre data-parsoid='{"stx":"html"}'>foo</pre>
2823 <pre data-parsoid='{"stx":"html","strippedNL":"\n"}'>
2827 <pre data-parsoid='{"stx":"html"}'>
2832 <pre data-parsoid='{"stx":"html"}'>
2840 HTML-pre: big spaces
2877 <pre data-parsoid='{"stx":"html"}'>
2896 HTML-pre: 2: indented text
2909 HTML-pre: 3: other wikitext
2930 ### Definition lists
2937 <dl><dt> name </dt>
2938 <dd> Definition</dd></dl>
2943 Definition list for indentation only
2947 <dl><dd> Indented text</dd></dl>
2952 Definition list with no space
2957 <dd>Definition</dd></dl>
2962 Definition list with URL link
2964 ; http://example.com/ : definition
2966 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt>
2967 <dd> definition</dd></dl>
2972 Definition list with bracketed URL link
2974 ;[http://www.example.com/ Example]:Something about it
2976 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt>
2977 <dd>Something about it</dd></dl>
2982 Definition list with wikilink containing colon
2984 ; [[Help:FAQ]]: The least-read page on Wikipedia
2986 <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>
2987 <dd> The least-read page on Wikipedia</dd></dl>
2991 # At Brion's and JeLuF's insistence... :)
2993 Definition list with news link containing colon
2995 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
2997 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt>
2998 <dd> This isn't even a real newsgroup!</dd></dl>
3003 Malformed definition list with colon
3005 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
3007 <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>
3012 Definition lists: colon in external link text
3014 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
3016 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt>
3017 <dd> OK, I made that up</dd></dl>
3022 Definition lists: colon in HTML attribute
3024 ;<b style="display: inline">bold</b>
3026 <dl><dt><b style="display: inline">bold</b></dt></dl>
3031 Definition lists: self-closed tag
3033 ;one<br/>two : two-line fun
3035 <dl><dt>one<br />two </dt>
3036 <dd> two-line fun</dd></dl>
3041 Bug 11748: Literal closing tags
3045 <dd>test test test test test</dd>
3047 <dd>test test test test test</dd>
3052 <dd>test test test test test</dd>
3054 <dd>test test test test test</dd>
3060 Definition and unordered list using wiki syntax nested in unordered list using html tags.
3063 ; term : description
3068 <dl><dt> term </dt>
3069 <dd> description</dd></dl>
3070 <ul><li> unordered</li></ul>
3077 Definition list with empty definition and following paragraph
3089 Nested definition lists using html syntax
3098 Definition Lists: No nesting: Multiple dd's
3111 Definition Lists: Indentation: Regular
3119 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3124 Definition Lists: Indentation: Missing 1st level
3130 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3135 Definition Lists: Indentation: Multi-level indent
3139 <dl><dd><dl><dd><dl><dd>i3</dd></dl></dd></dl></dd></dl>
3144 Definition Lists: Hacky use to indent tables
3151 should be left alone
3153 <dl><dd><dl><dd><table>
3158 </td></tr></table></dd></dl></dd></dl>
3160 should be left alone
3165 Definition Lists: Hacky use to indent tables, with comments (bug 63979)
3173 should be left alone
3176 <dl><dd><dl><dd><table><tr>
3179 </tr></table><!-- bar --></dd></dl></dd></dl>
3181 should be left alone</p>
3185 Definition Lists: Hacky use to indent tables, with comment before table
3191 <dl><dd><dl><dd><!-- foo --><table><tr>
3193 </tr></table></dd></dl></dd></dl>
3198 Definition Lists: Hacky use to indent tables (WS-insensitive)
3207 <dd> <table><tr><td>a</td></tr></table> </dd>
3210 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
3211 ## as an empty dt item. It also ignores all but the last ";" when followed
3212 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
3213 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
3216 ## Ex: ";;t2 ::d2" is transformed into:
3228 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
3229 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
3240 ## All Parsoid only definition list tests have this difference.
3242 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
3243 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
3246 Table / list interaction: indented table with lists in table contents
3261 <ul><li> b</li></ul>
3265 <ul><li> d</li></ul>
3266 </td></tr></table></dd></dl>
3271 Table / list interaction: lists nested in tables nested in indented lists
3294 </td></tr></table></dd></dl>
3301 Definition Lists: Nesting: Multi-level (Parsoid only)
3331 Definition Lists: Nesting: Test 2 (Parsoid only)
3351 Definition Lists: Nesting: Test 3 (Parsoid only)
3379 Definition Lists: Nesting: Test 4
3384 <dl><dd><dl><dd><dl><dt>t3</dt>
3385 <dd>d3</dd></dl></dd></dl></dd></dl>
3390 ## The Parsoid team believes the following three test exposes a
3391 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
3392 ## wrong to close the <dl> after the <dt> containing the <ul>.)
3394 Definition Lists: Mixed Lists: Test 1
3400 <dl><dd><dl><dt><ul><li> foo</li>
3401 <li> bar</li></ul></dt></dl>
3402 <dl><dt> baz</dt></dl></dd></dl>
3421 Definition Lists: Mixed Lists: Test 2
3426 <ul><li><dl><dd> d1</dd>
3427 <dd> d2</dd></dl></li></ul>
3433 Definition Lists: Mixed Lists: Test 3
3438 <ul><li><dl><dd><dl><dd><dl><dd> d1</dd>
3439 <dd> d2</dd></dl></dd></dl></dd></dl></li></ul>
3445 Definition Lists: Mixed Lists: Test 4
3450 <ul><li><dl><dt>d1 </dt>
3453 <dd>d4</dd></dl></li></ul>
3459 Definition Lists: Mixed Lists: Test 5
3465 <dl><dd> d2</dd></dl></dd></dl></li></ul>
3471 Definition Lists: Mixed Lists: Test 6
3476 <ol><li><ul><li><dl><dd>d1
3477 <dl><dd><dl><dd> d3</dd></dl></dd></dl></dd></dl></li></ul></li></ol>
3483 Definition Lists: Mixed Lists: Test 7
3488 <dl><dd><ul><li> d1</li>
3489 <li> d2</li></ul></dd></dl>
3495 Definition Lists: Mixed Lists: Test 8
3500 <dl><dd><ul><li> d1</li></ul>
3501 <dl><dd><ul><li> d2</li></ul></dd></dl></dd></dl>
3507 Definition Lists: Mixed Lists: Test 9
3511 <ul><li><dl><dt>foo </dt>
3512 <dd>bar</dd></dl></li></ul>
3518 Definition Lists: Mixed Lists: Test 10
3522 <ul><li><ol><li><dl><dt>foo </dt>
3523 <dd>bar</dd></dl></li></ol></li></ul>
3527 # The Parsoid team disagrees with the PHP parser's seemingly-random
3528 # rules regarding dd/dt on the next two tests. Parsoid is more
3529 # consistent, and recognizes the shared nesting and keeps the
3530 # still-open tags around until the nesting is complete.
3533 Definition Lists: Mixed Lists: Test 11
3538 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt>
3539 <dd><ul><li><dl><dt><dl><dt>bar</dt></dl></dd></dl></li></ul></dd></dl>
3540 <dl><dt>boo </dt>
3541 <dd>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
3559 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3560 <dd data-parsoid='{"stx":"row"}'>bar</dd>
3564 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3565 <dd data-parsoid='{"stx":"row"}'>baz</dd>
3575 Definition Lists: Weird Ones: Test 1
3577 *#;*::;; foo : bar (who uses this?)
3579 <ul><li><ol><li><dl><dt> foo </dt>
3580 <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>
3598 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3599 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd>
3614 External links: non-bracketed
3616 Non-bracketed: http://example.com
3618 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3622 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3624 External links: numbered
3626 Numbered: [http://example.com]
3627 Numbered: [http://example.net]
3628 Numbered: [http://example.com]
3630 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
3631 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
3632 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
3635 <p>Numbered: <a rel="mw:ExtLink" href="http://example.com"></a>
3636 Numbered: <a rel="mw:ExtLink" href="http://example.net"></a>
3637 Numbered: <a rel="mw:ExtLink" href="http://example.com"></a></p>
3641 External links: specified text
3643 Specified text: [http://example.com link]
3645 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
3650 External links: trail
3652 Linktrails should not work for external links: [http://example.com link]s
3654 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
3659 External links: dollar sign in URL
3661 http://example.com/1$2345
3663 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
3667 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3669 External links: dollar sign in URL (autonumber)
3671 [http://example.com/1$2345]
3673 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
3676 <p><a rel="mw:ExtLink" href="http://example.com/1$2345"></a></p>
3680 External links: open square bracket forbidden in URL (bug 4377)
3682 parsoid=wt2html,wt2wt,html2html
3684 http://example.com/1[2345
3686 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
3689 <p><a rel="mw:ExtLink" href="http://example.com/1">http://example.com/1</a>[2345</p>
3693 External links: open square bracket forbidden in URL (named) (bug 4377)
3695 parsoid=wt2html,html2html
3697 [http://example.com/1[2345]
3699 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
3702 <p><a rel="mw:ExtLink" href="http://example.com/1">[2345</a></p>
3705 # parsoid adds a space before the link name
3707 External links: open square bracket forbidden in URL (named) (bug 4377)
3710 [http://example.com/1 [2345]
3712 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
3717 External links: nowiki in URL link text (bug 6230)
3719 [http://example.com/ <nowiki>''example site''</nowiki>]
3721 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
3726 External links: newline forbidden in text (bug 6230 regression check)
3728 [http://example.com/ first
3731 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
3737 External links: Pipe char between url and text
3739 [http://example.com | link]
3741 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
3746 External links: protocol-relative URL in brackets
3748 [//example.com/ Test]
3750 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
3754 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3756 External links: protocol-relative URL in brackets without text
3760 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
3763 <p><a rel="mw:ExtLink" href="//example.com"></a></p>
3767 External links: protocol-relative URL in free text is left alone
3771 <p>//example.com/Foo
3776 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
3778 foo//example.com/Foo
3780 <p>foo//example.com/Foo
3785 External links: with no contents
3787 [http://en.wikipedia.org/wiki/Foo]
3789 [[wikipedia:Foo|Bar]]
3791 [[wikipedia:Foo|<span>Bar</span>]]
3793 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo"></a></p>
3794 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo">Bar</a></p>
3795 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo"><span>Bar</span></a></p>
3801 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3803 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
3808 External image from https
3810 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3812 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
3817 External image (when not allowed)
3819 wgAllowExternalImages=0
3821 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3823 <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>
3828 Link to non-http image, no img tag
3830 Link to non-http image, no img tag: ftp://example.com/test.jpg
3832 <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>
3837 External links: terminating separator
3839 Terminating separator: http://example.com/thing,
3841 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
3846 External links: intervening separator
3848 Intervening separator: http://example.com/1,2,3
3850 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
3855 External links: old bug with URL in query
3857 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
3859 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
3864 External links: old URL-in-URL bug, mixed protocols
3866 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
3868 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
3873 External links: URL in text
3875 URL in text: [http://example.com http://example.com]
3877 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3882 External links: Clickable images
3884 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
3886 <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>
3891 External links: raw ampersand
3893 Old & use: http://x&y
3895 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3900 External links: encoded ampersand
3902 Old & use: http://x&y
3904 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3907 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y">http://x&y</a></p>
3911 External links: encoded equals (bug 6102)
3913 http://example.com/?foo=bar
3915 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
3918 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a></p>
3922 ## Note that parsoid doesn't explicit mark autonumbered links, nor
3923 ## does it number them. As discussed in bug 53505, we can identify
3924 ## autonumbered links via CSS.
3928 External links: [raw ampersand]
3930 Old & use: [http://x&y]
3932 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3935 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
3938 # note that parsoid html is identical to [raw ampersand] case; so html2wt
3939 # mode will return the [raw ampersand] wikitext
3941 External links: [encoded ampersand]
3943 parsoid=wt2html,wt2wt,html2html
3945 Old & use: [http://x&y]
3947 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3950 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
3954 External links: [raw equals]
3956 [http://example.com/?foo=bar]
3958 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3961 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
3964 # note that parsoid html is identical to [raw equals] case; so html2wt
3965 # mode will return the [raw equals] wikitext
3967 External links: [encoded equals] (bug 6102)
3969 parsoid=wt2html,wt2wt,html2html
3971 [http://example.com/?foo=bar]
3973 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3976 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
3979 # xxx parsoid strips the IDN character, so the round-trip tests will
3980 # obviously fail and are disabled. --cscott
3982 External links: [IDN ignored character reference in hostname; strip it right off]
3984 parsoid=wt2html,wt2wt,html2html
3986 [http://e‌xample.com/]
3988 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
3991 <p><a rel="mw:ExtLink" href="http://example.com/"></a></p>
3994 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
3995 # Where an external link could easily circumvent the sanitization of the text of
3996 # a link like this (where an IDN-ignore character is in the URL somewhere), this
3997 # test demands a higher standard. That's a bit strange.
4001 # http://example.com -> [http://example.com|http://example.com]
4002 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
4004 # The first example is sanitized, but the second is not. Any security benefits
4005 # from this production are trivial to circumvent. Either remove this test and
4006 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
4007 # the test accordingly.
4011 # xxx parsoid strips the IDN character, so the round-trip tests will
4012 # obviously fail and are disabled. --cscott
4014 External links: IDN ignored character reference in hostname; strip it right off
4016 parsoid=wt2html,html2html
4018 http://e‌xample.com/
4020 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
4023 <p><a rel="mw:ExtLink" href="http://example.com/">http://example.com/</a></p>
4027 External links: www.jpeg.org (bug 554)
4031 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
4035 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4037 External links: URL within URL (original bug 2)
4039 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
4041 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
4044 <p><a rel="mw:ExtLink" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp"></a></p>
4048 BUG 361: URL inside bracketed URL
4050 [http://www.example.com/foo http://www.example.com/bar]
4052 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
4057 BUG 361: URL within URL, not bracketed
4059 http://www.example.com/foo?=http://www.example.com/bar
4061 <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>
4066 BUG 289: ">"-token in URL-tail
4068 http://www.example.com/<hello>
4070 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
4075 BUG 289: literal ">"-token in URL-tail
4077 http://www.example.com/<b>html</b>
4079 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
4084 BUG 289: ">"-token in bracketed URL
4086 [http://www.example.com/<hello> stuff]
4088 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
4093 BUG 289: literal ">"-token in bracketed URL
4095 [http://www.example.com/<b>html</b> stuff]
4097 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
4102 BUG 289: literal double quote at end of URL
4104 http://www.example.com/"hello"
4106 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
4111 BUG 289: literal double quote in bracketed URL
4113 [http://www.example.com/"hello" stuff]
4115 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
4120 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
4122 [http://www.example.com test]
4124 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
4129 External links: link text with spaces
4131 [http://www.example.com a b c]
4132 [http://www.example.com ''a'' ''b'']
4134 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
4135 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
4140 External links: wiki links within external link (Bug 3695)
4142 [http://example.com [[wikilink]] embedded in ext link]
4144 <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>
4147 <p><a rel="mw:ExtLink" href="http://example.com"></a><a rel="mw:WikiLink" href="./Wikilink">wikilink</a><span> embedded in ext link</span></p>
4151 BUG 787: Links with one slash after the url protocol are invalid
4155 [http:/example.com title]
4157 <p>http:/example.com
4158 </p><p>[http:/example.com title]
4163 Bracketed external links with template-generated invalid target
4165 [{{echo|http:/example.com}} title]
4167 <p>[http:/example.com title]
4172 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
4174 ''[http://example.com text'']
4175 [http://example.com '''text]'''
4176 ''Something [http://example.com in italic'']
4177 ''Something [http://example.com mixed''''', even bold]'''
4178 '''''Now [http://example.com both''''']
4180 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
4181 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
4182 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
4183 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
4184 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
4190 Bug 4781: %26 in URL
4192 http://www.example.com/?title=AT%26T
4194 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
4197 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a></p>
4200 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
4201 # % is actually legal in HTML5. Any change in output would need testing though.
4203 Bug 4781, 5267: %25 in URL
4205 http://www.example.com/?title=100%25_Bran
4207 <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>
4210 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a></p>
4214 Bug 4781, 5267: %28, %29 in URL
4216 http://www.example.com/?title=Ben-Hur_%281959_film%29
4218 <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>
4221 <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>
4226 Bug 4781: %26 in autonumber URL
4228 [http://www.example.com/?title=AT%26T]
4230 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
4233 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T"></a></p>
4237 Bug 4781, 5267: %26 in autonumber URL
4239 [http://www.example.com/?title=100%25_Bran]
4241 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
4244 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran"></a></p>
4248 Bug 4781, 5267: %28, %29 in autonumber URL
4250 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
4252 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
4255 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29"></a></p>
4260 Bug 4781: %26 in bracketed URL
4262 [http://www.example.com/?title=AT%26T link]
4264 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
4267 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">link</a></p>
4271 Bug 4781, 5267: %25 in bracketed URL
4273 [http://www.example.com/?title=100%25_Bran link]
4275 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
4280 Bug 4781, 5267: %28, %29 in bracketed URL
4282 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
4284 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
4287 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a></p>
4291 External link containing a period in the anchor. (bug 63947)
4293 [//foo.org/bar#baz. bang]
4295 [//foo.org/bar. bang]
4297 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4298 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4301 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4302 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4306 External link containing a single quote. (bug 63947)
4310 [//foo.org/bar'baz bang]
4312 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4313 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4316 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4317 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4322 External link containing a period in the anchor. (bug 63947)
4324 [//foo.org/bar#baz. bang]
4326 [//foo.org/bar. bang]
4328 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4329 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4332 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4333 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4337 External link containing a single quote. (bug 63947)
4341 [//foo.org/bar'baz bang]
4343 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4344 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4347 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4348 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4353 External link containing double-single-quotes in text '' (bug 4598 sanity check)
4355 Some [http://example.com/ pretty ''italics'' and stuff]!
4357 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
4362 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
4364 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
4366 <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>
4371 External link containing double-single-quotes with no space separating the url from text in italics
4373 [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]].]
4375 <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>
4378 <p><a rel="mw:ExtLink" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de </a><a rel="mw:WikiLink" href="./Museo_Picasso_(París)">Museo Picasso</a><span>.</span></p>
4382 External link with comments in link text
4384 [http://www.google.com Google <!-- comment -->]
4386 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
4391 URL-encoding in URL functions (single parameter)
4393 {{localurl:Some page|amp=&}}
4395 <p>/index.php?title=Some_page&amp=&
4400 URL-encoding in URL functions (multiple parameters)
4402 {{localurl:Some page|q=?&=&}}
4404 <p>/index.php?title=Some_page&q=?&amp=&
4411 http://example.com/index.php?foozoid%5B%5D=bar
4413 http://example.com/index.php?foozoid[]=bar
4415 <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>
4416 </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>
4419 <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>
4421 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid[]=bar">http://example.com/index.php?foozoid[]=bar</a></p>
4425 IPv6 urls (bug 21261)
4429 http://[2404:130:0:1000::187:2]/index.php
4431 <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>
4436 Non-extlinks in brackets
4445 [{{echo|foo}} ''bar'']
4446 [{{echo|foo}}l's] errand
4447 [{{echo|foo}}l's errand]
4449 [url=http://example.com]
4462 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
4467 Percent encoding in external links
4469 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
4471 <p><a rel="nofollow" class="external text" href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a>
4474 <p><a rel="mw:ExtLink"
4475 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
4479 Use url link syntax for links where the content is equal the link target
4483 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4486 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
4490 Parenthesis in external links, especially URL links
4494 http://example.com/test)
4496 http://example.com/(test)
4498 http://example.com/((test)
4500 (http://example.com/(test))
4502 (http://example.com/(test)))))
4504 http://example.com/a)b
4506 [http://example.com) foo]
4508 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4509 </p><p><a rel="nofollow" class="external free" href="http://example.com/test">http://example.com/test</a>)
4510 </p><p><a rel="nofollow" class="external free" href="http://example.com/(test)">http://example.com/(test)</a>
4511 </p><p><a rel="nofollow" class="external free" href="http://example.com/((test)">http://example.com/((test)</a>
4512 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test))">http://example.com/(test))</a>
4513 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test)))))">http://example.com/(test)))))</a>
4514 </p><p><a rel="nofollow" class="external free" href="http://example.com/a)b">http://example.com/a)b</a>
4515 </p><p><a rel="nofollow" class="external text" href="http://example.com)">foo</a>
4518 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)</p>
4519 <p><a rel="mw:ExtLink" href="http://example.com/test">http://example.com/test</a>)</p>
4520 <p><a rel="mw:ExtLink" href="http://example.com/(test)">http://example.com/(test)</a></p>
4521 <p><a rel="mw:ExtLink" href="http://example.com/((test)">http://example.com/((test)</a></p>
4522 <p>(<a rel="mw:ExtLink" href="http://example.com/(test))">http://example.com/(test))</a></p>
4523 <p>(<a rel="mw:ExtLink" href="http://example.com/(test)))))">http://example.com/(test)))))</a></p>
4524 <p><a rel="mw:ExtLink" href="http://example.com/a)b">http://example.com/a)b</a></p>
4525 <p><a rel="mw:ExtLink" href="http://example.com)">foo</a></p>
4529 Parenthesis in external links, w/ transclusion or comment
4531 (http://example.com/{{echo|hi}})
4533 (http://example.com<!-- hi -->)
4535 <p>(<a rel="nofollow" class="external free" href="http://example.com/hi">http://example.com/hi</a>)
4536 </p><p>(<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4539 <p>(<a data-mw='{"attribs":[[{"txt":"href"},{"html":"http://example.com/<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;hi&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;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]}\">hi</span>"}]]}' typeof="mw:ExpandedAttrs" about="#mwt2" rel="mw:ExtLink" href="http://example.com/hi" data-parsoid='{"stx":"url","a":{"href":"http://example.com/hi"},"sa":{"href":"http://example.com/{{echo|hi}}"}}'>http://example.com/hi</a>)</p>
4541 <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>
4545 Replace invalid link targets when serializing
4549 <a rel="mw:WikiLink" href="./]] foo [[bar">Manual</a>
4551 [[MediaWiki:Badtitletext|Manual]]
4561 Normal text. '''Bold text.''' Normal text. ''Italic text.''
4563 Normal text. '''''Bold italic text.''''' Normal text.
4565 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
4566 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
4571 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
4572 # parser strips. The wikitext contains just the first half of the bold
4575 Unclosed and unmatched quotes
4577 '''''Bold italic text '''with bold deactivated''' in between.'''''
4579 '''''Bold italic text ''with italic deactivated'' in between.'''''
4583 ..spanning two paragraphs (should not work).'''
4585 '''Bold tag left open
4587 ''Italic tag left open
4591 <!-- Unmatching number of opening, closing tags: -->
4592 '''This year''''s election ''should'' beat '''last year''''s.
4594 ''Tom'''s car is bigger than ''Susan'''s.
4596 Plain ''italic'''s plain
4598 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
4599 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
4600 </p><p><b>Bold text..</b>
4601 </p><p>..spanning two paragraphs (should not work).
4602 </p><p><b>Bold tag left open</b>
4603 </p><p><i>Italic tag left open</i>
4605 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
4606 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
4607 </p><p>Plain <i>italic'</i>s plain
4610 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
4611 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
4612 </p><p><b>Bold text..</b>
4613 </p><p>..spanning two paragraphs (should not work).<b></b>
4614 </p><p><b>Bold tag left open</b>
4615 </p><p><i>Italic tag left open</i>
4617 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
4618 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
4619 </p><p>Plain <i>italic'</i>s plain
4626 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
4629 # This should not produce <table></table> as <table><tr><td></td></tr></table>
4630 # is the bare minimum required by the spec, see:
4631 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
4632 # Parsoid team replies: empty table tags are legal in HTML5
4634 A table with no data.
4647 A table with stray table end tags on start tag line (wt2html)
4651 {|style="color: red;"|}
4653 {|style="color: red;" |}
4657 {|style="color: red;"|} id="foo"
4661 {|style="color: red;" |} id="foo"
4665 <table style="color: red;"></table>
4667 <table style="color: red;">
4673 <table style="color: red;" id="foo">
4679 <table style="color: red;" id="foo">
4688 A table with no data (take 2)
4696 # A table with nothing but a caption is invalid XHTML, we might want to render
4697 # this as <p>caption</p>
4698 # Parsoid team replies: table with only a caption is legal in HTML5
4700 A table with nothing but a caption
4708 </caption><tr><td></td></tr></table>
4711 <table><caption> caption</caption></table>
4715 A table with caption with default-spaced attributes and a table row
4718 |+ style="color: red;" | caption1
4724 <caption style="color: red;"> caption1
4733 A table with captions with non-default spaced attributes and a table row
4736 |+style="color: red;"|caption2
4737 |+ style="color: red;"| caption3
4743 <caption style="color: red;">caption2
4745 <caption style="color: red;"> caption3
4754 Table td-cell syntax variations
4758 | foo bar foo || baz
4759 | style='color:red;' | baz
4760 | style='color:red;' || baz
4767 <td> foo bar foo </td>
4770 <td style="color:red;"> baz
4772 <td> style='color:red;' </td>
4800 Simple table but with multiple dashes for row wikitext
4818 Multiplication table
4820 {| border="1" cellpadding="2"
4821 |+Multiplication table
4823 ! × !! 1 !! 2 !! 3
4841 <table border="1" cellpadding="2">
4842 <caption>Multiplication table
4889 Accept "||" in table headings
4904 Accept "!!" in table data
4910 <table data-parsoid='{}'>
4911 <tbody data-parsoid='{}'><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'> Foo!! </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'></td></tr>
4916 Accept "||" in indented table headings
4926 </th></tr></table></dd></dl>
4931 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
4948 Accept "| !" at start of line in tables (ignore !-attribute)
4952 | !style="color:red" | bar
4964 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 +/-
4968 |style='color:red;'|+1
4969 |style='color:blue;'|-1
4981 <td style="color:red;">+1
4983 <td style="color:blue;">-1
5007 |rowspan=2| Cell 2, row 1 (and 2)
5018 <td rowspan="2"> Cell 2, row 1 (and 2)
5036 {| bgcolor=#ABCDEF border=2
5041 |the original table again
5049 <table bgcolor="#ABCDEF" border="2">
5057 <td>the original table again
5063 Invalid attributes in table cell (bug 1830)
5077 # The "|}" to close the table is missing from the input, so parsoid's
5078 # *2wt modes will fail.
5080 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
5082 parsoid=wt2html,html2html
5085 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
5089 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
5090 <td>]" onmouseover="alert(document.cookie)">test
5098 <td><a rel="mw:ExtLink" href="ftp://|x||"></a>" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
5103 Indented table markup mixed with indented pre content (proposed in bug 6200)
5108 Text that should be rendered preformatted
5116 <pre>Text that should be rendered preformatted
5125 Template-generated table cell attributes and cell content
5134 <td style="color: red"> Foo
5136 <td style="color: red"> Foo
5142 Template-generated table cell attributes and cell content (2)
5145 |align=center {{table_attribs}}
5150 <td align="center" style="color: red"> Foo
5156 Template-generated table cell attributes and cell content (3)
5159 |align=center {{table_cells}}
5164 <td align="center" style="color: red"> Foo </td>
5172 Table with row followed by newlines and table heading
5190 Table with empty line following the start tag
5207 # FIXME: Preserve the attribute properly (with an empty string as value) in
5208 # the PHP parser. Parsoid implements the behavior below.
5210 Table attributes with empty value
5220 </td></tr></tbody></table>
5225 Wikitext table with a lot of comments
5248 Wikitext table with double-line table cell
5265 Table cell with a single comment
5282 Table-cell after a comment-only-empty-line
5291 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>a</td>
5293 <!--c2--><td data-parsoid='{"autoInsertedEnd":true}'> b</td></tr>
5298 # The expected HTML structure in this test is debatable. The PHP parser does
5299 # not parse this kind of table at all. The main focus for Parsoid is on
5300 # round-tripping, so this output is ok for now. TODO: revisit!
5302 Wikitext table with html-syntax row
5312 <td>foo</td></tr></tbody></table>
5316 Implicit <td> after a |-
5317 (PHP parser relies on Tidy to add the missing <td> tags)
5319 parsoid=wt2html,wt2wt
5332 Pres should be recognized in an explicit <td> context, but not in an implicit <td> context
5333 (PHP parser relies on Tidy to add the missing <td> tags)
5335 parsoid=wt2html,wt2wt
5347 <tr><td><pre>a</pre></td></tr>
5348 <tr><td> b</td></tr>
5354 Lists should be recognized in an implicit <td> context
5355 (PHP parser relies on Tidy to add the missing <td> tags)
5357 parsoid=wt2html,wt2wt
5374 Parsoid: Round-trip tables directly followed by content (bug 51219)
5376 parsoid=wt2html,wt2wt
5388 <td>foo</td></tr></tbody></table> bar
5392 <td>baz</td></tr></tbody></table><b>quux</b>
5396 Parsoid: Default to a newline after tables in new content (bug 51219)
5403 <nowiki> </nowiki>bar
5410 <tr><td>foo</td></tr></tbody></table> bar
5412 <tr><td>baz</td></tr></tbody></table><b>quux</b>
5416 Parsoid: newline inducing block nodes don't suppress <nowiki>
5428 Parsoid: Row-syntax table headings followed by comment & table cells
5430 parsoid=wt2html,wt2wt
5434 <!-- foo --> || baz || quux
5439 <tr><th>foo </th><th>bar </th>
5441 <td>quux</td></tr></tbody></table>
5446 Parsoid: Recover better from broken table attributes
5458 <p>foo</p></td></tr>
5463 Strip unsupported table tags
5514 Plain link, capitalized
5518 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5523 Plain link, uncapitalized
5527 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
5534 [[Main Page|The Main Page]]
5536 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
5541 Piped link with comment in link text
5543 [[Main Page|The Main<!--front--> Page]]
5545 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
5550 Piped link with multiple pipe characters in link text
5552 [[Main Page||The|Main|Page|]]
5554 <p><a href="/wiki/Main_Page" title="Main Page">|The|Main|Page|</a>
5557 <p><a rel="mw:WikiLink" href="Main_Page">|The|Main|Page|</a></p>
5565 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
5570 Broken link with fragment
5572 [[Zigzagzogzagzig#zug]]
5574 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
5579 Special page link with fragment
5581 [[Special:Version#anchor]]
5583 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
5588 Nonexistent special page link with fragment
5590 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
5592 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
5599 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
5601 <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>
5608 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
5610 <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>!!!
5621 Bug 43661: Piped links with identical prefixes
5623 [[prefixed article|prefixed articles with spaces]]
5625 [[prefixed article|prefixed articlesaoeu]]
5627 [[Main Page|Main Page test]]
5629 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
5630 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
5631 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
5637 Link with HTML entity in suffix / tail
5639 [[Main Page]]", [[Main Page]]a
5641 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
5646 Link with 3 brackets
5655 Link with 4 brackets
5659 <p>[[<a href="/wiki/Main_Page" title="Main Page">Main Page</a>]]
5664 Piped link with 3 brackets
5666 [[[main page|the main page]]]
5668 <p>[[[main page|the main page]]]
5673 Piped link with extlink-like text
5676 [[Main Page|This is a [bar]]]
5678 <p><a href="/wiki/Main_Page" title="Main Page">[bar]</a>
5679 <a href="/wiki/Main_Page" title="Main Page">This is a [bar]</a>
5684 Link with multiple pipes
5686 [[Main Page|The|Main|Page]]
5688 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
5692 # Note that parsoid does not munge anchor text; all non-space
5693 # characters are valid in HTML5 ids.
5695 Anchor containing a #. (bug 63430)
5697 [[Main Page#And#Link]]
5699 <p><a href="/wiki/Main_Page#And.23Link" title="Main Page">Main Page#And#Link</a>
5702 <p><a rel="mw:WikiLink" href="./Main_Page#And%23Link">Main Page#And#Link</a></p>
5708 [[Talk:Parser testing]], [[Meta:Disclaimers]]
5710 <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>
5715 Link with space in namespace
5717 [[User talk:Foo bar]]
5719 <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>
5724 MemoryAlpha:AlphaTest
5726 This is an article in the MemoryAlpha namespace
5727 (which shadows the memoryalpha interwiki link).
5731 Namespace takes precedence over interwiki link (bug 51680)
5733 [[MemoryAlpha:AlphaTest]]
5735 <p><a href="/wiki/MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
5739 # The previous test doesn't work correctly in html2*, due to not recognizing the
5740 # link as an internal one. This one checks for the correct behavior.
5742 Link to namespace preferred over interwiki with correct rel attribute
5744 parsoid=html2wt,html2html
5746 [[MemoryAlpha:AlphaTest]]
5748 <p><a rel="mw:WikiLink" href="./MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
5753 Piped link to namespace
5755 [[Meta:Disclaimers|The disclaimers]]
5757 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
5764 [[Usually caused by a typo (oops}]]
5766 <p>[[Usually caused by a typo (oops}]]
5773 Just a test of an article title containing a percent.
5777 Link containing % (not as a hex sequence)
5781 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
5784 <p><a rel="mw:WikiLink" href="./7%25_Solution">7% Solution</a></p>
5787 # note that the parsoid HTML is identical to the previous test output,
5788 # so the previous test ensures that the html2wt mode will generate the
5789 # "not as a hex sequence" wikitext.
5791 Link containing % as a single hex sequence interpreted to char
5793 parsoid=wt2wt,wt2html,html2html
5797 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
5800 <p><a rel="mw:WikiLink" href="./7%25_Solution">7% Solution</a></p>
5804 Link containing % as a double hex sequence interpreted to hex sequence
5808 <p>[[7%2525 Solution]]
5812 # note that parsoid does not munge anchor text; all non-space
5813 # characters are valid in HTML5 anchors.
5815 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
5816 Example for such a section: == < ==
5818 [[%23%3c]][[%23%3e]]
5820 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
5823 <p><a rel="mw:WikiLink" href="./Main%20Page#%3C">#<</a><a rel="mw:WikiLink" href="./Main%20Page#%3E">#></a></p>
5827 Link containing "<#" and ">#" as a hex sequences
5829 [[%3c%23]][[%3e%23]]
5831 <p>[[%3c%23]][[%3e%23]]
5836 Link containing an equals sign
5838 [[Special:BookSources/isbn=4-00-026157-6]]
5840 <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>
5843 <p><a rel="mw:WikiLink" href="./Special:BookSources/isbn=4-00-026157-6">Special:BookSources/isbn=4-00-026157-6</a></p>
5849 Just a test of an article title containing a tilde.
5852 # note that links containing signatures, like [[Foo~~~~]], are
5853 # massaged by the pre-save transform (PST) and so the tildes are never
5854 # seen by the parser.
5856 Link containing a tilde
5860 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
5863 <p><a rel="mw:WikiLink" href="./Foo~bar">Foo~bar</a></p>
5867 Link containing double-single-quotes '' (bug 4598)
5869 [[Lista d''e paise d''o munno]]
5871 <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>
5874 <p><a rel="mw:WikiLink" href="./Lista_d''e_paise_d''o_munno">Lista d''e paise d''o munno</a></p>
5878 Link containing double-single-quotes '' in text (bug 4598 sanity check)
5880 Some [[Link|pretty ''italics'' and stuff]]!
5882 <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>!
5885 <p>Some <a rel="mw:WikiLink" href="Link">pretty <i>italics</i> and stuff</a>!</p>
5889 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
5891 ''Some [[Link|pretty ''italics'' and stuff]]!''
5893 <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>
5898 Link with double quotes in title part (literal) and alternate part (interpreted)
5900 [[File:Denys Savchenko ''Pentecoste''.jpg]]
5904 [[''Pentecoste''|Pentecoste]]
5906 [[''Pentecoste''|''Pentecoste'']]
5908 <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>
5909 </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>
5910 </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>
5911 </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>
5914 <meta typeof="mw:Placeholder"/>
5915 <p><a rel="mw:WikiLink" href="''Pentecoste''">''Pentecoste''</a></p>
5916 <p><a rel="mw:WikiLink" href="''Pentecoste''">Pentecoste</a></p>
5917 <p><a rel="mw:WikiLink" href="''Pentecoste''"><i>Pentecoste</i></a></p>
5921 Broken image links with HTML captions (bug 39700)
5923 [[File:Nonexistent|<script></script>]]
5924 [[File:Nonexistent|100px|<script></script>]]
5925 [[File:Nonexistent|<]]
5926 [[File:Nonexistent|a<i>b</i>c]]
5928 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
5929 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
5930 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
5931 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
5938 [[http://www.example.com]]
5940 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
5943 <p>[<a rel="mw:ExtLink" href="http://www.example.com"></a>]</p>
5947 Plain link to URL with link text
5949 [[http://www.example.com Link text]]
5951 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
5956 Plain link to protocol-relative URL
5958 [[//www.example.com]]
5960 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
5963 <p>[<a rel="mw:ExtLink" href="//www.example.com"></a>]</p>
5967 Plain link to protocol-relative URL with link text
5969 [[//www.example.com Link text]]
5971 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
5976 Plain link to page with question mark in title
5982 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
5983 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
5988 # I'm fairly sure the expected result here is wrong.
5989 # We want these to be URL links, not pseudo-pages with URLs for titles....
5990 # However the current output is also pretty screwy.
5993 # I'm changing it to match the current output--it arguably makes more
5994 # sense in the light of the test above. Old expected result was:
5995 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
5997 # But I think this test is bordering on "garbage in, garbage out" anyway.
6002 Piped link to URL: [[http://www.example.com|an example URL]]
6004 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
6007 <p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com|an">example URL</a>]</p>
6011 BUG 2: [[page|http://url/]] should link to page, not http://url/
6013 [[Main Page|http://url/]]
6015 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
6018 <p><a rel="mw:WikiLink" href="./Main_Page">http://url/</a></p>
6021 # Parsoid does not mark self-links, by design.
6023 BUG 337: Escaped self-links should be bold
6027 [[Bug462]] [[Bug462]]
6029 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
6032 <p><a rel="mw:WikiLink" href="./Bug462">Bug462</a> <a rel="mw:WikiLink" href="./Bug462">Bug462</a></p>
6036 Self-link to section should not be bold
6040 [[Main Page#section]]
6042 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
6053 Self-link to numeric title
6059 <p><strong class="selflink">0</strong>
6064 Link to numeric-equivalent title
6070 <p><a href="/wiki/00" title="00">00</a>
6075 <nowiki> inside a link
6077 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
6079 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
6084 Non-breaking spaces in title
6086 [[ Main Page ]]
6088 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
6093 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
6099 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
6104 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
6110 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
6115 Internal link with en linktrail: no apostrophes (bug 27473)
6121 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
6126 Internal link with ca linktrail with apostrophes (bug 27473)
6132 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
6137 Internal link with kaa linktrail with apostrophes (bug 27473)
6143 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
6148 Link with multiple ":" in a subpage-supporting namespace (bug 63636)
6150 [[User:Foo/Test/63636:Bar|Test]]
6152 <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>
6155 <p><a rel="mw:WikiLink" href="./User:Foo/Test/63636:Bar">Test</a></p>
6159 Purely hash wikilink
6161 title=[[User:test/123]]
6165 <p data-parsoid='{}'><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>
6169 1. Interaction of linktrail and template encapsulation
6175 <p><a rel="mw:WikiLink" href="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
6179 2. Interaction of linktrail and template encapsulation
6183 {{echo|Some [[Fool]]}}s
6185 <p data-parsoid='{}'><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]"}},"i":0}},"s"]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>Some </span><a rel="mw:WikiLink" href="./Fool" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a></p>
6189 3. Interaction of linktrail and template encapsulation
6193 {{echo|Some [[Fool]]s are '''bold and foolish'''}}
6195 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]s are '''bold and foolish'''"}},"i":0}}]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>Some <a rel="mw:WikiLink" href="./Fool" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a> are <b data-parsoid="{}">bold and foolish</b></p>
6205 Internal link with is link prefix
6209 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
6211 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
6222 Internal link with is link trail and link prefix
6226 [[mótmælendatrú|xxx]]ar
6228 mótmælenda[[söfnuður]]
6229 mótmælenda[[söfnuður|söfnuðir]]
6230 mótmælenda[[söfnuður|söfnuðir]]xxx
6232 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
6233 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
6234 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
6235 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
6236 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
6241 Parsoid link trail escaping
6243 parsoid=html2wt,html2html
6247 <p><a rel="mw:WikiLink" href="Apple">apple</a>s</p>
6251 Parsoid link prefix escaping
6254 parsoid=html2wt,html2html
6256 Aðrir mótmælenda<nowiki/>[[söfnuður]]
6258 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður">söfnuður</a></p>
6262 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
6270 [http://wp.org ''foo'']
6272 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
6273 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
6274 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
6275 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
6280 Parsoid: Scoped parsing should handle mixed transclusions and plain text
6284 [[Foo|{{echo|a}} b {{echo|c}}]]
6286 <p><a rel="mw:WikiLink" href="Foo"><span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span> b <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c"}},"i":0}}]}'>c</span></a></p>
6290 Link with angle bracket after anchor
6294 <p><a rel="mw:WikiLink" href="./Foo#%3Cbar%3E" data-parsoid='{"stx":"simple","a":{"href":"./Foo#%3Cbar%3E"},"sa":{"href":"Foo#<bar>"}}'>Foo#<bar></a></p>
6298 ### Interwiki links (see maintenance/interwiki.sql)
6302 Inline interwiki link
6304 [[MeatBall:SoftSecurity]]
6306 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
6311 Inline interwiki link with empty title (bug 2372)
6315 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
6320 Interwiki link encoding conversion (bug 1636)
6322 *[[Wikipedia:ro:Olteniţa]]
6323 *[[Wikipedia:ro:Olteniţa]]
6325 <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>
6326 <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>
6331 Interwiki link with fragment (bug 2130)
6333 [[MeatBall:SoftSecurity#foo]]
6335 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
6339 # Ideally the wikipedia: prefix here should be proto-relative too
6341 Different interwiki prefixes mapping to the same URL
6349 [[:wikipedia:Foo|Foo]]
6351 [[wikipedia:en:Foo]]
6353 [[:wikipedia:en:Foo]]
6355 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}'>en:Foo</a></p>
6357 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}'>Foo</a></p>
6359 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true}'>wikipedia:Foo</a></p>
6361 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":":wikipedia:Foo"},"isIW":true}'>Foo</a></p>
6363 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":"wikipedia:en:Foo"},"isIW":true}'>wikipedia:en:Foo</a></p>
6365 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":":wikipedia:en:Foo"},"isIW":true}'>wikipedia:en:Foo</a></p>
6369 Interwiki links that cannot be represented in wiki syntax
6372 [[meatball:ok#foo|ok with fragment]]
6373 [[meatball:ok_as_well?|ok ending with ? mark]]
6374 [http://de.wikipedia.org/wiki/Foo?action=history has query]
6375 [http://de.wikipedia.org/wiki/#foo is just fragment]
6378 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok">meatball:ok</a>
6379 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo">ok with fragment</a>
6380 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well?">ok ending with ? mark</a>
6381 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
6382 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a></p>
6386 Interwiki links: trail
6390 [[wikipedia:Foo|Ba]]r
6392 <p data-parsoid='{}'><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true,"tail":"r"}'>Bar</a></p>
6396 Local interwiki link
6398 [[local:Template:Foo]]
6400 <p><a href="/wiki/Template:Foo" title="Template:Foo">local:Template:Foo</a>
6405 Local interwiki link: self-link to current page
6411 <p><strong class="selflink">local:Main Page</strong>
6416 Local interwiki link: prefix only (bug 64167)
6420 <p><a href="/wiki/Main_Page" title="Main Page">local:</a>
6425 Local interwiki link: with additional interwiki prefix (bug 61357)
6427 [[local:meatball:Hello]]
6429 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?Hello" class="extiw" title="meatball:Hello">local:meatball:Hello</a>
6434 ### Interlanguage links
6435 ### Language links (so that searching for '### language' matches..)
6448 <link rel="mw:PageProp/Language" href="//zh.wikipedia.org/wiki/Chinese"/></p>
6452 Interlanguage link with spacing
6461 <link rel="mw:PageProp/Language" href="//zh.wikipedia.org/wiki/Chinese"/></p>
6465 Double interlanguage link
6475 <link rel="mw:PageProp/Language" href="//es.wikipedia.org/wiki/Spanish"/>
6476 <link rel="mw:PageProp/Language" href="//zh.wikipedia.org/wiki/Chinese"/></p>
6480 Interlanguage link, with prefix links
6491 <link rel="mw:PageProp/Language" href="//zh.wikipedia.org/wiki/Chinese"/></p>
6495 Double interlanguage link, with prefix links (bug 8897)
6507 <link rel="mw:PageProp/Language" href="//es.wikipedia.org/wiki/Spanish"/>
6508 <link rel="mw:PageProp/Language" href="//zh.wikipedia.org/wiki/Chinese"/></p>
6512 "Extra" interlanguage links (bug 32189 / gerrit 111390)
6521 <link rel="mw:PageProp/Language" title="Multilingual" href="//wikisource.org/wiki/Article"/></p>
6525 Parsoid-specific test: Wikilinks with should RT properly
6531 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
6536 Parsoid bug 53221: Wikilinks should be properly entity-escaped
6540 He&nbsp;llo [[Foo|He&nbsp;llo]]
6542 He&nbsp;llo [[He&nbsp;llo]]
6544 <p>He&nbsp;llo <a href="Foo" rel="mw:WikiLink">He&nbsp;llo</a></p>
6545 <p>He&nbsp;llo <a href="He&nbsp;llo" rel="mw:WikiLink">He&nbsp;llo</a></p>
6549 Parsoid: handle constructor well
6557 <p><a rel="mw:WikiLink" href="./Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"}}">constructor</a></p>
6559 <p><a rel="mw:WikiLink" href="./Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"}}">constructor:foo</a></p>
6563 Parsoid: recognize interlanguage links without a target page
6569 <p><link rel="mw:PageProp/Language" href="http://ko.wikipedia.org/wiki/"></p>
6573 Parsoid: recognize interwiki links without a target page
6579 <p><a rel="mw:ExtLink" href="//ko.wikipedia.org/wiki/">ko:</a></p>
6583 Parsoid: Bug #45209, handle interwiki links pointing to the current wiki as plain wiki links
6589 <p><a rel="mw:WikiLink" href="./Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"en:Foo"}}'>Foo</a></p>
6593 Interlanguage link with preceding local interwiki link (bug 68085)
6596 [[local:es:Spanish]]
6599 <a href="http://es.wikipedia.org/wiki/Spanish" class="extiw" title="es:Spanish">local:es:Spanish</a>
6604 Looks like an interlanguage link, but is actually a local interwiki
6610 <a href="/wiki/Template:Foo" title="Template:Foo">mi:Template:Foo</a>
6615 ### Redirects, Parsoid-only
6618 1. Simple redirect to page
6622 #REDIRECT [[Main Page]]
6624 <link rel="mw:PageProp/redirect" href="./Main_Page">
6627 # Only wt2html and html2html since "Main_Page" will serialize to "Main Page"
6629 2. Other redirect variants
6631 parsoid=wt2html,wt2wt
6633 #REDIRECT [[Main_Page]]
6634 #REDIRECT [[<nowiki>[[Bar]]</nowiki>]]
6636 <link rel="mw:PageProp/redirect" href="./Main_Page">
6637 <link rel="mw:PageProp/redirect" href="./%5B%5BBar%5D%5D">
6643 parsoid=wt2html,wt2wt
6648 <li>REDIRECT [[]]</li></ol>
6652 Optional colon in #REDIRECT
6654 # the colon is archaic syntax. we support it for wt2html, but we
6655 # don't care that it roundtrips back to the modern syntax.
6656 parsoid=wt2html,html2html
6658 #REDIRECT:[[Main Page]]
6660 <link rel="mw:PageProp/redirect" href="./Main_Page">
6664 Whitespace in #REDIRECT with optional colon
6666 # the colon and gratuitous whitespace is archaic syntax. we support
6667 # it for wt2html, but we don't care that it roundtrips back to the
6668 # modern syntax (without extra whitespace)
6669 parsoid=wt2html,html2html
6676 <link rel="mw:PageProp/redirect" href="./Main_Page">
6680 Piped link in #REDIRECT
6682 # content after piped link is ignored. we support this syntax,
6683 # but don't care that the piped link is lost when we roundtrip this.
6686 #REDIRECT [[Main Page|bar]]
6688 <link rel="mw:PageProp/redirect" href="./Main_Page">
6692 Redirect to category
6696 #REDIRECT [[Category:Foo]]
6698 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
6702 Redirect to category with URL encoding
6706 #REDIRECT [[Category%3AFoo]]
6708 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
6712 Redirect to category page
6714 parsoid=wt2html,html2html
6716 #REDIRECT [[:Category:Foo]]
6718 <p><a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a></p>
6722 Redirect to image page (1)
6726 #REDIRECT [[File:Wiki.png]]
6728 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
6732 Redirect to image page (2)
6736 #REDIRECT [[Image:Wiki.png]]
6738 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
6742 Redirect to language
6746 #REDIRECT [[en:File:Wiki.png]]
6748 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
6752 Redirect to interwiki
6756 #REDIRECT [[meatball:File:Wiki.png]]
6758 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
6762 Non-English #REDIRECT
6767 #TILVÍSUN [[Main Page]]
6769 <link rel="mw:PageProp/redirect" href="./Main_Page">
6780 <p>Foo<link rel="mw:PageProp/redirect" href="./Foo"></p>
6797 Broken br tag sanitization
6805 # TODO: Fix html2html mode (bug 51055)!
6807 Parsoid: Broken br tag recognition
6820 Incorrecly removing closing slashes from correctly formed XHTML
6822 <br style="clear:both;" />
6824 <p><br style="clear:both;" />
6829 Failing to transform badly formed HTML into correct XHTML
6831 <br style="clear: left;">
6832 <br style="clear: right;">
6833 <br style="clear: both;">
6835 <p><br style="clear: left;" />
6836 <br style="clear: right;" />
6837 <br style="clear: both;" />
6842 Handling html with a div self-closing tag
6851 <p><div title />
6855 <p><div title=bar />
6856 <div title=bar/>
6858 <div title="bar/"></div>
6864 Handling html with a br self-closing tag
6873 <p><br title="title" />
6874 <br title="title" />
6883 Horizontal ruler (should it add that extra space?)
6897 Horizontal ruler -- 4+ dashes render hr
6906 Horizontal ruler -- eats additional dashes on the same line
6915 Horizontal ruler -- does not collapse dashes on consecutive lines
6926 Horizontal ruler -- <4 dashes render as plain text
6935 Horizontal ruler -- Supports content following dashes on same line
6944 ### Block-level elements
6953 <ul><li>Common list</li>
6955 <li>item 3</li></ul>
6966 <ol><li>Numbered list</li>
6968 <li> item 3</li></ol>
6982 ***#Number on level 4
6984 **#Number on level 3
6985 **#Number on level 3
6989 #** Level 3, but ordered
6992 <ol><li> with numbers</li></ol>
6993 <ul><li> and bullets</li></ul>
6994 <ol><li> and numbers</li></ol></li>
6996 <ul><li>bullet level 2
6997 <ul><li>bullet level 3
6998 <ol><li>Number on level 4</li></ol></li></ul></li>
7000 <ol><li>Number on level 3</li>
7001 <li>Number on level 3</li></ol></li></ul>
7002 <ol><li>number level 2</li></ol></li>
7004 <ul><li><ul><li> Level 3</li></ul></li></ul></li></ul>
7005 <ol><li><ul><li><ul><li> Level 3, but ordered</li></ul></li></ul></li></ol>
7016 <ul><li>bar</li></ul></li></ul>
7026 <ul><li><ul><li>foo</li></ul></li>
7032 Nested lists 3 (first element empty)
7038 <ul><li>bar</li></ul></li></ul>
7043 Nested lists 4 (first element empty)
7048 <ul><li><ul><li></li></ul></li>
7054 Nested lists 5 (both elements empty)
7059 <ul><li><ul><li></li></ul></li>
7065 Nested lists 6 (both elements empty)
7071 <ul><li></li></ul></li></ul>
7076 Nested lists 7 (skip initial nesting levels)
7080 <ul><li><ul><li><ul><li> foo</li></ul></li></ul></li></ul>
7085 Nested lists 8 (multiple nesting transitions)
7093 <ul><li><ul><li> bar</li></ul></li>
7094 <li> baz</li></ul></li>
7100 1. Lists with start-of-line-transparent tokens before bullets: Comments
7113 2. Lists with start-of-line-transparent tokens before bullets: Template close
7118 <ul><li>foo bar</li>
7124 List items are not parsed correctly following a <pre> block (bug 785)
7130 <ul><li> <pre>foo</pre></li>
7131 <li> <pre>bar</pre></li>
7137 List items from template
7148 * notSOL{{inner list}}
7151 <ul><li> item 1</li>
7152 <li> item 2</li></ul>
7153 <ul><li> item 0</li>
7155 <li> item 2</li></ul>
7156 <ul><li> item 0</li>
7159 <li> item 2</li></ul>
7164 List interrupted by empty line or heading
7172 <ul><li> foo</li></ul>
7173 <ul><li><ul><li> bar</li></ul></li></ul>
7174 <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>
7175 <ul><li> Another list item</li></ul>
7180 Multiple list tags generated by templates
7195 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
7198 <!--This line will NOT split the list-->
7200 <!--This line will NOT split the list either-->
7202 <!--foo--> <!----> <!--This line NOT split the list either-->
7213 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
7216 <!--This line will NOT split the list-->
7218 <!--This line will NOT split the list either-->
7220 <!--foo--> <!----> <!--This line NOT split the list
7233 (Cannot test this with PHP parser since it relies on Tidy for the hack)
7235 parsoid=wt2html,wt2wt
7239 * {{echo|<li>templated li-hack}}
7240 * <!--foo--> <li> unsupported li-hack with preceding comments
7243 <li><li>not a li-hack
7250 <li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<li>templated li-hack"}}}}]}'>templated li-hack</li>
7251 <li> <!--foo--> </li>
7252 <li> li-hack with preceding comments</li>
7263 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
7290 Parsoid: Test of whitespace serialization with Templated bullets
7297 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}}]}'> Bar</li>
7301 # ------------------------------------------------------------------------
7302 # The next set of tests are about Parsoid's ability to handle badly nested
7303 # tags (parse, minimize scope of fixup, and roundtrip back)
7304 # ------------------------------------------------------------------------
7307 Unbalanced closing block tags break a list
7308 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
7326 Unbalanced closing non-block tags don't break a list
7327 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
7344 Unclosed formatting tags that straddle lists are closed and reopened
7345 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
7359 List embedded in a non-block tag
7360 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
7366 <p><small></small></p>
7372 <p><small></small></p>
7376 Table with missing opening <tr> tag
7378 parsoid=wt2html,wt2wt
7396 # Note that the current date is hard-coded as
7397 # 1970-01-01T00:02:03Z (a Thursday)
7398 # when running parser tests. The timezone is also fixed to GMT, so
7399 # local date will be identical to current date.
7402 Magic Word: {{CURRENTDAY}}
7411 Magic Word: {{CURRENTDAY2}}
7420 Magic Word: {{CURRENTDAYNAME}}
7429 Magic Word: {{CURRENTDOW}}
7438 Magic Word: {{CURRENTMONTH}}
7447 Magic Word: {{CURRENTMONTH1}}
7456 Magic Word: {{CURRENTMONTHABBREV}}
7458 {{CURRENTMONTHABBREV}}
7465 Magic Word: {{CURRENTMONTHNAME}}
7467 {{CURRENTMONTHNAME}}
7474 Magic Word: {{CURRENTMONTHNAMEGEN}}
7476 {{CURRENTMONTHNAMEGEN}}
7483 Magic Word: {{CURRENTTIME}}
7492 Magic Word: {{CURRENTHOUR}}
7501 Magic Word: {{CURRENTWEEK}} (@bug 4594)
7510 Magic Word: {{CURRENTYEAR}}
7519 Magic Word: {{CURRENTTIMESTAMP}}
7521 {{CURRENTTIMESTAMP}}
7528 Magic Words LOCAL (UTC)
7532 * {{LOCALMONTHNAME}}
7533 * {{LOCALMONTHNAMEGEN}}
7534 * {{LOCALMONTHABBREV}}
7543 * {{LOCALTIMESTAMP}}
7558 <li> 19700101000203</li></ul>
7563 Magic Word: {{FULLPAGENAME}}
7565 title=[[User:Ævar Arnfjörð Bjarmason]]
7569 <p>User:Ævar Arnfjörð Bjarmason
7574 Magic Word: {{FULLPAGENAMEE}}
7576 title=[[User:Ævar Arnfjörð Bjarmason]]
7580 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7585 Magic Word: {{TALKSPACE}}
7587 title=[[User:Ævar Arnfjörð Bjarmason]]
7596 Magic Word: {{TALKSPACE}}, same namespace
7598 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7607 Magic Word: {{TALKSPACE}}, main namespace
7609 title=[[Parser Test]]
7618 Magic Word: {{TALKSPACEE}}
7620 title=[[User:Ævar Arnfjörð Bjarmason]]
7629 Magic Word: {{SUBJECTSPACE}}
7631 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7640 Magic Word: {{SUBJECTSPACE}}, same namespace
7642 title=[[User:Ævar Arnfjörð Bjarmason]]
7651 Magic Word: {{SUBJECTSPACE}}, main namespace
7653 title=[[Parser Test]]
7661 Magic Word: {{SUBJECTSPACEE}}
7663 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7672 Magic Word: {{NAMESPACE}}
7674 title=[[User:Ævar Arnfjörð Bjarmason]]
7683 Magic Word: {{NAMESPACEE}}
7685 title=[[User:Ævar Arnfjörð Bjarmason]]
7694 Magic Word: {{NAMESPACENUMBER}}
7696 title=[[User:Ævar Arnfjörð Bjarmason]]
7705 Magic Word: {{SUBPAGENAME}}
7707 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
7716 Magic Word: {{SUBPAGENAMEE}}
7718 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
7727 Magic Word: {{ROOTPAGENAME}}
7729 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
7733 <p>Ævar Arnfjörð Bjarmason
7738 Magic Word: {{ROOTPAGENAMEE}}
7740 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
7744 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7749 Magic Word: {{BASEPAGENAME}}
7751 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
7755 <p>Ævar Arnfjörð Bjarmason
7760 Magic Word: {{BASEPAGENAMEE}}
7762 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
7766 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7771 Magic Word: {{TALKPAGENAME}}
7773 title=[[User:Ævar Arnfjörð Bjarmason]]
7777 <p>User talk:Ævar Arnfjörð Bjarmason
7782 Magic Word: {{TALKPAGENAMEE}}
7784 title=[[User:Ævar Arnfjörð Bjarmason]]
7788 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7793 Magic Word: {{SUBJECTPAGENAME}}
7795 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7799 <p>User:Ævar Arnfjörð Bjarmason
7804 Magic Word: {{SUBJECTPAGENAMEE}}
7806 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7808 {{SUBJECTPAGENAMEE}}
7810 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7815 Magic Word: {{NUMBEROFFILES}}
7824 Magic Word: {{PAGENAME}}
7826 title=[[User:Ævar Arnfjörð Bjarmason]]
7830 <p>Ævar Arnfjörð Bjarmason
7835 Magic Word: {{PAGENAME}} with metacharacters
7837 title=[['foo & bar = baz']]
7841 <p><i>'foo & bar = baz'</i>
7846 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
7848 title=[[*RFC 1234 http://example.com/]]
7852 <p>*RFC 1234 http://example.com/
7857 Magic Word: {{PAGENAMEE}}
7859 title=[[User:Ævar Arnfjörð Bjarmason]]
7863 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7868 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
7870 title=[[*RFC 1234 http://example.com/]]
7874 <p>*RFC_1234_http://example.com/
7879 Magic Word: {{REVISIONID}}
7888 Magic Word: {{SCRIPTPATH}}
7897 Magic Word: {{STYLEPATH}}
7906 Magic Word: {{SERVER}}
7910 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
7915 Magic Word: {{SERVERNAME}}
7924 Magic Word: {{SITENAME}}
7933 Case-sensitive magic words, when cased differently, should just be template transclusions
7940 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
7941 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
7942 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
7943 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
7948 Case-insensitive magic words should still work with weird casing.
7958 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
7963 Namespace 1 {{ns:1}}
7972 Namespace 1 {{ns:01}}
7981 Namespace 0 {{ns:0}} (bug 4783)
7989 Namespace 0 {{ns:00}} (bug 4783)
7997 Namespace -1 {{ns:-1}}
8006 Namespace User {{ns:User}}
8015 Namespace User talk {{ns:User_talk}}
8024 Namespace User talk {{ns:uSeR tAlK}}
8033 Namespace File {{ns:File}}
8042 Namespace File {{ns:Image}}
8051 Namespace (lang=de) Benutzer {{ns:User}}
8062 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
8068 <p>Benutzer Diskussion
8076 {{urlencode:hi world?!}}
8077 {{urlencode:hi world?!|WIKI}}
8078 {{urlencode:hi world?!|PATH}}
8079 {{urlencode:hi world?!|QUERY}}
8089 Magic Word: prioritize type info over data-parsoid
8095 <meta property="mw:PageProp/forcetoc" data-parsoid='{"src":"__NOTOC__","magicSrc":"__NOTOC__"}'/>
8099 Magic Word: serialize on separate line (parsoid)
8101 parsoid=wt2wt,html2wt
8107 foo<meta property="mw:PageProp/notoc"/>bar
8111 Magic Word: rt non-english wikis
8118 <meta property="mw:PageProp/noeditsection" data-parsoid='{"src":"__NOEDITSECTION__","magicSrc":"__NOEDITSECTION__"}'/>
8125 Magic links: internal link to RFC (bug 479)
8129 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
8134 Magic links: RFC (bug 479)
8138 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
8143 Magic links: ISBN (bug 1937)
8147 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
8152 Magic links: PMID incorrectly converts space to underscore
8156 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
8165 Nonexistent template
8167 {{thistemplatedoesnotexist}}
8169 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
8174 Template with invalid target containing tags
8176 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
8178 <p>{{a<b>b</b>|foo|a=b|a = b}}
8183 Template with invalid target containing unclosed tag
8185 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
8187 <p>{{a<b>|foo|a=b|a = b}}</b>
8192 Template with invalid target containing wikilink
8196 <p>{{<a href="/wiki/Main_Page" title="Main Page">Main Page</a>}}
8199 <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>
8205 This is a test template
8213 <p>This is a test template
8218 Template with explicit namespace
8222 <p>This is a test template
8230 This is a test template with parameter {{{param}}}
8236 {{paramtest|param=foo}}
8238 <p>This is a test template with parameter foo
8243 Template:paramtestnum
8249 Template unnamed parameter
8251 {{paramtestnum|Main Page|the main page}}
8253 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
8258 Template:templatesimple
8264 Template:templateredirect
8266 #redirect [[Template:templatesimple]]
8270 Template:templateasargtestnum
8276 Template:templateasargtest
8278 {{template{{{templ}}}}}
8282 Template:templateasargtest2
8288 Template with template name as unnamed argument
8290 {{templateasargtestnum|templatesimple}}
8297 Template with template name as argument
8299 {{templateasargtest|templ=simple}}
8306 Template with template name as argument (2)
8308 {{templateasargtest2|templ=templatesimple}}
8315 Template:templateasargtestdefault
8317 {{{{{templ|templatesimple}}}}}
8327 Template with default value
8329 {{templateasargtestdefault}}
8336 Template with default value (value set)
8338 {{templateasargtestdefault|templ=templa}}
8347 {{templateredirect}}
8354 Template with argument in separate line
8356 {{ templateasargtest |
8364 Template with complex template as argument
8367 param ={{ templateasargtest |
8370 <p>This is a test template with parameter (test)
8375 Template with thumb image (with link in description)
8378 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
8380 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>
8385 Template:complextemplate
8387 {{{1}}} {{paramtest|
8388 param ={{{param}}}}}
8392 Template with complex arguments
8395 param ={{ templateasargtest |
8396 templ = simple }}|[[Template:complextemplate|link]]}}
8398 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
8403 BUG 553: link with two variables in a piped link
8406 |[[{{{1}}}|{{{2}}}]]
8411 <td>[[{{{1}}}|{{{2}}}]]
8417 Magic variable as template parameter
8419 {{paramtest|param={{SITENAME}}}}
8421 <p>This is a test template with parameter MediaWiki
8428 [[{{{param}}}|link]]
8432 Template parameter as link source
8434 {{linktest|param=Main Page}}
8436 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
8441 Template-generated attribute string (k='v')
8443 <span {{attr_str|id|v1}}>bar</span>
8445 <p><span id="v1">bar</span>
8452 including another template, {{paramtest|param={{{arg}}}}}
8456 Template passing argument to another template
8458 {{paramtest2|arg='hmm'}}
8460 <p>including another template, This is a test template with parameter 'hmm'
8471 Template as link source
8475 [[{{linktest2}}|Main Page]]
8477 [[{{linktest2}}]]Page
8479 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
8480 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
8481 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
8499 Template infinite loop
8503 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
8508 Template from main namespace
8527 BUG 529: Template with table, not included at beginning of line
8546 BUG 523: Template shouldn't eat newline (or add an extra one before table)
8566 BUG 41: Template parameters shown as broken links
8575 Template with targets containing wikilinks
8579 {{[[{{echo|foo}}]]}}
8581 {{{{echo|[[foo}}]]}}
8583 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
8584 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
8592 ''None'' of '''this''' should be
8594 but rather passed unmodified
8601 # hmm, fix this or just deprecate msgnw and document its behavior?
8605 {{msgnw:MSGNW test}}
8607 <p>''None'' of '''this''' should be
8609  but rather passed unmodified
8610 {{test}}
8620 {{int:youhavenewmessages|lots of money|not!}}
8622 <p>You have lots of money (not!).
8629 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
8633 <includeonly> and <noinclude> being included
8644 <onlyinclude>Foo</onlyinclude>bar
8648 <onlyinclude> being included
8660 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
8664 <onlyinclude> and <includeonly> being included
8673 <includeonly> and <noinclude> on a page
8675 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
8682 Un-closed <noinclude>
8689 <onlyinclude> on a page
8691 <onlyinclude>Foo</onlyinclude>bar
8698 Un-closed <onlyinclude>
8705 Self-closed noinclude, includeonly, onlyinclude tags
8716 Unbalanced includeonly and noinclude tags
8720 |b</noinclude></noinclude>
8721 |c</noinclude></includeonly>
8722 |d</includeonly></includeonly>
8731 <td>c</includeonly>
8733 <td>d</includeonly></includeonly>
8739 Template:Includeonly section
8742 ==Includeonly section==
8748 Bug 6563: Edit link generation for section shown by <includeonly>
8750 {{includeonly section}}
8752 <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>
8753 <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>
8757 # Uses same input as the contents of [[Template:Includeonly section]]
8759 Bug 6563: Section extraction for section shown by <includeonly>
8764 ==Includeonly section==
8772 Bug 6563: Edit link generation for section suppressed by <includeonly>
8775 ==Includeonly section==
8779 <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>
8784 Bug 6563: Section extraction for section suppressed by <includeonly>
8789 ==Includeonly section==
8797 Un-closed <includeonly>
8804 Includes and comments at SOL
8806 <!-- comment --><noinclude><!-- comment --></noinclude><!-- comment -->== hu ==
8813 <includeonly>can have stuff</includeonly>=== here ===
8816 <h2><span class="mw-headline" id="hu">hu</span></h2>
8821 <h3><span class="mw-headline" id="here">here</span></h3>
8824 <!-- comment --><meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/><!-- comment --><meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/><!-- comment -->
8825 <h2 data-parsoid='{}'> hu </h2>
8827 <meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/>
8829 <p data-parsoid='{}'>some</p>
8830 <meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/>
8831 <ul data-parsoid='{}'>
8832 <li data-parsoid='{}'> stuff</li>
8834 <li data-parsoid='{}'> here</li></ul>
8836 <h3 data-parsoid='{}'> here </h3>
8839 # TODO: test with DOM fragment reuse!
8841 Parsoid: DOM fragment reuse
8843 parsoid=wt2wt,wt2html
8845 a{{echo|b<table></table>c}}d
8857 a<span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b
8858 <table></table>c"}},"i":0}}]}'>b</span>
8859 <table about="#mwt1"></table><span about="#mwt1">c</span>d
8862 <p about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["a",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b\n<table></table>\nc"}},"i":0}},"d"]}'>ab</p><span about="#mwt2">
8864 <table about="#mwt2"></table><span about="#mwt2">
8866 <p about="#mwt2">cd</p>
8869 <p about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n\n<table></table>\n\nb"}},"i":0}}]}'>a</p><span about="#mwt3">
8872 <table about="#mwt3"></table><span about="#mwt3">
8875 <p about="#mwt3">b</p>
8879 Parsoid: Merge double tds (bug 50603)
8888 <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>
8893 Parsoid: Merge double tds in nested transclusion content (bug 50603)
8903 <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}}]}'>
8905 <tr><td data-mw='{"parts":["|"]}'> foo</td></tr>
8911 ### <includeonly> and <noinclude> in attributes
8914 0. includeonly around the entire attribute
8916 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
8918 <p><span id="v2">bar</span>
8923 1. includeonly in html attr key
8925 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
8927 <p><span id="foo">bar</span>
8932 2. includeonly in html attr value
8934 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
8935 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
8937 <p><span id="v1">bar</span>
8938 <span id="v1">bar</span>
8943 3. includeonly in part of an attr value
8945 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
8947 <p><span style="color:red;">bar</span>
8952 4. includeonly in table attributes
8976 ### Token Stream Patcher tests
8978 ### These tests won't always pass wt2wt and other modes because
8979 ### on serialization, the table will be output on a new line.
8980 ### For now, we are blacklisting them, and using this to test selser.
8984 1. Table tag in SOL posn. should get reparsed correctly with valid TSR
8986 parsoid=wt2html,wt2wt
8988 {{echo|}}{| width = '100%'
8992 <span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":""}},"i":0}}]}'></span>
8993 <table width="100%">
8996 <td>foo</td></tr></tbody></table>
9000 2. Table tag in SOL posn. should get reparsed correctly with valid TSR
9002 parsoid=wt2html,wt2wt
9004 <includeonly>a</includeonly>{| {{{b}}}
9008 <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}}}":""}}'>
9009 <tbody><tr><td>c</td></tr>
9015 ### Testing parsing of templates where a template arg
9016 ### has the same name as the template itself.
9026 Templates: Template Name/Arg clash: 1. Use of positional param
9035 Templates: Template Name/Arg clash: 2. Use of named param
9044 Templates: Template Name/Arg clash: 3. Use of named param with empty input
9053 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
9057 Templates: 1. Simple use
9066 Templates: 2. Inside a block tag
9068 <div>{{echo|Foo}}</div>
9069 <blockquote>{{echo|Foo}}</blockquote>
9072 <blockquote>Foo</blockquote>
9077 Templates: P-wrapping: 1a. Templates on consecutive lines
9088 Templates: P-wrapping: 1b. Templates on consecutive lines
9102 Templates: P-wrapping: 1c. Templates on consecutive lines
9105 {{echo|bar}} <div>baz</div>
9114 Templates: P-wrapping: 1d. Template preceded by comment-only line
9123 <p about="#mwt223" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Bar"}},"i":0}}]}'>Bar</p>
9127 Templates: Inline Text: 1. Multiple template uses
9129 {{echo|Foo}}bar{{echo|baz}}
9136 Templates: Inline Text: 2. Back-to-back template uses
9138 {{echo|Foo}}{{echo|bar}}
9145 Templates: Block Tags: 1. Multiple template uses
9147 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
9149 <div>Foo</div><div>bar</div><div>baz</div>
9154 Templates: Block Tags: 2. Back-to-back template uses
9156 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
9158 <div>Foo</div><div>bar</div>
9163 Templates: Links: 1. Simple example
9165 {{echo|[[Foo|bar]]}}
9167 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
9172 Templates: Links: 2. Generation of link href
9174 [[{{echo|Foo}}|bar]]
9176 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
9181 Templates: Links: 3. Generation of part of a link href
9183 [[Fo{{echo|o}}|bar]]
9187 [[Foo{{echo|bar}}baz]]
9189 [[Foo{{echo|bar}}|bar]]
9191 [[:Foo{{echo|bar}}]]
9193 [[:Foo{{echo|bar}}|bar]]
9195 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
9196 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
9197 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
9198 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
9199 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
9200 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
9205 Templates: Links: 4. Multiple templates generating link href
9207 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
9209 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
9214 Templates: Links: 5. Generation of link text
9216 [[Foo|{{echo|bar}}]]
9218 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
9223 Templates: Links: 5. Nested templates (only outermost template should be marked)
9225 {{echo|[[{{echo|Foo}}|bar]]}}
9227 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
9232 Templates: HTML Tag: 1. Generation of HTML attr. key
9234 <div {{echo|style}}="color:red;">foo</div>
9236 <div style="color:red;">foo</div>
9241 Templates: HTML Tag: 2. Generation of HTML attr. value
9243 <div style={{echo|'color:red;'}}>foo</div>
9245 <div style="color:red;">foo</div>
9250 Templates: HTML Tag: 3. Generation of HTML attr key and value
9252 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
9254 <div style="color:red;">foo</div>
9259 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
9261 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
9263 <div title="This is a long title with just one piece templated">foo</div>
9268 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
9270 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
9272 <div title="This is a long title with just one piece templated">foo</div>
9277 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
9279 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
9281 <div title="This is a long title with just one piece templated">foo</div>
9286 Templates: HTML Tag: 7. Generation of partial attribute key string
9288 <div st{{echo|yle}}="color:red;">foo</div>
9290 <div style="color:red;">foo</div>
9295 Templates: HTML Tables: 1. Generating start of a HTML table
9297 {{echo|<table><tr><td>foo</td>}}</tr></table>
9299 <table><tr><td>foo</td></tr></table>
9304 Templates: HTML Tables: 2a. Generating middle of a HTML table
9306 <table><tr>{{echo|<td>foo</td>}}</tr></table>
9308 <table><tr><td>foo</td></tr></table>
9313 Templates: HTML Tables: 2b. Generating middle of a HTML table
9315 <table>{{echo|<tr><td>foo</td></tr>}}</table>
9317 <table><tr><td>foo</td></tr></table>
9322 Templates: HTML Tables: 3. Generating end of a HTML table
9324 <table><tr>{{echo|<td>foo</td></tr></table>}}
9326 <table><tr><td>foo</td></tr></table>
9331 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
9333 {{echo|<table>}}<tr><td>foo</td></tr></table>
9335 <table><tr><td>foo</td></tr></table>
9340 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
9342 <table>{{echo|<tr>}}<td>foo</td></tr></table>
9344 <table><tr><td>foo</td></tr></table>
9349 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
9351 <table><tr>{{echo|<td>}}foo</td></tr></table>
9353 <table><tr><td>foo</td></tr></table>
9358 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
9360 <table><tr><td>foo{{echo|</td>}}</tr></table>
9362 <table><tr><td>foo</td></tr></table>
9367 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
9369 <table><tr><td>foo</td>{{echo|</tr>}}</table>
9371 <table><tr><td>foo</td></tr></table>
9376 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
9378 <table><tr><td>foo</td></tr>{{echo|</table>}}
9380 <table><tr><td>foo</td></tr></table>
9385 Templates: HTML Tables: 5. Proper fostering of categories from inside
9387 parsoid=wt2html,wt2wt
9389 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
9390 <!--Two categories (Bug 50330)-->
9391 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
9393 <link rel="mw:PageProp/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
9394 <!--Two categories (Bug 50330)-->
9395 <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>
9399 Templates: Wiki Tables: 1a. Fostering of entire template content
9407 <tr><td></td></tr></table>
9412 Templates: Wiki Tables: 1b. Fostering of entire template content
9425 <tr><td></td></tr></table>
9430 Templates: Wiki Tables: 2. Fostering of partial template content
9440 <tr><td></td></tr></table>
9445 Templates: Wiki Tables: 3. td-content via multiple templates
9448 {{echo|{{pipe}}a}}{{echo|b}}
9459 Templates: Wiki Tables: 4. Templated tags, no content
9465 <tr><td></td></tr></table>
9470 Templates: Wiki Tables: 5. Templated tags, regular td-tags
9484 Templates: Wiki Tables: 6. Templated tags, templated td-tags
9498 Templates: Lists: Multi-line list-items via templates
9500 *{{echo|a {{nonexistent|
9502 *{{echo|b {{nonexistent|
9505 <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>
9506 <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>
9511 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
9513 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
9515 <p><i>ab</i>c<i>d</i>e
9520 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
9521 (PHP parser generates misnested html)
9523 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
9525 <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>
9529 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
9530 (PHP parser generates misnested html; Parsoid html2wt mode adds newlines between {{echo}}s)
9532 parsoid=wt2html,wt2wt
9534 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
9536 <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>
9537 <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>
9538 <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>
9542 Templates: Ugly nesting: 4. Divs opened/closed across templates
9544 a<div>b{{echo|c</div>d}}e
9551 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
9557 |{{echo|foo</table>}}
9561 <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|}"]}'>
9565 <td>foo</td></tr></tbody></table><span about="#mwt1">
9566 </span><span about="#mwt1">|bar</span><span about="#mwt1">
9571 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
9581 <td>1. {{echo|foo </table>}}</td>
9583 <td>2. {{echo|baz </table>}}</td>
9596 <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>"]}'>
9601 <td>1. foo </td></tr></tbody></table></td>
9603 <td>2. baz </td></tr></tbody></table><span about="#mwt2">
9604 </span><span about="#mwt2">
9605 </span><span about="#mwt2">
9606 </span><span about="#mwt2">abc</span><span about="#mwt2">
9607 </span><span about="#mwt2">
9608 </span><span about="#mwt2">
9609 </span><span about="#mwt2">
9610 </span><span about="#mwt2">
9611 </span><span about="#mwt2">
9612 </span><span about="#mwt2">xyz</span><span about="#mwt2">
9613 </span><span about="#mwt2">
9618 Templates: Ugly templates: 3. newline-only template parameter
9627 # This looks like a bug: a single newline triggers p/br for some reason.
9629 Templates: Ugly templates: 4. newline-only template parameter inconsistency
9638 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges that
9639 # have a true overlap (T1-start - T2-start - T1-end - T2-end).
9641 Templates: Ugly templates: 5. Template encapsulation test: Non-trivial overlap of template ranges is properly handled
9647 <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
9648 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
9652 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges
9653 # that are "identical" and generate nesting cycles in the algorithm
9655 Templates: Ugly templates: 6. Template encapsulation test: Cyclical nesting of template ranges is properly handled
9657 {{echo|<table><tr><td><table>}}
9661 <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"}'>
9662 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
9663 </table></td></tr></tbody></table>
9667 Parser Functions: 1. Simple example
9676 Parser Functions: 2. Nested use (only outermost should be marked up)
9685 ### Pre-save transform tests
9688 pre-save transform: subst:
9694 This is a test template
9698 pre-save transform: normal template
9708 pre-save transform: nonexistent template
9712 {{thistemplatedoesnotexist}}
9714 {{thistemplatedoesnotexist}}
9719 pre-save transform: subst magic variables
9728 # This is bug 89, which I fixed. -- wtm
9730 pre-save transform: subst: templates with parameters
9734 {{subst:paramtest|param="something else"}}
9736 This is a test template with parameter "something else"
9742 <nowiki>'''not wiki'''</nowiki>
9746 pre-save transform: nowiki in subst (bug 1188)
9750 {{subst:nowikitest}}
9752 <nowiki>'''not wiki'''</nowiki>
9757 Template:commenttest
9759 This template has <!-- a comment --> in it.
9763 pre-save transform: comment in subst (bug 1936)
9767 {{subst:commenttest}}
9769 This template has <!-- a comment --> in it.
9773 pre-save transform: unclosed tag
9777 <nowiki>'''not wiki'''
9779 <nowiki>'''not wiki'''
9783 pre-save transform: mixed tag case
9787 <NOwiki>'''not wiki'''</noWIKI>
9789 <NOwiki>'''not wiki'''</noWIKI>
9793 pre-save transform: unclosed comment in <nowiki>
9797 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
9799 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
9802 # Leading @ in this template definition works around a limitation
9803 # in parsoid's parserTests which otherwise strips the <span> from the
9804 # result (confusing it for a template wrapper)
9808 @<span onmouseover="alert('crap')">Oh no</span>
9812 (confirming safety of fix for subst bug 1936)
9814 {{Template:dangerous}}
9816 <p>@<span>Oh no</span>
9821 pre-save transform: comment containing gallery (bug 5024)
9825 <!-- <gallery>data</gallery> -->
9827 <!-- <gallery>data</gallery> -->
9831 pre-save transform: comment containing extension
9835 <!-- <tag>data</tag> -->
9837 <!-- <tag>data</tag> -->
9841 pre-save transform: comment containing nowiki
9845 <!-- <nowiki>data</nowiki> -->
9847 <!-- <nowiki>data</nowiki> -->
9851 pre-save transform: <noinclude> in subst (bug 3298)
9861 pre-save transform: <onlyinclude> in subst (bug 3298)
9873 {{<includeonly>subst:</includeonly>Includes}}
9877 Template:SafeSubstTest
9879 {{<includeonly>safesubst:</includeonly>Includes}}
9883 bug 22297: safesubst: works during PST
9887 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
9893 bug 22297: safesubst: works during normal parse
9902 subst: does not work during normal parse
9906 <p>{{subst:Includes}}
9911 pre-save transform: context links ("pipe trick")
9915 [[Article (context)|]]
9918 [[Bar:Article (context)|]]
9919 [[:Bar:Article (context)|]]
9921 [[|Article (context)]]
9925 [[Article (context)|Article]]
9926 [[Bar:Article|Article]]
9927 [[:Bar:Article|Article]]
9928 [[Bar:Article (context)|Article]]
9929 [[:Bar:Article (context)|Article]]
9931 [[Article (context)]]
9932 [[Bar:X (Y) Z|X (Y) Z]]
9933 [[:Bar:X (Y) Z|X (Y) Z]]
9937 pre-save transform: context links ("pipe trick") with interwiki prefix
9941 [[interwiki:Article|]]
9942 [[:interwiki:Article|]]
9943 [[interwiki:Bar:Article|]]
9944 [[:interwiki:Bar:Article|]]
9946 [[interwiki:Article|Article]]
9947 [[:interwiki:Article|Article]]
9948 [[interwiki:Bar:Article|Bar:Article]]
9949 [[:interwiki:Bar:Article|Bar:Article]]
9953 pre-save transform: context links ("pipe trick") with parens in title
9955 pst title=[[Somearticle (context)]]
9959 [[Article (context)|Article]]
9963 pre-save transform: context links ("pipe trick") with comma in title
9965 pst title=[[Someplace, Somewhere]]
9968 [[Otherplace, Elsewhere|]]
9969 [[Otherplace, Elsewhere, Anywhere|]]
9971 [[Otherplace, Somewhere|Otherplace]]
9972 [[Otherplace, Elsewhere|Otherplace]]
9973 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
9977 pre-save transform: context links ("pipe trick") with parens and comma
9979 pst title=[[Someplace (IGNORED), Somewhere]]
9982 [[Otherplace (place), Elsewhere|]]
9984 [[Otherplace, Somewhere|Otherplace]]
9985 [[Otherplace (place), Elsewhere|Otherplace]]
9989 pre-save transform: context links ("pipe trick") with comma and parens
9991 pst title=[[Who, me? (context)]]
9994 [[Me, Myself, and I (1937 song)|]]
9996 [[Yes, you. (context)|Yes, you.]]
9997 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
10001 pre-save transform: context links ("pipe trick") with namespace
10003 pst title=[[Ns:Somearticle]]
10007 [[Ns:Article|Article]]
10011 pre-save transform: context links ("pipe trick") with namespace and parens
10013 pst title=[[Ns:Somearticle (context)]]
10017 [[Ns:Article (context)|Article]]
10021 pre-save transform: context links ("pipe trick") with namespace and comma
10023 pst title=[[Ns:Somearticle, Context, Whatever]]
10027 [[Ns:Article, Context, Whatever|Article]]
10031 pre-save transform: context links ("pipe trick") with namespace, comma and parens
10033 pst title=[[Ns:Somearticle, Context (context)]]
10037 [[Ns:Article (context)|Article]]
10041 pre-save transform: context links ("pipe trick") with namespace, parens and comma
10043 pst title=[[Ns:Somearticle (IGNORED), Context]]
10047 [[Ns:Article, Context|Article]]
10051 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
10055 [[Article(context)|]]
10056 [[Bar:Article(context)|]]
10057 [[:Bar:Article(context)|]]
10058 [[|Article(context)]]
10062 [[Article(context)|Article]]
10063 [[Bar:Article(context)|Article]]
10064 [[:Bar:Article(context)|Article]]
10065 [[Article(context)]]
10066 [[Bar:X(Y)Z|X(Y)Z]]
10067 [[:Bar:X(Y)Z|X(Y)Z]]
10071 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
10075 [[Article (context)|]]
10076 [[Bar:Article (context)|]]
10077 [[:Bar:Article (context)|]]
10078 [[|Article (context)]]
10082 [[Article (context)|Article]]
10083 [[Bar:Article (context)|Article]]
10084 [[:Bar:Article (context)|Article]]
10085 [[Article (context)]]
10086 [[Bar:X (Y) Z|X (Y) Z]]
10087 [[:Bar:X (Y) Z|X (Y) Z]]
10091 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
10095 [[Article(context)|]]
10096 [[Bar:Article(context)|]]
10097 [[:Bar:Article(context)|]]
10098 [[|Article(context)]]
10102 [[Article(context)|Article]]
10103 [[Bar:Article(context)|Article]]
10104 [[:Bar:Article(context)|Article]]
10105 [[Article(context)]]
10106 [[Bar:X(Y)Z|X(Y)Z]]
10107 [[:Bar:X(Y)Z|X(Y)Z]]
10111 pre-save transform: context links ("pipe trick") with commas (bug 21660)
10115 [[Article (context), context|]]
10116 [[Article (context),context|]]
10117 [[Bar:Article (context), context|]]
10118 [[Bar:Article (context),context|]]
10119 [[:Bar:Article (context), context|]]
10120 [[:Bar:Article (context),context|]]
10122 [[Article (context), context|Article]]
10123 [[Article (context),context|Article]]
10124 [[Bar:Article (context), context|Article]]
10125 [[Bar:Article (context),context|Article]]
10126 [[:Bar:Article (context), context|Article]]
10127 [[:Bar:Article (context),context|Article]]
10131 pre-save transform: trim trailing empty lines
10135 Empty lines are trimmed
10141 Empty lines are trimmed
10145 pre-save transform: Signature expansion
10150 * <noinclude>~~~</noinclude>
10151 * <includeonly>~~~</includeonly>
10152 * <onlyinclude>~~~</onlyinclude>
10154 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
10155 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
10156 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
10157 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
10162 pre-save transform: Signature expansion in nowiki tags (bug 93)
10168 <nowiki>~~~~</nowiki>
10170 <includeonly><nowiki>~~~~</nowiki></includeonly>
10172 <noinclude><nowiki>~~~~</nowiki></noinclude>
10174 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
10176 {{subst:Foo}} shall be converted to FOO
10178 As well as inside noinclude/onlyinclude
10179 <noinclude>{{subst:Foo}}</noinclude>
10180 <onlyinclude>{{subst:Foo}}</onlyinclude>
10182 But not inside includeonly
10183 <includeonly>{{subst:Foo}}</includeonly>
10187 <nowiki>~~~~</nowiki>
10189 <includeonly><nowiki>~~~~</nowiki></includeonly>
10191 <noinclude><nowiki>~~~~</nowiki></noinclude>
10193 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
10195 FOO shall be converted to FOO
10197 As well as inside noinclude/onlyinclude
10198 <noinclude>FOO</noinclude>
10199 <onlyinclude>FOO</onlyinclude>
10201 But not inside includeonly
10202 <includeonly>{{subst:Foo}}</includeonly>
10206 Parsoid: Recognize nowiki with trailing space in tags
10210 <nowiki ><div>[[foo]]</nowiki >
10218 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
10225 Parsoid: Recognize nowiki with odd capitalization
10229 <noWikI ><div>[[foo]]</Nowiki >
10231 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
10236 Parsoid: Escape nowiki with trailing space in tags
10240 <nowiki > foo </nowiki >
10246 <p><nowiki > foo </nowiki ></p>
10247 <p>a<nowiki />b</p>
10248 <p>c<nowiki/ >d</p>
10252 Parsoid: Escape weird noWikI capitalizations
10256 <noWikI > foo </NoWikI >
10258 <p><noWikI > foo </NoWikI ></p>
10262 ### Message transform tests
10265 message transform: magic variables
10275 message transform: should not transform wiki markup
10285 message transform: <noinclude> in transcluded template (bug 4926)
10295 message transform: <onlyinclude> in transcluded template (bug 4926)
10305 {{#special:}} page name, known
10309 {{#special:Recentchanges}}
10311 Special:RecentChanges
10315 {{#special:}} page name with subpage, known
10319 {{#special:Recentchanges/param}}
10321 Special:RecentChanges/param
10325 {{#special:}} page name, unknown
10329 {{#special:foobar nonexistent}}
10331 Special:Foobar nonexistent
10335 {{#speciale:}} page name, known
10339 {{#speciale:Recentchanges}}
10341 Special:RecentChanges
10345 {{#speciale:}} page name with subpage, known
10349 {{#speciale:Recentchanges/param}}
10351 Special:RecentChanges/param
10355 {{#speciale:}} page name, unknown
10359 {{#speciale:foobar nonexistent}}
10361 Special:Foobar_nonexistent
10367 ### For Parsoid-specific tests, see
10368 #### https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
10373 parsoid=wt2html,wt2wt,html2html
10375 [[Image:foobar.jpg]]
10377 <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>
10380 <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>
10385 Simple image (using File: namespace, now canonical)
10387 [[File:Foobar.jpg]]
10389 <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>
10392 <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>
10397 Right-aligned image
10399 [[File:Foobar.jpg|right]]
10401 <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>
10404 <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>
10410 [[File:Foobar.jpg|right|Caption text]]
10412 <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>
10415 <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>
10419 Image with caption, bug 53312 #1
10421 [[File:Foobar.jpg|right|Caption page stuff]]
10423 <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>
10426 <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>
10430 Image with caption, bug 53312 #2
10432 [[File:Foobar.jpg|right|Caption page=]]
10434 <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>
10437 <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>
10441 Image with caption, bug 53312 #3
10443 [[File:Foobar.jpg|right|Caption page=stuff]]
10445 <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>
10448 <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>
10452 Allow empty links in image captions (Bug 60753)
10456 [[File:Foobar.jpg|thumb|Caption [[Link1]]
10461 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Caption <a href="/index.php?title=Link1&action=edit&redlink=1" class="new" title="Link1 (page does not exist)">Link1</a> [[]] <a href="/index.php?title=Link2&action=edit&redlink=1" class="new" title="Link2 (page does not exist)">Link2</a></div></div></div>
10464 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"caption","ak":"Caption [[Link1]]\n[[]]\n[[Link2]]\n"}],"dsr":[0,59,2,2]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"dsr":[2,null,null,null]}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption data-parsoid='{"dsr":[null,57,null,null]}'>Caption <a rel="mw:WikiLink" href="./Link1" data-parsoid='{"stx":"simple","a":{"href":"./Link1"},"sa":{"href":"Link1"},"dsr":[32,41,2,2]}'>Link1</a>
10466 <a rel="mw:WikiLink" href="./Link2" data-parsoid='{"stx":"simple","a":{"href":"./Link2"},"sa":{"href":"Link2"},"dsr":[47,56,2,2]}'>Link2</a>
10467 </figcaption></figure>
10471 Link with empty target
10480 Image with empty attribute
10482 parsoid=wt2html,wt2wt,html2html
10484 [[File:Foobar.jpg|right||Caption text]]
10486 <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>
10489 <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>
10493 1. Block image with individual attributes from templates
10495 [[File:Foobar.jpg|thumb|{{echo|137px}}|This is a caption]]
10497 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption</div></div></div>
10500 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" data-mw='{"attribs":[["thumbnail",{"html":"thumb"}],["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;137px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;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]}\">137px</span>"}]]}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
10504 2. Block Image with individual attributes from templates
10506 [[File:Foobar.jpg|{{echo|thumb}}|{{echo|137px}}|This is a caption]]
10508 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption</div></div></div>
10511 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" data-mw='{"attribs":[["thumbnail",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;thumb&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;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]}\">thumb</span>"}],["width",{"html":"<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;137px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;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]}\">137px</span>"}]]}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
10515 3. Inline image with individual attributes from templates
10517 [[File:Foobar.jpg|{{echo|50px}}]]
10519 <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>
10522 <p><span typeof="mw:Image mw:ExpandedAttrs" about="#mwt2" data-mw='{"attribs":[["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;50px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;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]}\">50px</span>"}]]}' data-parsoid='{"optList":[{"ck":"width","ak":"{{echo|50px}}"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
10525 ## Parsoid does not provide editing support for images where templates produce multiple image attributes.
10526 ## To signal this, we add a 'mw:Placeholder' type to such images. This could change in the future.
10528 Image with multiple attributes from the same template
10530 [[File:Foobar.jpg|{{image_attribs}}]]
10532 <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>
10535 <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>
10539 Image with link tails
10543 123[[File:Foobar.jpg]]456
10544 123[[File:Foobar.jpg|right]]456
10545 123[[File:Foobar.jpg|thumb]]456
10547 <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
10549 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
10550 123<div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>456
10553 <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>
10554 123<figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>456
10555 123<figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220"></a></figure>456
10559 Image with multiple captions -- only last one is accepted
10561 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
10563 <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>
10566 <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>
10570 Image with multiple widths -- use last
10572 [[File:Foobar.jpg|200px|300px|caption]]
10574 <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>
10577 <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>
10581 Image with multiple alignments -- use first (bug 48664)
10585 [[File:Foobar.jpg|thumb|left|right|center|caption]]
10587 [[File:Foobar.jpg|middle|text-top|caption]]
10589 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10590 <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>
10593 <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>
10594 <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>
10598 Image with width attribute at different positions
10600 [[File:Foobar.jpg|200px|right|Caption]]
10601 [[File:Foobar.jpg|right|200px|Caption]]
10602 [[File:Foobar.jpg|right|Caption|200px]]
10604 <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>
10605 <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>
10606 <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>
10609 <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>
10610 <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>
10611 <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>
10614 # a sad bit of backward-compatibility
10616 Image with size specified with pxpx (bug 13500, 51628)
10618 parsoid=wt2html,wt2wt,html2html
10620 [[File:Foobar.jpg|20pxpx]]
10621 [[File:Foobar.jpg|200x20pxpx]]
10623 <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>
10624 <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>
10627 <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>
10631 Image with link parameter, wiki target
10633 [[File:Foobar.jpg|link=Main Page]]
10635 <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>
10638 <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>
10641 # parsoid bug 49293 (part 1)
10643 Image with link parameter, URL target
10645 [[File:Foobar.jpg|link=http://example.com/]]
10647 <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>
10650 <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>
10653 # parsoid bug 49293 (part 2)
10655 Image with link parameter, protocol-less URL target
10657 [[File:Foobar.jpg|link=//example.com/]]
10659 <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>
10662 <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>
10666 Image with link parameter, wgExternalLinkTarget
10668 [[Image:foobar.jpg|link=http://example.com/]]
10670 wgExternalLinkTarget='foobar'
10672 <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>
10677 Image with link parameter, wgNoFollowLinks set to false
10679 [[Image:foobar.jpg|link=http://example.com/]]
10681 wgNoFollowLinks=false
10683 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10688 Image with link parameter, wgNoFollowDomainExceptions
10690 [[Image:foobar.jpg|link=http://example.com/]]
10692 wgNoFollowDomainExceptions='example.com'
10694 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10699 Image with link parameter, wgExternalLinkTarget, unnamed parameter
10701 [[Image:foobar.jpg|link=http://example.com/|Title]]
10703 wgExternalLinkTarget='foobar'
10705 <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>
10710 Image with empty link parameter
10712 [[File:Foobar.jpg|link=]]
10714 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
10717 <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>
10721 Image with link parameter (wiki target) and unnamed parameter
10723 [[File:Foobar.jpg|link=Main_Page|Title]]
10725 <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>
10728 <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>
10732 Image with link parameter (URL target) and unnamed parameter
10734 [[File:Foobar.jpg|link=http://example.com/|Title]]
10736 <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>
10739 <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>
10743 Thumbnail image with link parameter
10746 parsoid=wt2html,wt2wt,html2html
10748 [[File:Foobar.jpg|thumb|link=http://example.com/|Title]]
10750 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="http://example.com/"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10753 <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>
10757 Manually-specified thumbnail image
10761 [[File:Foobar.jpg|thumb=Thumb.png|Title]]
10763 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/File:Foobar.jpg"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10766 <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>
10770 Manually-specified thumbnail image with explicit link to wiki page
10773 parsoid=wt2html,wt2wt,html2html
10775 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|Title]]
10777 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10780 <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>
10784 Manually-specified thumbnail image with explicit link to url
10787 parsoid=wt2html,wt2wt,html2html
10789 [[File:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
10791 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="http://example.com"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10794 <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>
10798 Manually-specified thumbnail image with explicit no link
10801 parsoid=wt2html,wt2wt,html2html
10803 [[File:Foobar.jpg|thumb=Thumb.png|link=|Title]]
10805 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10808 <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>
10812 Manually-specified thumbnail image with explicit link and alt text
10815 parsoid=wt2html,wt2wt,html2html
10817 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|alt=alttext|Title]]
10819 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="alttext" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10822 <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>
10826 Image with frame and link
10828 parsoid=wt2html,wt2wt,html2html
10830 [[File:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
10832 <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>
10835 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page">Main Page</a></figcaption></figure>
10839 Image with frame and link and explicit alt
10841 parsoid=wt2html,wt2wt,html2html
10843 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
10845 <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>
10848 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img alt="Altitude" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page">Main Page</a></figcaption></figure>
10852 Image with wiki markup in implicit alt
10854 parsoid=wt2html,wt2wt,html2html
10856 [[Image:Foobar.jpg|testing '''bold''' in alt]]
10858 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
10860 <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>
10861 </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>
10864 <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>
10865 <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>
10868 ###################
10869 # Conflicting image format options.
10870 # First option specified should 'win'.
10871 # All three cases in each test should be identical.
10874 Image with 'frameless' first.
10876 parsoid=wt2html,wt2wt,html2html
10878 [[File:Foobar.jpg|frameless|caption]]
10880 [[File:Foobar.jpg|frameless|frame|caption]]
10882 [[File:Foobar.jpg|frameless|thumb|caption]]
10884 <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>
10885 </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>
10886 </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>
10889 <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>
10890 <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>
10891 <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>
10895 Image with 'frame' first.
10897 parsoid=wt2html,wt2wt,html2html
10899 [[File:Foobar.jpg|frame|caption]]
10900 [[File:Foobar.jpg|frame|frameless|caption]]
10901 [[File:Foobar.jpg|frame|thumb|caption]]
10903 <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>
10904 <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>
10905 <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>
10908 <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><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><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>
10912 Image with 'thumb' first.
10914 parsoid=wt2html,wt2wt,html2html
10916 [[File:Foobar.jpg|thumb|caption]]
10917 [[File:Foobar.jpg|thumb|frameless|caption]]
10918 [[File:Foobar.jpg|thumb|frame|caption]]
10920 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10921 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10922 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10925 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
10928 ###################
10930 # See https://www.mediawiki.org/wiki/Help:Images#Size_and_frame
10931 # and https://bugzilla.wikimedia.org/show_bug.cgi?id=62258
10932 # Foobar has actual size of 1941x220
10933 # 1. Thumbs & frameless always reduce, can't be enlarged unless it's
10934 # a scalable format.
10935 # 2. Framed images always ignore size options; always render at default size.
10936 # 3. "Unspecified format" and border are the only types which can be
10940 Image: "unspecified format" and border enlarge
10942 parsoid=wt2html,wt2wt,html2html
10944 [[File:Foobar.jpg|2000px]]
10946 [[File:Foobar.jpg|border|2000px]]
10948 <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>
10949 </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>
10952 <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>
10953 <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>
10957 Image: "unspecified format" and border reduce
10959 parsoid=wt2html,wt2wt,html2html
10961 [[File:Foobar.jpg|1000px]]
10963 [[File:Foobar.jpg|border|1000px]]
10965 <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>
10966 </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>
10969 <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>
10970 <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>
10974 Image: thumbs reduce
10976 parsoid=wt2html,wt2wt,html2html
10978 [[File:Foobar.jpg|thumb|50px]]
10980 <div class="thumb tright"><div class="thumbinner" style="width:52px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10983 <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>
10987 Image: bitmap thumbs can't be enlarged past original size, but vector can.
10989 parsoid=wt2html,wt2wt,html2html
10991 [[File:Foobar.jpg|thumb|2000px]]
10993 [[File:Foobar.svg|thumb|2000px]]
10995 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10996 <div class="thumb tright"><div class="thumbinner" style="width:2002px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="Foobar.svg" src="http://example.com/images/thumb/f/ff/Foobar.svg/2000px-Foobar.svg.png" width="2000" height="1500" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/3000px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/4000px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10999 <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>
11000 <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>
11004 Image: frameless can reduce in size
11006 parsoid=wt2html,wt2wt,html2html
11008 [[File:Foobar.jpg|frameless|50px]]
11010 <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>
11013 <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>
11017 Image: bitmap frameless can't be enlarged past original size, but vector can
11019 parsoid=wt2html,wt2wt,html2html
11021 [[File:Foobar.jpg|frameless|2000px]]
11023 [[File:Foobar.svg|frameless|2000px]]
11025 <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>
11026 </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>
11029 <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>
11030 <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>
11034 Image: framed images are always unscaled.
11036 parsoid=wt2html,wt2wt,html2html
11038 [[File:Foobar.jpg|frame]]
11040 [[File:Foobar.jpg|frame|50px]]
11042 [[File:Foobar.jpg|frame|50x50px]]
11044 [[File:Foobar.jpg|frame|2000px]]
11046 <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>
11047 <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>
11048 <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>
11049 <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>
11052 <figure class="mw-default-size" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure>
11055 ###################
11058 Link to image page- image page normally doesn't exists, hence edit link
11059 Add test with existing image page
11060 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
11064 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
11069 bug 18784 Link to non-existent image page with caption should use caption as link text
11071 [[:Image:test|caption]]
11073 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
11078 Frameless image caption with a free URL
11080 [[File:Foobar.jpg|http://example.com]]
11082 <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>
11085 <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>
11089 Thumbnail image caption with a free URL
11093 [[File:Foobar.jpg|thumb|http://example.com]]
11095 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
11098 <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>
11102 Thumbnail image caption with a free URL and explicit alt
11105 parsoid=wt2html,wt2wt,html2html
11107 [[File:Foobar.jpg|thumb|http://example.com|alt=Alteration]]
11109 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
11112 <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>
11116 SVG thumbnails with no language set
11119 [[File:Foobar.svg|thumb|caption]]
11121 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
11124 <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>
11128 SVG thumbnails with language de
11130 parsoid=wt2html,wt2wt,html2html
11132 [[File:Foobar.svg|thumb|caption|lang=de]]
11134 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=File:Foobar.svg&lang=de" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/langde-180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/langde-270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/langde-360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
11137 <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>
11141 SVG thumbnails with invalid language code
11143 parsoid=wt2html,wt2wt,html2html
11145 [[File:Foobar.svg|thumb|caption|lang=invalid.language.code]]
11147 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>lang=invalid.language.code</div></div></div>
11150 <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>
11154 BUG 1887: A ISBN with a thumbnail
11156 [[File:Foobar.jpg|thumb|ISBN 1235467890]]
11158 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div>
11161 <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>
11165 BUG 1887: A RFC with a thumbnail
11167 [[File:Foobar.jpg|thumb|This is RFC 12354]]
11169 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
11172 <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>
11176 BUG 1887: A mailto link with a thumbnail
11178 [[File:Foobar.jpg|thumb|Please mailto:nobody@example.com]]
11180 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a rel="nofollow" class="external free" href="mailto:nobody@example.com">mailto:nobody@example.com</a></div></div></div>
11183 <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>
11186 # Pending resolution to bug 368
11188 BUG 648: Frameless image caption with a link
11190 [[File:Foobar.jpg|text with a [[link]] in it]]
11192 <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>
11195 <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>
11199 BUG 648: Frameless image caption with a link (suffix)
11201 [[File:Foobar.jpg|text with a [[link]]foo in it]]
11203 <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>
11206 <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>
11210 BUG 648: Frameless image caption with an interwiki link
11212 [[File:Foobar.jpg|text with a [[MeatBall:Link]] in it]]
11214 <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>
11217 <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>
11221 BUG 648: Frameless image caption with a piped interwiki link
11223 [[File:Foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
11225 <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>
11228 <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>
11232 Escape HTML special chars in image alt text
11234 [[File:Foobar.jpg|& < > "]]
11236 <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>
11239 <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>
11243 BUG 499: Alt text should have Ӓ, not &1234;
11245 [[File:Foobar.jpg|♀]]
11247 <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>
11250 <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>
11254 Broken image caption with link
11256 parsoid=wt2html,wt2wt,html2html
11258 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
11260 <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.
11263 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="Main_Page">this</a> is just an ordinary link.</p>
11267 Image caption containing another image
11269 [[File:Foobar.jpg|thumb|This is a caption with another [[File:Thumb.png|image]] inside it!]]
11271 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption with another <a href="/wiki/File:Thumb.png" class="image" title="image"><img alt="image" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" /></a> inside it!</div></div></div>
11274 <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>
11278 Image: caption containing a newline
11280 [[File:Foobar.jpg|This
11283 <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>
11286 <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>
11290 Image: caption containing leading space
11291 (The leading space should not trigger nowiki escaping in wt2wt mode)
11293 [[File:Foobar.jpg|thumb| bar]]
11295 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>bar</div></div></div>
11298 <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>
11302 Image: caption containing a table
11304 parsoid=wt2html,wt2wt,html2html
11306 [[Image:Foobar.jpg|thumb|200px|This is an example image thumbnail caption with a table
11312 and some more text.]]
11314 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is an example image thumbnail caption with a table <table> <tr> <th> Foo </th> <th> Bar </th></tr> <tr> <td> Foo1 </td> <td> Bar1 </td></tr></table> and some more text.</div></div></div>
11317 <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
11320 <tr><th>Foo </th><th>Bar</th></tr>
11323 <td>Bar1</td></tr></tbody></table>and some more text.</figcaption></figure>
11327 Bug 3090: External links other than http: in image captions
11329 [[File:Foobar.jpg|thumb|200x200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
11331 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a rel="nofollow" class="external text" href="irc://example.net">irc</a> and <a rel="nofollow" class="external text" href="https://example.com">Secure</a> ext links in it.</div></div></div>
11334 <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>
11340 parsoid=wt2html,wt2wt,html2html
11342 [[Image:foobar.jpg|a|class=b]]
11344 <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>
11347 <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>
11351 Localized image handling (1).
11353 parsoid=wt2html,wt2wt,html2html
11356 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
11358 <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>
11361 <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>
11365 Localized image handling (2).
11368 parsoid=wt2html,wt2wt,html2html
11371 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
11373 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/Foo" title="Foo"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/Archivo:Foobar.jpg" class="internal" title="Aumentar"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
11376 <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>
11380 "border", "frameless" and "class" attributes on an image.
11383 parsoid=wt2html,wt2wt,html2html
11385 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
11387 <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>
11390 <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>
11393 # Note that 'right' is the default alignment, despite the misspelled 'righ' below
11395 Invalid image attributes (bug 62500)
11398 parsoid=wt2html,wt2wt,html2html
11400 [[File:Foobar.jpg|thumb|float|left|caption]]
11402 [[File:Foobar.jpg|thumb|righ|caption]]
11404 [[File:Foobar.jpg|bogus1|thumb|bogus2|left|bogus3|caption]]
11406 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
11407 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
11408 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
11411 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
11417 #REDIRECT [[File:Barfoo.jpg]]
11423 [[Image:Barfoo.jpg]]
11425 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
11430 Missing image with uploads disabled
11434 [[Image:Foobaz.jpg]]
11436 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
11440 # Parsoid-specific testing for images
11441 # https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
11442 # Currently imperfect due to a flaw in the Parsoid testrunner
11444 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
11448 Parsoid-specific image handling - simple image with size and middle alignment
11450 [[File:Foobar.jpg|middle|50px]]
11452 <p><span class="mw-valign-middle" typeof="mw:Image">
11453 <a href="File:Foobar.jpg">
11454 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
11461 Parsoid-specific image handling - simple image with size, middle alignment,
11462 non-standard namespace alias
11464 parsoid=wt2wt,wt2html,html2html
11466 [[Image:Foobar.jpg|middle|50px]]
11468 <p><span class="mw-valign-middle" typeof="mw:Image">
11469 <a href="File:Foobar.jpg">
11470 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
11477 Parsoid-specific image handling - simple image with size and middle alignment
11480 [[File:Foobar.jpg|50px|middle]]
11482 <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>
11486 Parsoid-specific image handling - simple image with size and middle alignment
11487 and non-standard namespace name
11489 parsoid=wt2html,wt2wt,html2html
11491 [[Image:Foobar.jpg|50px|middle]]
11493 <p><span class="mw-valign-middle" typeof="mw:Image">
11494 <a href="File:Foobar.jpg">
11495 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
11502 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
11504 [[File:Foobar.jpg|500x10px|baseline|caption]]
11506 <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>
11510 Parsoid-specific image handling - simple image with border and size spec
11512 [[File:Foobar.jpg|50px|border|caption]]
11514 <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>
11518 Parsoid-specific image handling - thumbnail with halign, valign, and caption
11520 [[File:Foobar.jpg|left|baseline|thumb|caption content]]
11522 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb">
11523 <a href="File:Foobar.jpg">
11524 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220" />
11526 <figcaption>caption content</figcaption>
11531 Parsoid-specific image handling - thumbnail with halign, valign, and caption
11534 [[File:Foobar.jpg|thumb|left|baseline|caption content]]
11536 <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>
11540 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
11542 [[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
11544 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb">
11545 <a href="File:Foobar.jpg">
11546 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" />
11548 <figcaption>caption</figcaption>
11553 Parsoid-specific image handling - thumbnail with specific size, halign,
11554 valign, and caption (existing content)
11556 [[File:Foobar.jpg|thumb|50x50px|right|middle|caption]]
11558 <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>
11562 Parsoid-specific image handling - framed image with specific size and caption
11565 parsoid=wt2html,wt2wt,html2html
11567 [[File:Foobar.jpg|frame|500x50px|caption]]
11569 <figure typeof="mw:Image/Frame">
11570 <a href="File:Foobar.jpg">
11571 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941" />
11573 <figcaption>caption</figcaption>
11578 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
11581 parsoid=wt2html,wt2wt,html2html
11583 [[File:Foobar.jpg|left|baseline|frame|500x50px|caption]]
11585 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame">
11586 <a href="File:Foobar.jpg">
11587 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941" />
11589 <figcaption>caption</figcaption>
11594 Parsoid-specific image handling - frameless image with specific size, border, and caption
11596 [[File:Foobar.jpg|frameless|442x50px|border|caption]]
11598 <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>
11602 Parsoid-specific image handling - simple image with a formatted caption
11604 [[File:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
11606 <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>"}'>
11607 <a href="File:Foobar.jpg">
11608 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941">
11613 Parsoid-specific image handling - caption with a template in it
11615 [[File:Foobar.jpg|thumb|200x23px|This caption has a {{echo|transclusion}} in it.]]
11617 <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>
11621 Parsoid-specific image handling - caption with unbalanced tags in it
11623 parsoid=wt2html,wt2wt,html2html
11626 [[File:Foobar.jpg|thumb|200x200px|This caption has a <center>unbalanced tag in it.]]
11630 <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>
11635 Parsoid-specific image handling - empty caption (1)
11637 parsoid=wt2html,wt2wt
11639 [[File:Foobar.jpg|thumb|]]
11641 <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>
11644 # empty captions don't get serialized unless we're in the "round trip" case
11646 Parsoid-specific image handling - empty caption (2)
11650 <figure class="mw-default-size" typeof="mw:Image/Thumb">
11651 <a href="File:Foobar.jpg">
11652 <img resource="./File:Foobar.jpg"
11653 src="//example.com/images/3/3a/Foobar.jpg"
11654 height="25" width="220"/>
11656 <figcaption></figcaption>
11659 [[File:Foobar.jpg|thumb]]
11663 Parsoid-specific image handling - whitespace caption
11665 [[File:Foobar.jpg|thumb| ]]
11667 <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>
11671 Parsoid-specific image handling - lang option
11674 [[File:Foobar.svg|lang=de|caption]]
11678 <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>
11687 Subpage test/subpage
11695 subpage title=[[Subpage test]]
11699 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
11704 Subpage noslash link
11706 subpage title=[[Subpage test]]
11710 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
11714 # TODO: make this PHP-parser compatible!
11716 Relative subpage noslash link
11718 parsoid=wt2wt,wt2html,html2html
11719 subpage title=[[Subpage test/1/2/3/4]]
11725 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage/">subpage</a></p>
11726 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
11730 Parsoid: dot-slash prefixed wikilinks
11740 </p><p>[[././baz/]]
11745 </p><p>[[././baz/]]
11750 Render invalid page names as plain text (bug 51090)
11763 [[{{echo|./../foo}}|bar]]
11764 [[{{echo|foo/.}}|bar]]
11765 [[{{echo|foo/..}}|bar]]
11766 [[{{echo|foo~~~~bar}}]]
11767 [[{{echo|foo>bar}}]]
11768 [[{{echo|foo././bar}}]]
11769 [[{{echo|foo{bar}}]]
11770 [[{{echo|foo}bar}}]]
11771 [[{{echo|foo[bar}}]]
11772 [[{{echo|foo]bar}}]]
11773 [[{{echo|foo<bar}}]]
11775 <p>[[./../foo|bar]]
11785 </p><p>[[./../foo|bar]]
11798 <p>[[./../foo|bar]][[foo�|bar]][[foo/.|bar]][[foo/..|bar]][[foo~~~bar]][[foo>bar]][[foo[bar]][[.]][[..]][[foo././bar]]</p>
11799 <p>[[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"./../foo"}},"i":0}}]}'>./../foo</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/."}},"i":0}}]}'>foo/.</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/.."}},"i":0}}]}'>foo/..</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo~~~~bar"}},"i":0}}]}'>foo~~~~bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo>bar"}},"i":0}}]}'>foo>bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo././bar"}},"i":0}}]}'>foo././bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo{bar"}},"i":0}}]}'>foo{bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo}bar"}},"i":0}}]}'>foo}bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo[bar"}},"i":0}}]}'>foo[bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo]bar"}},"i":0}}]}'>foo]bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<bar"}},"i":0}}]}'>foo<bar</span>]]</p>
11807 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
11812 BUG 561: {{/Subpage}}
11814 subpage title=[[Page]]
11818 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
11826 Category:MediaWiki User's Guide
11834 [[:Category:MediaWiki User's Guide]]
11836 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
11845 [[Category:MediaWiki User's Guide]]
11847 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11851 PAGESINCATEGORY invalid title fatal (r33546 fix)
11853 {{PAGESINCATEGORY:<bogus>}}
11860 Category with different sort key
11864 [[Category:MediaWiki User's Guide|Foo]]
11866 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11870 Category with identical sort key
11874 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
11876 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11880 Category with empty sort key
11885 [[Category:MediaWiki User's Guide|]]
11887 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
11891 Category with empty sort key and parentheses
11896 [[Category:Foo (bar)|]]
11898 [[Category:Foo (bar)|Foo]]
11902 Category with link tail
11907 123[[Category:Foo]]456
11909 123[[Category:Foo]]456
11913 Category with template
11918 [[Category:{{echo|Foo}}]]
11920 [[Category:{{echo|Foo}}]]
11924 Category with template in sort key
11929 [[Category:Foo|{{echo|Bar}}]]
11931 [[Category:Foo|{{echo|Bar}}]]
11935 Category with template in sort key and title
11940 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
11942 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
11946 Category / paragraph interactions
11948 Foo [[Category:Baz]] Bar
11950 Foo [[Category:Baz]]
11958 [[Category:Baz]] Bar
11971 {{echo|[[Category:Baz]]}}
11986 Parsoid: Serialize link to category page with colon escape
11992 [[:Category:Foo|Bar]]
11995 <a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a>
11996 <a rel="mw:WikiLink" href="Category:Foo">Bar</a>
12001 Parsoid: Link prefix/suffixes aren't applied to category links
12003 parsoid=wt2html,wt2wt,html2html
12008 <p>x<link rel="mw:PageProp/Category" href="Category:Foo">y</p>
12012 Parsoid: Serialize link to file page with colon escape
12018 [[:File:Foo.png|Bar]]
12021 <a rel="mw:WikiLink" href="File:Foo.png">File:Foo.png</a>
12022 <a rel="mw:WikiLink" href="File:Foo.png">Bar</a>
12027 Parsoid: Serialize a genuine category link without colon escape
12032 [[Category:Foo|Bar]]
12034 <link rel="mw:PageProp/Category" href="Category:Foo">
12035 <link rel="mw:PageProp/Category" href="Category:Foo#Bar">
12039 Parsoid: Defaultsort
12043 {{DEFAULTSORT:Foo}}
12045 <meta property="mw:PageProp/categorydefaultsort" content="Foo"/>
12049 ### Inter-language links
12052 Interlanguage links
12060 es:Alimento fr:Nourriture zh:食品
12062 <p><link rel="mw:PageProp/Language" href="//es.wikipedia.org/wiki/Alimento"/>
12063 <link rel="mw:PageProp/Language" href="//fr.wikipedia.org/wiki/Nourriture"/>
12064 <link rel="mw:PageProp/Language" href="//zh.wikipedia.org/wiki/食品"/></p>
12068 Duplicate interlanguage links (bug 24502)
12079 <p><link rel="mw:PageProp/Language" href="//es.wikipedia.org/wiki/1"/>
12080 <link rel="mw:PageProp/Language" href="//es.wikipedia.org/wiki/2"/>
12081 <link rel="mw:PageProp/Language" href="//fr.wikipedia.org/wiki/1"/>
12082 <link rel="mw:PageProp/Language" href="//fr.wikipedia.org/wiki/2"/></p>
12089 Basic section headings
12096 ===Smaller headline===
12099 <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>
12102 <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>
12105 <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>
12111 Section headings with TOC
12114 === Subheadline 1 ===
12115 ===== Skipping a level =====
12116 ====== Skipping a level ======
12120 ===Another headline===
12122 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12124 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
12126 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
12128 <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>
12130 <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>
12137 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
12139 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
12145 <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>
12146 <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>
12147 <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>
12148 <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>
12149 <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>
12152 <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>
12156 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
12158 Handling of sections up to level 6 and beyond
12161 == Level 2 Heading==
12162 === Level 3 Heading===
12163 ==== Level 4 Heading====
12164 ===== Level 5 Heading=====
12165 ====== Level 6 Heading======
12166 ======= Level 7 Heading=======
12167 ======== Level 8 Heading========
12168 ========= Level 9 Heading=========
12169 ========== Level 10 Heading==========
12171 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12173 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
12175 <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>
12177 <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>
12179 <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>
12181 <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>
12183 <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>
12184 <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>
12185 <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>
12186 <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>
12187 <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>
12201 <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>
12202 <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>
12203 <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>
12204 <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>
12205 <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>
12206 <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>
12207 <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>
12208 <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>
12209 <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>
12210 <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>
12215 TOC regression (bug 9764)
12219 ==== title 1.1.1 ====
12224 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12226 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
12228 <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>
12230 <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>
12233 <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>
12236 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
12238 <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>
12244 <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>
12245 <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>
12246 <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>
12247 <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>
12248 <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>
12249 <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>
12254 TOC with wgMaxTocLevel=3 (bug 6204)
12260 ==== title 1.1.1 ====
12265 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12267 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
12269 <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>
12270 <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>
12273 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
12275 <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>
12281 <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>
12282 <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>
12283 <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>
12284 <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>
12285 <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>
12286 <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>
12291 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
12297 ====Section 1.1.1====
12298 ====Section 1.1.1.1====
12301 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12303 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
12305 <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>
12308 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
12312 <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>
12313 <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>
12314 <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>
12315 <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>
12316 <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>
12322 Resolving duplicate section names
12327 <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>
12328 <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>
12333 Resolving duplicate section names with differing case (bug 10721)
12338 <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>
12339 <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>
12351 Template with sections, __NOTOC__
12358 <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>
12359 <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>
12360 <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>
12361 <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>
12366 __NOEDITSECTION__ keyword
12372 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
12373 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
12378 Link inside a section heading
12380 ==Section with a [[Main Page|link]] in it==
12382 <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>
12387 TOC regression (bug 12077)
12394 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12396 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
12398 <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>
12401 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
12405 <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>
12406 <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>
12407 <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>
12412 BUG 1219 URL next to image (good)
12414 http://example.com [[Image:foobar.jpg]]
12416 <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>
12421 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
12424 The line above must have a trailing space!
12427 But just in case it doesn't...
12429 <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>
12430 <p>The line above must have a trailing space!
12432 <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>
12433 <p>But just in case it doesn't...
12438 Header with special characters (bug 25462)
12440 The tooltips shall not show entities to the user (ie. be double escaped)
12457 <p>The tooltips shall not show entities to the user (ie. be double escaped)
12459 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12461 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
12462 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
12463 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
12464 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
12465 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
12469 <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>
12472 <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>
12475 <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>
12478 <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>
12481 <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>
12487 Headers with excess '=' characters
12488 (Are similar tests necessary beyond the 1st level?)
12492 =''italic'' heading==
12493 ==''italic'' heading=
12495 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12497 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
12498 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
12499 <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>
12500 <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>
12504 <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>
12505 <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>
12506 <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>
12507 <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>
12512 HTML headers vs TOC (bug 23393)
12513 (__NOEDITSECTION__ for clearer output, doesn't matter here)
12525 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12527 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
12529 <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>
12530 <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>
12533 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
12535 <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>
12536 <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>
12542 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
12543 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
12544 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
12545 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
12546 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
12547 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
12552 Single-line or multiline-comments can follow headings
12554 parsoid=wt2html,wt2wt
12562 <h2><span class="mw-headline" id="foo">foo</span></h2>
12563 <h2><span class="mw-headline" id="bar">bar</span></h2>
12564 <h2><span class="mw-headline" id="baz">baz</span></h2>
12569 BUG 1219 URL next to image (broken)
12571 http://example.com[[Image:foobar.jpg]]
12573 <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>
12578 Bug 1186 news: in the middle of text
12580 http://en.wikinews.org/wiki/Wikinews:Workplace
12582 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
12588 Namespaced link must have a title
12597 Namespaced link must have a title (bad fragment version)
12599 [[Project:#fragment]]
12601 <p>[[Project:#fragment]]
12607 ### HTML tags and HTML attributes
12611 div with no attributes
12613 <div>HTML rocks</div>
12615 <div>HTML rocks</div>
12620 div with double-quoted attribute
12622 <div id="rock">HTML rocks</div>
12624 <div id="rock">HTML rocks</div>
12629 div with single-quoted attribute
12631 <div id='rock'>HTML rocks</div>
12633 <div id="rock">HTML rocks</div>
12638 div with unquoted attribute
12640 <div id=rock>HTML rocks</div>
12642 <div id="rock">HTML rocks</div>
12647 div with illegal double attributes
12649 <div id="a" id="b">HTML rocks</div>
12651 <div id="b">HTML rocks</div>
12655 # FIXME: produce empty string instead of "class" in the PHP parser, following
12658 div with empty attribute value, space before equals
12662 <div class =>HTML rocks</div>
12664 <div class="">HTML rocks</div>
12668 # The PHP parser escapes the opening brace to { for some reason, so
12669 # disabled this test for it.
12671 div with braces in attribute value
12675 <div title="{}">Foo</div>
12677 <div title="{}">Foo</div>
12680 # This it very inconsistent in the PHP parser: it returns
12681 # class="class" if there is a space between the name and the equal sign (see
12682 # 'div with empty attribute value, space before equals'), but strips the
12683 # attribute completely if the space is missing. We hope that not much content
12684 # depends on this, so are implementing the behavior below in Parsoid for
12685 # consistencies' sake. Disabled for the PHP parser.
12686 # FIXME: fix this behavior in the PHP parser?
12688 div with empty attribute value, no space before equals
12692 <div class=>HTML rocks</div>
12694 <div class="">HTML rocks</div>
12699 HTML multiple attributes correction
12701 <p class="error" class="awesome">Awesome!</p>
12703 <p class="awesome">Awesome!</p>
12708 Table multiple attributes correction
12711 !+ class="error" class="awesome"| status
12716 <th class="awesome"> status
12724 <DIV ID="x">HTML ROCKS</DIV>
12726 <div id="x">HTML ROCKS</div>
12731 Non-ASCII pseudo-tags are rendered as text
12740 Pseudo-tag with URL 'name' renders as url link
12742 <http://example.com/>
12744 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
12749 text with amp in the middle of nowhere
12753 <p>Remember AT&T?
12758 text with character entity: eacute
12760 I always thought é was a cute letter.
12762 <p>I always thought é was a cute letter.
12767 text with entity-escaped character entity-like string: eacute
12769 I always thought &eacute; was a cute letter.
12771 <p>I always thought &eacute; was a cute letter.
12776 text with undefined character entity: xacute
12778 I always thought &xacute; was a cute letter.
12780 <p>I always thought &xacute; was a cute letter.
12784 # TODO: generalize to PHP parser?
12790 <data value="5">five</data>
12791 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
12792 <mark>This highlighted text</mark>
12794 <p><data value="5">five</data>
12795 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
12796 <mark>This highlighted text</mark></p>
12800 HTML tag with leading space is parsed as text
12804 <p>< div>foo< /div>
12809 ### Nesting tests (see bug 41545, 50604, 51081)
12812 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
12813 # Note that html2wt is considerably more difficult if we use <b> in
12814 # the test case, instead of <big>
12816 Ensure that HTML adoption agency algorithm is properly implemented.
12818 <big>X<big>Y</big>Z</big>
12820 <p><big>X<big>Y</big>Z</big>
12824 # This was bug 41545 in the PHP parser.
12828 <kbd>X<kbd>Y</kbd>Z</kbd>
12830 <p><kbd>X<kbd>Y</kbd>Z</kbd>
12834 # The following cases were bug 51081 in the PHP parser.
12835 # Note that there are some other nestable tags (b, i, etc) which are
12836 # not covered; see bug 51081 for discussion.
12840 <em>X<em>Y</em>Z</em>
12842 <p><em>X<em>Y</em>Z</em>
12847 Nesting of <strong>
12849 <strong>X<strong>Y</strong>Z</strong>
12851 <p><strong>X<strong>Y</strong>Z</strong>
12860 <p><q>X<q>Y</q>Z</q>
12867 <ruby>X<ruby>Y</ruby>Z</ruby>
12869 <p><ruby>X<ruby>Y</ruby>Z</ruby>
12876 <bdo>X<bdo>Y</bdo>Z</bdo>
12878 <p><bdo>X<bdo>Y</bdo>Z</bdo>
12890 [[Media:Foobar.jpg]]
12892 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
12897 Media link with text
12899 [[Media:Foobar.jpg|A neat file to look at]]
12901 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
12905 # FIXME: this is still bad HTML tag nesting
12907 Media link with nasty text
12908 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
12910 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
12912 <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>
12917 Media link to nonexistent file (bug 1702)
12919 [[Media:No such.jpg]]
12921 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
12926 Image link to nonexistent file (bug 1850 - good)
12928 [[Image:No such.jpg]]
12930 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
12935 :Image link to nonexistent file (bug 1850 - bad)
12937 [[:Image:No such.jpg]]
12939 <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>
12946 Character reference normalization in link text (bug 1938)
12948 [[Main Page|this&that]]
12950 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
12957 Test for unicode normalization
12959 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
12963 (bug 19451) Links should refer to the normalized form.
12971 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12972 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12973 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12974 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12975 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12980 Empty attribute crash test (bug 2067)
12982 <font color="">foo</font>
12984 <p><font color="">foo</font>
12989 Empty attribute crash test single-quotes (bug 2067)
12991 <font color=''>foo</font>
12993 <p><font color="">foo</font>
12998 Attribute test: equals, then nothing
13000 <font color=>foo</font>
13002 <p><font>foo</font>
13007 Attribute test: unquoted value
13009 <font color=x>foo</font>
13011 <p><font color="x">foo</font>
13016 Attribute test: unquoted but illegal value (hash)
13018 <font color=#x>foo</font>
13020 <p><font color="#x">foo</font>
13025 Attribute test: no value
13027 <font color>foo</font>
13029 <p><font color="color">foo</font>
13034 Bug 2095: link with three closing brackets
13038 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
13041 <p><a rel="mw:WikiLink" href="./Main_Page">Main Page</a>]</p>
13045 Bug 2095: link with pipe and three closing brackets
13047 [[Main Page|link]]]
13049 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
13052 <p><a rel="mw:WikiLink" href="./Main_Page">link</a>]</p>
13056 Bug 2095: link with pipe and three closing brackets, version 2
13058 [[Main Page|[http://example.com/]]]
13060 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
13063 <p><a rel="mw:WikiLink" href="./Main_Page">[http://example.com/]</a></p>
13072 Template:Dangerous attribute
13074 " onmouseover="alert(document.cookie)
13078 Template:Dangerous style attribute
13080 border-size: expression(alert(document.cookie))
13086 <div style="float: right; {{{1}}}">Magic div</div>
13090 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
13092 <div title="{{test}}"></div>
13094 <div title="This is a test template"></div>
13099 Bug 2304: HTML attribute safety (dangerous template; 2309)
13101 <div title="{{dangerous attribute}}"></div>
13103 <div title=""></div>
13108 Bug 2304: HTML attribute safety (dangerous style template; 2309)
13110 <div style="{{dangerous style attribute}}"></div>
13112 <div style="/* insecure input */"></div>
13117 Bug 2304: HTML attribute safety (safe parameter; 2309)
13119 {{div style|width: 200px}}
13121 <div style="float: right; width: 200px">Magic div</div>
13126 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
13128 {{div style|width: expression(alert(document.cookie))}}
13130 <div style="/* insecure input */">Magic div</div>
13135 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
13137 {{div style|"><script>alert(document.cookie)</script>}}
13139 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
13144 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
13146 {{div style|" ><script>alert(document.cookie)</script>}}
13148 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
13153 Bug 2304: HTML attribute safety (link)
13155 <div title="[[Main Page]]"></div>
13157 <div title="[[Main Page]]"></div>
13162 Bug 2304: HTML attribute safety (italics)
13164 <div title="''foobar''"></div>
13166 <div title="''foobar''"></div>
13171 Bug 2304: HTML attribute safety (bold)
13173 <div title="'''foobar'''"></div>
13175 <div title="'''foobar'''"></div>
13181 Bug 2304: HTML attribute safety (ISBN)
13183 <div title="ISBN 1234567890"></div>
13185 <div title="ISBN 1234567890"></div>
13190 Bug 2304: HTML attribute safety (RFC)
13192 <div title="RFC 1234"></div>
13194 <div title="RFC 1234"></div>
13199 Bug 2304: HTML attribute safety (PMID)
13201 <div title="PMID 1234567890"></div>
13203 <div title="PMID 1234567890"></div>
13208 Bug 2304: HTML attribute safety (web link)
13210 <div title="http://example.com/"></div>
13212 <div title="http://example.com/"></div>
13217 Bug 2304: HTML attribute safety (named web link)
13219 <div title="[http://example.com/ link]"></div>
13221 <div title="[http://example.com/ link]"></div>
13226 Bug 3244: HTML attribute safety (extension; safe)
13228 <div style="<nowiki>background:blue</nowiki>"></div>
13230 <div style="background:blue"></div>
13235 Bug 3244: HTML attribute safety (extension; unsafe)
13237 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
13239 <div style="/* insecure input */"></div>
13243 # More MSIE fun discovered by Tom Gilder
13246 MSIE CSS safety test: spurious slash
13248 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
13250 <div style="/* insecure input */">evil</div>
13255 MSIE CSS safety test: hex code
13257 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
13259 <div style="/* insecure input */">evil</div>
13264 MSIE CSS safety test: comment in url
13266 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
13268 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
13273 MSIE CSS safety test: comment in expression
13275 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
13277 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
13282 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
13284 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
13286 <p style="/* invalid control char */">A</p>
13291 MSIE 6 CSS safety test: Fullwidth (bug 55332)
13293 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
13294 <div style="top:EXPRESSION(alert())">B</div>
13296 <p style="/* insecure input */">A</p>
13297 <div style="/* insecure input */">B</div>
13302 MSIE 6 CSS safety test: IPA extensions (bug 55332)
13304 <div style="background-image:uʀʟ(javascript:alert())">A</div>
13305 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
13307 <div style="/* insecure input */">A</div>
13308 <p style="/* insecure input */">B</p>
13313 MSIE 6 CSS safety test: sup/sub script (bug 55332)
13315 <div style="background-image:url⁽javascript:alert())">A</div>
13316 <div style="background-image:url₍javascript:alert())">B</div>
13317 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
13319 <div style="/* insecure input */">A</div>
13320 <div style="/* insecure input */">B</div>
13321 <p style="/* insecure input */">C</p>
13329 title="data:text/html,<img src=1 onerror=alert(1)>"
13330 style="-o-link:attr(title);-o-link-source:current">X</div>
13332 <div title="data:text/html,<img src=1 onerror=alert(1)>" style="/* insecure input */">X</div>
13337 MSIE 6 CSS safety test: Repetition markers (bug 55332)
13339 <p style="font-size: 100px; color: expres〱ion((title='XSSed'),'red')">A</p>
13340 <p style="font-size: 100px; color: expresゝion((title='XSSed'),'red')">B</p>
13341 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">C</p>
13342 <p style="font-size: 100px; color: expresヽion((title='XSSed'),'red')">D</p>
13343 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
13344 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
13345 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
13347 <p style="/* insecure input */">A</p>
13348 <p style="/* insecure input */">B</p>
13349 <p style="/* insecure input */">C</p>
13350 <p style="/* insecure input */">D</p>
13351 <p style="/* insecure input */">E</p>
13352 <p style="/* insecure input */">F</p>
13353 <p style="/* insecure input */">G</p>
13358 Table attribute legitimate extension
13361 !+ style="<nowiki>color:blue</nowiki>"| status
13366 <th style="color:blue"> status
13372 Table attribute safety
13375 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
13380 <th style="/* insecure input */"> status
13386 CSS line continuation 1
13388 <div style="background-image: u\ rl(test.jpg);"></div>
13390 <div style="/* insecure input */"></div>
13395 CSS line continuation 2
13397 <div style="background-image: u\ rl(test.jpg); "></div>
13399 <div style="/* insecure input */"></div>
13410 Expansion of multi-line templates in attribute values (bug 6255)
13412 <div style="background: {{identity|#00FF00}}">-</div>
13414 <div style="background: #00FF00">-</div>
13420 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
13422 <div style="background:
13425 <div style="background: #00FF00">-</div>
13430 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
13432 <div style="background: #00FF00">-</div>
13434 <div style="background: #00FF00">-</div>
13439 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
13442 Parser hook: empty input
13455 Parser hook: empty input using terminated empty elements
13468 Parser hook: empty input using terminated empty elements (space before)
13481 Parser hook: basic input
13495 Parser hook: case insensitive
13509 Parser hook: case insensitive, redux
13522 Parser hook: nested tags
13526 <tag><tag></tag></tag>
13537 Parser hook: basic arguments
13539 <tag width=200 height = "100" depth = '50' square></tag>
13547 'square' => 'square',
13554 Parser hook: argument containing a forward slash (bug 5344)
13556 <tag filename='/tmp/bla'></tag>
13561 'filename' => '/tmp/bla',
13568 Parser hook: empty input using terminated empty elements (bug 2374)
13581 # </tag> should be output literally since there is no matching tag that begins it
13583 Parser hook: basic arguments using terminated empty elements (bug 2374)
13585 <tag width=200 height = "100" depth = '50' square/>
13595 'square' => 'square',
13604 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
13608 Parser hook: static parser hook not inside a comment
13610 <statictag>hello, world</statictag>
13611 <statictag action=flush/>
13619 Parser hook: static parser hook inside a comment
13621 <!-- <statictag>hello, world</statictag> -->
13622 <statictag action=flush/>
13628 # Nested template calls; this case was broken by Parser.php rev 1.506,
13632 Template:One-parameter
13634 (My parameter is: {{{1}}})
13638 Template:Map-one-parameter
13640 {{{{{1}}}|{{{2}}}}}
13644 Nested template calls
13646 {{Map-one-parameter|One-parameter|param}}
13648 <p>(My parameter is: param)
13657 Sanitizer: Closing of open tags
13659 <s></s><table></table>
13661 <s></s><table></table>
13666 Sanitizer: Closing of open but not closed tags
13675 Sanitizer: Closing of closed but not open tags
13684 Sanitizer: Closing of closed but not open table tags
13686 Table not started</td></tr></table>
13688 <p>Table not started</td></tr></table>
13693 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
13695 <span id="æ: v">byte</span>[[#æ: v|backlink]]
13697 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
13702 Sanitizer: Validating the contents of the id attribute (bug 4515)
13708 Something, but definitely not <br id="9" />...
13712 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
13716 <br id="foo" /><br id="foo" />
13718 Something need to be done. foo-2 ?
13722 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
13725 <meta itemprop="hello" content="world">
13726 <meta http-equiv="refresh" content="5">
13727 <meta itemprop="hello" http-equiv="refresh" content="5">
13728 <link itemprop="hello" href="{{SERVER}}">
13729 <link rel="stylesheet" href="{{SERVER}}">
13730 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
13733 <div itemscope="itemscope">
13734 <p> <meta itemprop="hello" content="world" />
13735 <meta http-equiv="refresh" content="5">
13736 <meta itemprop="hello" content="5" />
13738 <link itemprop="hello" href="http://example.org" />
13739 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
13740 <link itemprop="hello" href="http://example.org" />
13746 Language converter: output gets cut off unexpectedly (bug 5757)
13750 this bit is safe: }-
13752 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
13754 then we get cut off here: }-
13756 all additional text is vanished
13758 <p>this bit is safe: }-
13759 </p><p>but if we add a conversion instance: xxx
13760 </p><p>then we get cut off here: }-
13761 </p><p>all additional text is vanished
13766 Self closed html pairs (bug 5487)
13769 <center><font id="bug" />Centered text</center>
13770 <div><font id="bug2" />In div text</div>
13772 <center><font id="bug" />Centered text</center>
13773 <div><font id="bug2" />In div text</div>
13782 Punctuation: nbsp before exclamation
13786 <p>C'est grave !
13791 Punctuation: CSS !important (bug 11874)
13793 <div style="width:50% !important">important</div>
13795 <div style="width:50% !important">important</div>
13800 Punctuation: CSS ! important (bug 11874; with space after)
13802 <div style="width:50% ! important">important</div>
13804 <div style="width:50% ! important">important</div>
13810 HTML bullet list, closed tags (bug 5497)
13825 HTML bullet list, unclosed tags (bug 5497)
13844 HTML ordered list, closed tags (bug 5497)
13859 HTML ordered list, unclosed tags (bug 5497)
13878 HTML nested bullet list, closed tags (bug 5497)
13903 HTML nested bullet list, open tags (bug 5497)
13932 HTML nested ordered list, closed tags (bug 5497)
13957 HTML nested ordered list, open tags (bug 5497)
13986 HTML ordered list item with parameters oddity
13988 <ol><li id="fragment">One</li>
13991 <ol><li id="fragment">One</li>
13996 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
13998 bug 5918: autonumbering
14000 [http://first/] [http://second] [ftp://ftp]
14004 [mailto:enclosed@mail.tld With target]
14006 [mailto:enclosed@mail.tld]
14008 mailto:inline@mail.tld
14010 <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>
14011 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
14012 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
14013 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
14014 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
14017 <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>
14018 <p><a rel="mw:ExtLink" href="ftp://inlineftp">ftp://inlineftp</a></p>
14019 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld">With target</a></p>
14020 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld"></a></p>
14021 <p><a rel="mw:ExtLink" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a></p>
14026 # Security and HTML correctness
14027 # From Nick Jenkins' fuzz testing
14031 Fuzz testing: Parser13
14046 Fuzz testing: Parser14
14051 <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>
14052 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14054 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
14062 Fuzz testing: Parser14-table
14067 <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>
14068 <table style="__TOC__">
14074 # Known to produce bogus xml (extra </td>)
14076 Fuzz testing: Parser16
14096 Fuzz testing: Parser21
14099 ! irc://{{ftp://a" onmouseover="alert('hello world');"
14104 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
14114 Fuzz testing: Parser22
14116 http://===r:::https://b
14120 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
14128 # Known to produce bad XML for now
14130 Fuzz testing: Parser24
14137 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
14138 <br style="onmouseover='alert(document.cookie);' " />
14140 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
14145 <u class="|">}}}} >
14146 <br style="onmouseover='alert(document.cookie);'" />
14148 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
14157 # Note: the current result listed for this is not what the original one was,
14158 # but the original bug was JavaScript injection, which is fixed in any case.
14159 # It's not clear that the original result listed was any more correct than the
14160 # current one. Original result:
14163 # <li class="||">
14164 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
14166 Fuzz testing: Parser25 (bug 6055)
14172 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
14174 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
14179 Fuzz testing: URL adjacent extension (with space, clean)
14182 http://example.com <nowiki>junk</nowiki>
14184 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
14189 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
14192 http://example.com<nowiki>junk</nowiki>
14194 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
14199 Fuzz testing: URL adjacent extension (no space, dirty; pre)
14202 http://example.com<pre>junk</pre>
14204 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
14209 Fuzz testing: image with bogus manual thumbnail
14211 [[Image:foobar.jpg|thumbnail= ]]
14213 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
14216 <meta typeof="mw:Placeholder" data-parsoid='{"src":"[[Image:foobar.jpg|thumbnail= ]]","optList":[{"ck":"manualthumb","ak":"thumbnail= "}],"dsr":[0,32,null,null]}'/>
14220 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
14222 <pre dir=" "></pre>
14224 <pre dir=" "></pre>
14229 Parsing optional HTML elements (Bug 6171)
14234 <td> Some tabular data</td>
14235 <td> More tabular data ...
14236 <td> And yet som tabular data</td>
14242 <td> Some tabular data</td>
14243 <td> More tabular data ...
14244 </td><td> And yet som tabular data</td>
14251 Correct handling of <td>, <tr> (Bug 6171)
14256 <td> Some tabular data</td>
14257 <td> More tabular data ...</td>
14258 <td> And yet som tabular data</td>
14264 <td> Some tabular data</td>
14265 <td> More tabular data ...</td>
14266 <td> And yet som tabular data</td>
14274 Parsing crashing regression (fr:JavaScript)
14278 <p></body></x>
14283 Inline wiki vs wiki block nesting
14289 <p><b>Bold paragraph</b>
14290 </p><p>New wiki paragraph
14295 Inline HTML vs wiki block nesting
14303 <p><b>Bold paragraph</b>
14304 </p><p>New wiki paragraph
14308 # Original result was this:
14309 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
14311 # While that might be marginally more intuitive, maybe, the six-apostrophe
14312 # construct is clearly pathological and the result stated here (which is what
14313 # the parser actually does) is about as reasonable as anything.
14315 Mixing markup for italics and bold
14318 '''bold''''''bold''bolditalics'''''
14320 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
14328 Article for special page transclusion test
14332 Special page transclusion
14335 {{Special:Prefixindex/Xyzzyx}}
14337 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
14342 Special page transclusion twice (bug 5021)
14345 {{Special:Prefixindex/Xyzzyx}}
14346 {{Special:Prefixindex/Xyzzyx}}
14348 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
14349 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
14354 Transclusion of default MediaWiki message
14356 {{MediaWiki:Mainpage}}
14363 Transclusion of nonexistent MediaWiki message
14365 {{MediaWiki:Mainpagexxx}}
14367 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
14372 Transclusion of MediaWiki message with underscore
14374 {{MediaWiki:history_short}}
14381 Transclusion of MediaWiki message with space
14383 {{MediaWiki:history short}}
14390 Invalid header with following text
14400 Section extraction test (section 0)
14420 Section extraction test (section 1)
14442 Section extraction test (section 2)
14463 Section extraction test (section 3)
14483 Section extraction test (section 4)
14507 Section extraction test (section 5)
14527 Section extraction test (section 6)
14548 Section extraction test (section 7)
14568 Section extraction test (section 8)
14588 Section extraction test (section 9)
14609 Section extraction test (section 10)
14629 Section extraction test (nonexistent section 11)
14648 Section extraction test with bogus heading (section 1)
14653 ==bogus== not a legal section
14657 ==bogus== not a legal section
14661 Section extraction test with bogus heading (section 2)
14666 ==bogus== not a legal section
14673 Section extraction test with comment after heading (section 1)
14685 Section extraction test with comment after heading (section 2)
14697 Section extraction test with bogus <nowiki> heading (section 1)
14702 ==bogus== <nowiki>not a legal section</nowiki>
14706 ==bogus== <nowiki>not a legal section</nowiki>
14710 Section extraction test with bogus <nowiki> heading (section 2)
14715 ==bogus== <nowiki>not a legal section</nowiki>
14722 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
14723 # instead of respecting commented sections
14725 Section extraction prefixed by comment (section 1)
14736 Section extraction prefixed by comment (section 2)
14747 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
14748 # instead of respecting HTML-style headings
14750 Section extraction, mixed wiki and html (section 1)
14766 Section extraction, mixed wiki and html (section 2)
14782 # Formerly testing for bug 3342
14784 Section extraction, heading surrounded by <noinclude>
14788 <noinclude>==unmarked==</noinclude>
14794 # Test behavior of bug 19910
14796 Sectiion with all-equals
14801 The line above must have a trailing space
14804 But just in case it doesn't...
14808 But just in case it doesn't...
14812 Section replacement test (section 0)
14843 Section replacement test (section 1)
14872 Section replacement test (section 2)
14902 Section replacement test (section 3)
14933 Section replacement test (section 4)
14960 Section replacement test (section 5)
14991 Section replacement test (section 6)
15021 Section replacement test (section 7)
15052 Section replacement test (section 8)
15083 Section replacement test (section 9)
15112 Section replacement test (section 10)
15142 Section replacement test with initial whitespace (bug 13728)
15146 Preformatted initial line
15150 Preformatted initial line
15157 Section extraction, heading followed by pre with 20 spaces (bug 6398)
15169 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
15182 Section extraction, <pre> around bogus header (bug 10309)
15199 Section replacement, <pre> around bogus header (bug 10309)
15201 noxml replace=2,"xxx"
15222 Handling of 
 in URLs
15226 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
15229 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://
15231 a</a></li></ul></li></ul>
15235 Handling of %0A in URLs
15239 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
15242 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
15246 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
15248 5 quotes, code coverage +1 line
15255 <p><b><i></i></b></p>
15258 # same html as previous, but wikitext adjusted to match parsoid html2wt
15259 # note that wt2html and html2html will put the <i> before the <b>
15261 5 quotes, code coverage +1 line w/ nowiki (1)
15263 parsoid=wt2wt,html2wt
15265 '''''<nowiki/>'''''
15270 <p><b><i></i></b></p>
15273 # same as previous, just swapping the <i> and <b>
15275 5 quotes, code coverage +1 line w/ nowiki (2)
15277 '''''<nowiki/>'''''
15282 <p><i><b></b></i></p>
15286 Special:Search page linking.
15290 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
15297 title=[[Parser test]]
15302 * {{FULLPAGENAMEE}}
15304 * {{BASEPAGENAMEE}}
15308 * {{ROOTPAGENAMEE}}
15310 * {{TALKPAGENAMEE}}
15311 * {{SUBJECTPAGENAME}}
15312 * {{SUBJECTPAGENAMEE}}
15315 * {{NAMESPACENUMBER}}
15319 * {{SUBJECTSPACEE}}
15320 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
15322 <ul><li> Parser test</li>
15323 <li> Parser_test</li>
15324 <li> Parser test</li>
15325 <li> Parser_test</li>
15326 <li> Parser test</li>
15327 <li> Parser_test</li>
15328 <li> Parser test</li>
15329 <li> Parser_test</li>
15330 <li> Parser test</li>
15331 <li> Parser_test</li>
15332 <li> Talk:Parser test</li>
15333 <li> Talk:Parser_test</li>
15334 <li> Parser test</li>
15335 <li> Parser_test</li>
15343 <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>
15346 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
15356 image4 |300px| centre
15357 image5.svg| http://///////
15362 <ul class="gallery mw-gallery-traditional">
15363 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15364 <div class="thumb" style="height: 150px;">Image1.png</div>
15365 <div class="gallerytext">
15368 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15369 <div class="thumb" style="height: 150px;">Image2.gif</div>
15370 <div class="gallerytext">
15375 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15376 <div class="thumb" style="height: 150px;">Image3</div>
15377 <div class="gallerytext">
15380 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15381 <div class="thumb" style="height: 150px;">Image4</div>
15382 <div class="gallerytext">
15387 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15388 <div class="thumb" style="height: 150px;">Image5.svg</div>
15389 <div class="gallerytext">
15390 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
15394 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15395 <div class="thumb" style="height: 150px;">* image6</div>
15396 <div class="gallerytext">
15404 Gallery (with options)
15406 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
15407 File:Nonexistant.jpg|caption
15408 File:Nonexistant.jpg
15409 image:foobar.jpg|some '''caption''' [[Main Page]]
15411 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
15414 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
15415 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
15416 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15417 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
15418 <div class="gallerytext">
15423 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15424 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
15425 <div class="gallerytext">
15428 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15429 <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>
15430 <div class="gallerytext">
15431 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
15435 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15436 <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>
15437 <div class="gallerytext">
15440 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
15441 <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>
15442 <div class="gallerytext">
15452 Gallery with link that has fragment
15455 image:foobar.jpg|link=Main_Page
15456 image:foobar.jpg|link=Main_Page#section
15457 image:foobar.jpg|link=Main Page#section|caption
15460 <ul class="gallery mw-gallery-traditional">
15461 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15462 <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>
15463 <div class="gallerytext">
15466 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15467 <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>
15468 <div class="gallerytext">
15471 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15472 <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>
15473 <div class="gallerytext">
15483 Gallery with wikitext inside caption
15486 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
15487 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
15490 <ul class="gallery mw-gallery-traditional">
15491 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15492 <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>
15493 <div class="gallerytext">
15494 <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>
15498 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15499 <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>
15500 <div class="gallerytext">
15501 <p>This is a test template
15510 gallery (with showfilename option)
15512 <gallery showfilename>
15513 File:Nonexistant.jpg|caption
15514 File:Nonexistant.jpg
15515 image:foobar.jpg|some '''caption''' [[Main Page]]
15519 <ul class="gallery mw-gallery-traditional">
15520 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15521 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15522 <div class="gallerytext">
15523 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
15528 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15529 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15530 <div class="gallerytext">
15531 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
15535 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15536 <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>
15537 <div class="gallerytext">
15538 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
15539 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
15543 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15544 <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>
15545 <div class="gallerytext">
15546 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
15555 Gallery (with namespace-less filenames)
15558 File:Nonexistant.jpg
15564 <ul class="gallery mw-gallery-traditional">
15565 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15566 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15567 <div class="gallerytext">
15570 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15571 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
15572 <div class="gallerytext">
15575 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15576 <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>
15577 <div class="gallerytext">
15580 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15581 <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>
15582 <div class="gallerytext">
15590 HTML Hex character encoding (spells the word "JavaScript")
15592 parsoid=wt2html,wt2wt,html2html
15594 JavaScript
15596 <p>JavaScript
15599 <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>
15603 HTML Hex character encoding bogus encoding (bug 26437 regression check)
15607 <p>&#xsee;&#XSEE;
15610 <p>&#xsee;&#XSEE;</p>
15614 HTML Hex character encoding mixed case
15616 parsoid=wt2html,wt2wt,html2html
15623 <p><span typeof="mw:Entity">î</span><span typeof="mw:Entity">î</span></p>
15627 __FORCETOC__ override
15639 ISBN 978-0-1234-56 789
15641 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
15646 ISBN followed by 5 spaces
15657 ISBN ISBN 1234567890
15659 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
15668 <p><a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-X</a>
15673 ISBN with empty prefix (parsoid test)
15677 <p><a href="Special:BookSources/1234567890" rel="mw:ExtLink">ISBN 1234567890</a></p>
15681 Bug 22905: <abbr> followed by ISBN followed by </a>
15683 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
15685 <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>
15694 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
15699 Double RFC with a wiki link
15703 <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>
15712 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
15717 Centre-aligned image
15719 [[Image:foobar.jpg|centre]]
15721 <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>
15728 [[Image:foobar.jpg|none]]
15730 <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>
15735 Width + Height sized image (using px) (height is ignored)
15737 [[Image:foobar.jpg|640x480px]]
15739 <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>
15744 Width-sized image (using px, no following whitespace)
15746 [[Image:foobar.jpg|640px]]
15748 <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>
15753 Width-sized image (using px, with following whitespace - test regression from r39467)
15755 [[Image:foobar.jpg|640px ]]
15757 <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>
15762 Width-sized image (using px, with preceding whitespace - test regression from r39467)
15764 [[Image:foobar.jpg| 640px]]
15766 <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>
15771 Image with page parameter
15775 [[File:LoremIpsum.djvu|page=2]]
15777 <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>
15782 Another italics / bold test
15790 # Note the results may be incorrect, as parserTest output included this:
15791 # XML error: Mismatched tag at byte 6120:
15792 # ...<dd> </dt></dl> </dd...
15823 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
15825 Images with the "|" character in the comment
15827 [[File:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
15829 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&param2=%7Cx">external</a> URL</div></div></div>
15832 <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>
15836 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
15838 <html><script>alert(1);</script></html>
15840 <p><html><script>alert(1);</script></html>
15845 HTML with raw HTML ($wgRawHtml==true)
15849 <html><script>alert(1);</script></html>
15851 <p><script>alert(1);</script>
15856 Parents of subpages, one level up
15858 subpage title=[[Subpage test/L1/L2/L3]]
15862 <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>
15868 Parents of subpages, one level up, not named
15870 subpage title=[[Subpage test/L1/L2/L3]]
15874 <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>
15881 Parents of subpages, two levels up
15883 subpage title=[[Subpage test/L1/L2/L3]]
15889 <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
15890 </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>
15895 Parents of subpages, two levels up, without trailing slash or name.
15897 subpage title=[[Subpage test/L1/L2/L3]]
15906 Parents of subpages, two levels up, with lots of extra trailing slashes.
15908 subpage title=[[Subpage test/L1/L2/L3]]
15912 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
15917 Subpage test/L1/L2/L3Sibling
15923 Transclusion of a sibling page (one level up)
15925 subpage title=[[Subpage test/L1/L2/L3]]
15934 Transclusion of a child page
15936 subpage title=[[Subpage test/L1/L2]]
15945 Non-transclusion because of too many up levels
15947 subpage title=[[Subpage test/L1/L2/L3]]
15949 {{../../../../More than parent}}
15951 <p>{{../../../../More than parent}}
15956 Definition list code coverage
15962 <dl><dt> title  </dt>
15964 <dt> title </dt>
15972 Don't fall for the self-closing div
15974 <div>hello world</div/>
15976 <div>hello world</div>
15985 <p>[[:Template:Msg]]
15994 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
15998 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
16000 Always escape literal '>' in output, not just after '<'
16014 <p>This is a test template
16015 This is a test template
16027 Inclusion of !userCanEdit() content
16031 <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>
16037 Out-of-order TOC heading levels
16046 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
16048 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
16050 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
16051 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
16054 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
16056 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
16057 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
16063 <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>
16064 <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>
16065 <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>
16066 <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>
16067 <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>
16068 <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>
16074 ISBN with a dummy number
16084 ISBN with space-delimited number
16088 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
16094 ISBN with multiple spaces, no number
16113 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
16114 </p><p>ISBN 12345678901
16120 ISBN with trailing year (bug 8110)
16122 ISBN 1-234-56789-0 - 2006
16124 ISBN 1 234 56789 0 - 2006
16126 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
16127 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
16135 {{anchorencode:foo bar©#%n}}
16137 <p>foo_bar.C2.A9.23.25n
16142 anchorencode trims spaces
16144 {{anchorencode: __pretty__please__}}
16151 anchorencode deals with links
16153 {{anchorencode: [[hello|world]] [[hi]]}}
16160 anchorencode deals with templates
16162 {{anchorencode: {{Foo}} }}
16169 anchorencode encodes like the TOC generator: (bug 18431)
16171 === _ +:.3A%3A&&]] ===
16172 {{anchorencode: _ +:.3A%3A&&]] }}
16175 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
16176 <p>.2B:.3A.253A.26.26.5D.5D
16181 Bug 6200: blockquotes and paragraph formatting
16202 Bug 8293: Use of center tag ruins paragraph formatting
16223 Parsing of overlapping (improperly nested) inline html tags
16225 <span><s>x</span></s>
16227 <p><span><s>x</span></s></span>
16230 <p><span><s>x</s></span>
16235 ### Language variants related tests
16238 Self-link in language variants
16240 title=[[Dunav]] language=sr
16242 Both [[Dunav]] and [[Дунав]] are names for this river.
16244 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
16255 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
16257 title=[[Duna]] language=sr
16259 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
16261 <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.
16266 Link to a section of a variant of this title shouldn't be parsed as self-link
16268 title=[[Duna]] language=sr
16270 [[Dуна]] is a self-link while [[Dunа#Foo]] and [[Dуна#Foo]] are not self-links.
16272 <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.
16277 Link to pages in language variants
16281 Main Page can be written as [[Маин Паге]]
16283 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
16289 Multiple links to pages in language variants
16293 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
16295 <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>.
16301 Simple template in language variants
16307 <p>This is a test template
16313 Template with explicit namespace in language variants
16319 <p>This is a test template
16325 Basic test for template parameter in language variants
16329 {{парамтест|param=foo}}
16331 <p>This is a test template with parameter foo
16337 Simple category in language variants
16341 [[Category:МедиаWики Усер'с Гуиде]]
16343 <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>
16360 Don't convert blue categorylinks to another variant (bug 33210)
16364 [[A]][[Category:分类]]
16366 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
16371 Stripping -{}- tags (language variants)
16375 Latin proverb: -{Ne nuntium necare}-
16377 <p>Latin proverb: Ne nuntium necare
16383 Prevent conversion with -{}- tags (language variants)
16385 language=sr variant=sr-ec
16387 Latinski: -{Ne nuntium necare}-
16389 <p>Латински: Ne nuntium necare
16395 Prevent conversion of text with -{}- tags (language variants)
16397 language=sr variant=sr-ec
16399 Latinski: -{Ne nuntium necare}-
16401 <p>Латински: Ne nuntium necare
16407 Prevent conversion of links with -{}- tags (language variants)
16409 language=sr variant=sr-ec
16413 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
16419 -{}- tags within headlines (within html for parserConvert())
16421 language=sr variant=sr-ec
16425 <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>
16431 Explicit definition of language variant alternatives
16433 language=zh variant=zh-tw
16435 -{zh:China;zh-tw:Taiwan}-, not China
16437 <p>Taiwan, not China
16443 Conversion around HTML tags
16445 language=sr variant=sr-ec
16447 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
16448 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
16451 <span title="ЛаCтин">ски</span>
16457 Explicit session-wise language variant mapping (A flag and - flag)
16459 language=zh variant=zh-tw
16461 Taiwan is not China.
16462 But -{A|zh:China;zh-tw:Taiwan}- is China,
16463 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
16464 and -{China}- is China.
16466 <p>Taiwan is not China.
16467 But Taiwan is Taiwan,
16468 (This should be stripped!)
16469 and China is China.
16474 Explicit session-wise language variant mapping (H flag for hide)
16476 language=zh variant=zh-tw
16478 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
16481 <p>(This should be stripped!)
16487 Adding explicit conversion rule for title (T flag)
16489 language=zh variant=zh-tw showtitle
16491 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
16494 <p>Should be stripped!
16499 Testing that changing the language variant here in the tests actually works
16501 language=zh variant=zh showtitle
16503 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
16506 <p>Should be stripped!
16511 Recursive conversion of alt and title attrs shouldn't clear converter state
16513 language=zh variant=zh-cn showtitle
16515 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
16516 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
16520 Should be stripped<span title="Exclamation">!</span>
16525 Bug 24072: more test on conversion rule for title
16527 language=zh variant=zh-tw showtitle
16529 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
16530 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
16533 <p>This should be stripped!
16534 This won't take interferes with the title rule.
16539 Partly disable title conversion if variant == main language code
16541 language=zh variant=zh title=[[ZH]] showtitle
16543 -{T|zh-cn:CN;zh-tw:TW}-
16551 Partly disable title conversion if variant == main language code, more
16553 language=zh variant=zh title=[[ZH]] showtitle
16563 Raw output of variant escape tags (R flag)
16565 language=zh variant=zh-tw
16567 Raw: -{R|zh:China;zh-tw:Taiwan}-
16569 <p>Raw: zh:China;zh-tw:Taiwan
16574 Nested using of manual convert syntax
16576 language=zh variant=zh-hk
16578 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
16580 <p>Nested: Hello Hong Kong!
16585 Proper conversion of text in external links
16587 language=sr variant=sr-ec
16589 http://www.google.com
16590 gopher://www.google.com
16591 [http://www.google.com http://www.google.com]
16592 [gopher://www.google.com gopher://www.google.com]
16593 [https://www.google.com irc://www.google.com]
16594 [ftp://www.google.com www.google.com/ftp://dir]
16595 [//www.google.com www.google.com]
16597 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
16598 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
16599 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
16600 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
16601 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
16602 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
16603 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
16608 Do not convert roman numbers to language variants
16610 language=sr variant=sr-ec
16614 <p>Фридрих IV је цар.
16619 Unclosed language converter markup "-{"
16630 Don't convert raw rule "-{R|=>}-" to "=>"
16641 Don't break link parsing if language converter markup is in the caption.
16643 language=sr variant=sr-ec
16645 [[Main Page|-{R|main page}-]]
16647 <p><a href="/wiki/Main_Page" title="Маин Паге">main page</a>
16651 # This test is currently broken in the PHP parser (bug 52661)
16653 Don't break image parsing if language converter markup is in the caption.
16658 [[File:Foobar.jpg|-{R|caption}-]]
16660 <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>
16664 # This test is currently broken in the PHP parser (bug 52661)
16666 Don't break list handling if language converter markup is in the item.
16668 language=zh variant=zh-cn
16671 ;-{zh-cn:AAA;zh-tw:BBB}-
16678 # This test is currently broken in the PHP parser (bug 52661)
16680 Don't break table handling if language converter markup is in the cell.
16682 language=sr variant=sr-ec
16699 Bug 529: Uncovered bullet
16708 # Plain MediaWiki does not remove empty lists, but tidy actually does.
16709 # Templates in Wikipedia rely on this behavior, as tidy has always been
16710 # enabled there. These tests are normally run *without* tidy, so specify the
16711 # full output here.
16712 # To test realistic parsing behavior, apply a tidy-like transformation to both
16713 # the expected output and your parser's output.
16715 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
16717 ******* Foo {{bullet}}
16719 <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>
16725 Bug 529: Uncovered table already at line-start
16748 Bug 529: Uncovered bullet in parser function result
16750 * Foo {{lc:{{bullet}} }}
16758 Bug 5678: Double-parsed template argument
16760 {{lc:{{{1}}}|hello}}
16767 Bug 5678: Double-parsed template invocation
16769 {{lc:{{paramtest {{!}} param = hello }} }}
16771 <p>{{paramtest | param = hello }}
16776 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
16779 title=[[Main Page]]
16781 {{PRVNÍVELKÉ:ěščř}}
16782 {{prvnívelké:ěščř}}
16802 Morwen/13: Unclosed link followed by heading
16809 <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>
16814 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
16821 <h1><span class="mw-headline" id="heading">heading</span></h1>
16826 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
16833 <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>
16848 Paragraphs inside divs (no extra line breaks)
16860 Paragraphs inside divs (extra line break on open)
16875 Paragraphs inside divs (extra line break on close)
16890 Paragraphs inside divs (extra line break on open and close)
16907 Nesting tags, paragraphs on lines which begin with <div>
16911 <div></div><strong>A
16920 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
16922 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
16924 <blockquote>Line one
16926 Line two</blockquote>
16928 <blockquote>Line one
16929 Line two</blockquote>
16934 Bug 6200: paragraphs inside blockquotes (extra line break on open)
16939 Line two</blockquote>
16944 Line two</blockquote>
16949 Bug 6200: paragraphs inside blockquotes (extra line break on close)
16951 <blockquote>Line one
16956 <blockquote>Line one
16964 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
16981 Paragraphs inside blockquotes/divs (no extra line breaks)
16983 <blockquote><div>Line one
16985 Line two</div></blockquote>
16987 <blockquote><div>Line one
16988 Line two</div></blockquote>
16993 Paragraphs inside blockquotes/divs (extra line break on open)
16998 Line two</div></blockquote>
17003 Line two</div></blockquote>
17008 Paragraphs inside blockquotes/divs (extra line break on close)
17010 <blockquote><div>Line one
17013 </div></blockquote>
17015 <blockquote><div>Line one
17018 </div></blockquote>
17023 Paragraphs inside blockquotes/divs (extra line break on open and close)
17029 </div></blockquote>
17035 </div></blockquote>
17040 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
17042 wgLinkHolderBatchSize=0
17048 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
17049 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
17050 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
17055 Free external link invading image caption
17057 [[Image:Foobar.jpg|thumb|http://x|hello]]
17059 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>hello</div></div></div>
17064 Bug 15196: localised external link numbers
17068 [http://en.wikipedia.org/]
17070 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
17073 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/"></a></p>
17077 Multibyte character in padleft
17079 {{padleft:-Hello|7|Æ}}
17086 Multibyte character in padright
17088 {{padright:Hello-|7|Æ}}
17095 formatdate parser function
17097 {{#formatdate:2009-03-24}}
17099 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
17104 formatdate parser function, with default format
17106 {{#formatdate:2009-03-24|mdy}}
17108 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
17113 Spacing of numbers in formatted dates
17115 {{#formatdate:January 15}}
17117 <p><span class="mw-formatted-date" title="01-15">January 15</span>
17122 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
17124 language=nl title=[[MediaWiki:Common.css]]
17126 {{#formatdate:2009-03-24|dmy}}
17128 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
17141 Edit comment with link
17145 I like the [[Main Page]] a lot
17147 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
17151 Edit comment with link and link text
17155 I like the [[Main Page|best pages]] a lot
17157 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
17161 Edit comment with link and link text with suffix
17165 I like the [[Main Page|best page]]s a lot
17167 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
17171 Edit comment with section link (non-local, eg in history list)
17173 comment title=[[Main Page]]
17175 /* External links */ removed bogus entries
17177 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
17181 Edit comment with section link and text before it (non-local, eg in history list)
17183 comment title=[[Main Page]]
17185 pre-comment text /* External links */ removed bogus entries
17187 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>
17191 Edit comment with section link (local, eg in diff view)
17193 comment local title=[[Main Page]]
17195 /* External links */ removed bogus entries
17197 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
17201 Edit comment with subpage link (bug 14080)
17205 title=[[Subpage test]]
17207 Poked at a [[/subpage]] here...
17209 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
17213 Edit comment with subpage link and link text (bug 14080)
17217 title=[[Subpage test]]
17219 Poked at a [[/subpage|neat little page]] here...
17221 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
17225 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
17228 title=[[Subpage test]]
17230 Poked at a [[/subpage]] here...
17232 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
17236 Edit comment with bare anchor link (local, as on diff)
17240 title=[[Main Page]]
17244 <a href="#section">#section</a>
17248 Edit comment with bare anchor link (non-local, as on history)
17251 title=[[Main Page]]
17255 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
17259 Anchor starting with underscore
17263 <p><a href="#_ref">One</a>
17268 Id starting with underscore
17270 <div id="_ref"></div>
17272 <div id="_ref"></div>
17277 Space normalisation on autocomment (bug 22784)
17280 title=[[Main Page]]
17282 /* __hello__world__ */
17284 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
17288 percent-encoding and + signs in comments (Bug 26410)
17292 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
17294 <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>
17298 Bad images - basic functionality
17307 Bad images - bug 16039: text after bad image disappears
17321 Verify that displaytitle works (bug #22501) no displaytitle
17325 wgAllowDisplayTitle=true
17326 wgRestrictDisplayTitle=false
17328 this is not the the title
17331 <p>this is not the the title
17336 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
17341 wgAllowDisplayTitle=true
17342 wgRestrictDisplayTitle=false
17344 this is not the the title
17345 {{DISPLAYTITLE:whatever}}
17348 <p>this is not the the title
17353 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
17358 wgAllowDisplayTitle=true
17359 wgRestrictDisplayTitle=true
17361 this is not the the title
17362 {{DISPLAYTITLE:whatever}}
17365 <p>this is not the the title
17370 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
17375 wgAllowDisplayTitle=true
17376 wgRestrictDisplayTitle=true
17378 this is not the the title
17379 {{DISPLAYTITLE:screen}}
17382 <p>this is not the the title
17387 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
17392 wgAllowDisplayTitle=false
17394 this is not the the title
17395 {{DISPLAYTITLE:screen}}
17398 <p>this is not the the title
17399 <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>
17404 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
17409 wgAllowDisplayTitle=false
17411 this is not the the title
17414 <p>this is not the the title
17419 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
17424 wgAllowDisplayTitle=true
17425 wgRestrictDisplayTitle=true
17427 this is not the the title
17428 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
17430 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
17431 <p>this is not the the title
17436 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
17441 wgAllowDisplayTitle=true
17442 wgRestrictDisplayTitle=true
17444 this is not the the title
17445 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
17447 <span style="color: red;">s</span>creen
17448 <p>this is not the the title
17453 preload: check <noinclude> and <includeonly>
17457 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
17463 preload: check <onlyinclude>
17467 Goodbye <onlyinclude>Hello world</onlyinclude>
17473 preload: can pass tags through if we want to
17477 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
17479 <includeonly>Hello world</includeonly>
17483 preload: check that it doesn't try to do tricks
17487 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
17489 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
17493 Play a bit with r67090 and bug 3158
17497 <div style="width:50% !important"> </div>
17498 <div style="width:50% !important"> </div>
17499 <div style="width:50% !important"> </div>
17500 <div style="border : solid;"> </div>
17502 <div style="width:50% !important"> </div>
17503 <div style="width:50% !important"> </div>
17504 <div style="width:50% !important"> </div>
17505 <div style="border : solid;"> </div>
17510 HTML5 data attributes
17512 <span data-foo="bar">Baz</span>
17513 <p data-abc-def_hij="">Quuz</p>
17515 <p><span data-foo="bar">Baz</span>
17517 <p data-abc-def_hij="">Quuz</p>
17522 percent-encoding and + signs in internal links (Bug 26410)
17524 [[User:+%]] [[Page+title%]]
17525 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
17526 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
17527 [[%33%45]] [[%33%45+]]
17529 <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>
17530 <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>
17531 <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>
17532 <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>
17537 Special characters in embedded file links (bug 27679)
17539 [[File:Contains & ampersand.jpg]]
17540 [[File:Does not exist.jpg|Title with & ampersand]]
17542 <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>
17543 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
17549 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
17551 Text's been normalized?
17553 <p>Text's been normalized?
17558 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
17560 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
17562 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
17567 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
17569 [http://www.example.org/ ideograms]
17571 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
17576 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
17578 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
17580 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
17604 Bug 31098 Template which includes system messages which includes the template
17608 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
17609 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
17614 Bug31490 Turkish: ucfirst 'blah'
17625 Bug31490 Turkish: ucfirst 'ix'
17636 Bug31490 Turkish: lcfirst 'BLAH'
17647 Bug31490 Turkish: ucfırst (with a dotless i)
17653 <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>
17658 Bug31490 ucfırst (with a dotless i) with English language
17664 <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>
17669 Bug 26375: TOC with italics
17671 title=[[Main Page]]
17674 == ''Lost'' episodes ==
17676 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17678 <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>
17682 <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>
17687 Bug 26375: TOC with bold
17689 title=[[Main Page]]
17692 == '''should be bold''' then normal text ==
17694 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17696 <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>
17700 <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>
17705 Bug 33845: Headings become cursive in TOC when they contain an image
17707 title=[[Main Page]]
17710 == Image [[Image:foobar.jpg]] ==
17712 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17714 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
17718 <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>
17723 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
17725 title=[[Main Page]]
17728 == <blockquote>Quote</blockquote> ==
17730 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17732 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
17736 <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>
17741 Unclosed tags in TOC
17743 title=[[Main Page]]
17747 <small>Hanc marginis exiguitas non caperet.</small>
17750 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17752 <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>
17756 <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>
17757 <p><small>Hanc marginis exiguitas non caperet.</small>
17763 Multiple tags in TOC
17766 == <i>Foo</i> <b>Bar</b> ==
17768 == <i>Foo</i> <blockquote>Bar</blockquote> ==
17770 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17772 <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>
17773 <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>
17777 <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>
17778 <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>
17783 Tags with parameters in TOC
17786 == <sup class="in-h2">Hello</sup> ==
17788 == <sup class="a > b">Evilbye</sup> ==
17790 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17792 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
17793 <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>
17797 <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>
17798 <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>
17803 span tags with directionality in TOC
17806 == <span dir="ltr">C++</span> ==
17808 == <span dir="rtl">זבנג!</span> ==
17810 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
17812 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
17814 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
17816 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17818 <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>
17819 <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>
17820 <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>
17821 <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>
17822 <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>
17826 <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>
17827 <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>
17828 <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>
17829 <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>
17830 <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>
17837 == {{int:headline_sample}} ==
17841 Bug 32057: Title needed when expanding <h> nodes.
17843 title=[[Main Page]]
17847 <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>
17852 Strip marker in urlencode
17854 {{urlencode:x<nowiki/>y}}
17855 {{urlencode:x<nowiki/>y|wiki}}
17856 {{urlencode:x<nowiki/>y|path}}
17883 Strip marker in formatNum
17885 {{formatnum:1<nowiki/>2}}
17886 {{formatnum:1<nowiki/>2|R}}
17894 Check noCommafy in formatNum
17898 {{formatnum:123456.78}}
17899 {{formatnum:123456.78|NOSEP}}
17907 Wrong option for formatNum (bug 56199)
17909 {{formatnum:1,234.56|Random}}
17910 {{formatnum:1,234.56|EVERYTHING}}
17911 {{formatnum:1234.56|any argument that has the string 'NOSEP'}}
17920 Strip marker in grammar
17924 {{grammar:elative|foo<nowiki/>bar}}
17931 Strip marker in padleft
17933 {{padleft:|2|x<nowiki/>y}}
17940 Strip marker in padright
17942 {{padright:|2|x<nowiki/>y}}
17949 Strip marker in anchorencode
17951 {{anchorencode:x<nowiki/>y}}
17958 nowiki inside link inside heading (bug 18295)
17960 ==[[foo|x<nowiki>y</nowiki>z]]==
17962 <h2><span class="mw-headline" id="xyz"><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">xyz</a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: xyz">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17967 new support for bdi element (bug 31817)
17969 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
17971 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
17976 Ignore pipe between table row attributes
17980 |- id=foo | style='color: red'
17988 <tr id="foo" style="color: red">
17995 Gallery override link with WikiLink (bug 34852)
17998 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
18001 <ul class="gallery mw-gallery-traditional">
18002 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
18003 <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>
18004 <div class="gallerytext">
18014 Gallery override link with absolute external link (bug 34852)
18017 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
18020 <ul class="gallery mw-gallery-traditional">
18021 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
18022 <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>
18023 <div class="gallerytext">
18033 Gallery override link with malicious javascript (bug 34852)
18036 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
18039 <ul class="gallery mw-gallery-traditional">
18040 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
18041 <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>
18042 <div class="gallerytext">
18052 Gallery with invalid title as link (bug 43964)
18055 File:foobar.jpg|link=<
18058 <ul class="gallery mw-gallery-traditional">
18059 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
18060 <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>
18061 <div class="gallerytext">
18069 Language parser function
18078 Padleft and padright as substr
18080 {{padleft:|3|abcde}}
18081 {{padright:|3|abcde}}
18089 Special parser function
18091 {{#special:RandomPage}}
18092 {{#special:BaDtItLe}}
18093 {{#special:Foobar}}
18102 Bug 34939 - Case insensitive link parsing ([HttP://])
18104 [HttP://MediaWiki.Org/]
18106 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
18109 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/"></a></p>
18113 Bug 34939 - Case insensitive link parsing ([HttP:// title])
18115 [HttP://MediaWiki.Org/ MediaWiki]
18117 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
18122 Bug 34939 - Case insensitive link parsing (HttP://)
18124 HttP://MediaWiki.Org/
18126 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
18129 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a></p>
18147 <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>
18148 <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>
18149 <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>
18150 <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>
18151 <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>
18157 ### Parsoid-specific tests
18158 ### Parsoid-PHP parser incompatibilities
18161 1. SOL-sensitive wikitext tokens as template-args
18163 parsoid=wt2html,wt2wt
18169 <span about="#mwt1" typeof="mw:Transclusion">
18170 </span><ul about="#mwt1"><li>a</li>
18172 <span about="#mwt2" typeof="mw:Transclusion">
18173 </span><ol about="#mwt2"><li>a</li>
18175 <span about="#mwt3" typeof="mw:Transclusion">
18176 </span><dl about="#mwt3"><dd>a</dd>
18180 #### -----------------------------------------------------------------
18181 #### Parsoid-specific functionality tests
18182 #### -----------------------------------------------------------------
18184 # Bug 63642: Formatting elt fixup is cleaned up.
18185 # We know wt2wt will fail, but we expect selser to pass.
18186 # Due to the nature of our testing, wt2wt and selser tests will enter the
18187 # blacklist and we'll catch selser regressions based on changes to the
18188 # blacklist entries for selser tests.
18190 Bad treebuilder fixup of formatting elt is cleaned up
18192 parsoid=wt2html,wt2wt
18197 [[Image:Foobar.jpg|right|Test]]
18203 <p><small></small></p>
18204 <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><small>Test</small></figcaption></figure>
18209 #### ----------------------------------------------------------------
18210 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
18211 #### tags. Parsoid's output for these tags differs from that of the
18213 #### ----------------------------------------------------------------
18216 Ref: 1. ref-location should be replaced with an index span
18221 B <ref name="x">foo</ref>
18224 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
18225 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-2">[2]</a></span>
18226 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"y"}}' id="cite_ref-y-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-y-3">[3]</a></span></p>
18230 Ref: 2. ref-tags with identical names should all get the same index
18234 A <ref name="x">foo</ref>
18237 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
18238 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
18242 Ref: 3. spaces in ref-names should be ignored
18246 A <ref name="x">foo</ref>
18247 B <ref name=" x " />
18250 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
18251 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
18252 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-2" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
18256 Ref: 4. 'constructor' should be accepted as a valid ref-name
18257 (NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
18261 A <ref name="constructor">foo</ref>
18263 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"constructor"}}' id="cite_ref-constructor-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-constructor-1">[1]</a></span></p>
18267 Ref: 5. body should accept generic wikitext
18272 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
18277 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"This is a <b data-parsoid='{\"dsr\":[19,40,3,3]}'><a rel=\"mw:WikiLink\" href=\"./Bolded_link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Bolded_link\"},\"sa\":{\"href\":\"bolded link\"},\"dsr\":[22,37,2,2]}'>bolded link</a></b> and this is a <span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"transclusion\"}},\"i\":0}}]}' data-parsoid='{\"pi\":[[{\"k\":\"1\",\"spc\":[\"\",\"\",\"\",\"\"]}]],\"dsr\":[55,76,null,null]}'>transclusion</span>\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18279 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
18280 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> This is a <b><a rel="mw:WikiLink" href="./Bolded_link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
18286 Ref: 6. indent-pres should not be output in ref-body
18298 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n bar\n baz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18300 <ol class="references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{}}'>
18301 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
18309 Ref: 7. No p-wrapping in ref-body
18328 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n\nbar\n\n\nbaz\n\n\n\nbooz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18330 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
18331 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
18346 Ref: 8. transclusion wikitext has lower precedence
18350 A <ref> foo {{echo|</ref> B C}}
18354 <p>A <span class="reference" data-mw="{"name":"ref","body":{"html":"foo <span typeof=\"mw:Nowiki\" data-parsoid='{\"src\":\"{{\",\"dsr\":[12,14,0,0]}'>{{</span>echo|"},"attrs":{}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C<span typeof="mw:Nowiki">}}</span></p>
18355 <ol class="references" typeof="mw:Extension/references" data-mw="{"name":"references","attrs":{}}">
18356 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <span typeof="mw:Nowiki">{{</span>echo|</li>
18361 Ref: 9. unclosed comments should not leak out of ref-body
18365 A <ref> foo <!--</ref> B C
18368 <p>A <span class="reference" data-mw='{"name":"ref","body":{"html":"foo <!---->"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C</p>
18369 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
18370 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo </li>
18375 Ref: 10. Unclosed HTML tags should not leak out of ref-body
18379 A <ref> <b> foo </ref> B C
18383 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"<b data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[8,16,3,0]}'> foo </b>"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref> <b> foo </ref>"}'><a href="#cite_note-1">[1]</a></span> B C</p>
18386 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'>
18387 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> <b data-parsoid='{"stx":"html","autoInsertedEnd":true}'> foo </b></li>
18392 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
18399 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo</ref>"}'><a href="#cite_note-1">[1]</a></span> B
18400 C <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bar</ref>"}'><a href="#cite_note-2">[2]</a></span> D</p>
18404 Ref: 12. ref-tags act as trailing newline migration barrier
18408 <!--the newline at the end of this line moves out of the p-tag-->a
18410 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
18415 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
18418 <p>b<!--the newline at the end of this line stays inside the p-tag--> <span about="#mwt1" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
18419 <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span></p>
18426 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
18434 <p><span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> A
18435 <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"bar\n"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span> B</p>
18439 Ref: 14. A nested ref-tag should be emitted as plain text
18443 <ref>foo <ref>bar</ref> baz</ref>
18447 <p><span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo &lt;ref>bar&lt;/ref> baz"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo <ref>bar</ref> baz</ref>"}'><a href="#cite_note-1">[1]</a></span></p>
18449 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'>
18450 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <ref>bar</ref> baz</li>
18455 Ref: 15. ref-tags with identical names should get identical indexes
18459 A1 <ref name="a">foo</ref> A2 <ref name="a" />
18460 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
18464 <p>A1 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span> A2 <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span>
18465 B1 <span about="#mwt7" class="reference" data-mw='{"name":"ref","attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span> B2 <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span></p>
18467 <ol about="#mwt10" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy">↑ <a href="#cite_ref-a-1-0">1.0</a> <a href="#cite_ref-a-1-1">1.1</a></span> foo</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy">↑ <a href="#cite_ref-b-2-0">2.0</a> <a href="#cite_ref-b-2-1">2.1</a></span> bar</li>
18471 ## We don't bother wt2wt-ing non-standard whitespace
18473 Ref: 16. Tokenizer should accept non-standard whitespace in <ref> and </ref> tags
18481 <p>A <span class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18483 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
18484 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
18488 References: 1. references tag without any refs should be handled properly
18494 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'></ol>
18498 References: 2. references tag with group only outputs references from that group
18502 A <ref group="a">foo</ref>
18503 B <ref group="b">bar</ref>
18505 <references group="a" />
18507 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
18508 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"group":"b"}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[b 1]</a></span></p>
18510 <ol about="#mwt6" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li>
18515 References: 3. ref list should be cleared after processing references
18527 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
18529 <ol about="#mwt4" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li>
18532 <p>B <span about="#mwt6" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[1]</a></span></p>
18534 <ol about="#mwt8" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> bar</li>
18539 References: 4. only referenced group should be cleared after processing references
18543 A <ref group="a">afoo</ref>
18546 <references group="a" />
18552 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"afoo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
18553 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bfoo"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bfoo</ref>"}'><a href="#cite_note-2">[1]</a></span></p>
18555 <ol about="#mwt6" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> afoo</li>
18558 <p>C <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"cfoo"},"attrs":{}}' id="cite_ref-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-3">[2]</a></span></p>
18560 <ol about="#mwt10" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> bfoo</li><li about="#cite_note-3" id="cite_note-3"><span rel="mw:referencedBy"><a href="#cite_ref-3-0">↑</a></span> cfoo</li>
18565 References: 5. ref tags in references should be processed while ignoring all other content
18570 B <ref name="b">bar</ref>
18573 <ref name="a">foo</ref>
18574 This should just get lost.
18577 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"a\" />"}'><a href="#cite_note-a-1">[1]</a></span>
18578 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"b\">bar</ref>"}'><a href="#cite_note-b-2">[2]</a></span></p>
18581 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-parsoid='{"src":"<references>\n<ref name=\"a\">foo</ref>\nThis should just get lost.\n</references>"}' data-mw='{"name":"references","body":{"extsrc":"<ref name=\"a\">foo</ref>\nThis should just get lost.","html":"\n<span about=\"#mwt8\" class=\"reference\" data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"a\"}}' rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-a-1\">[1]</a></span>\n"},"attrs":{}}'>
18582 <li about="#cite_note-a-1" id="cite_note-a-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-a-1-0">↑</a></span> foo</li>
18583 <li about="#cite_note-b-2" id="cite_note-b-2" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> bar</li>
18588 References: 6. <references /> from a transclusion
18592 <ref>Foo</ref> {{echo|<references />}}
18594 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"Foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> <ol class="references" typeof="mw:Extension/references mw:Transclusion" about="#mwt4" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references />"}},"i":0}}]}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> Foo</li></ol>
18598 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
18602 A <ref>foo bar for a</ref>
18603 B <ref group="X" name="b" />
18607 <references group="X">
18608 <ref name="b">foo</ref>
18611 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo bar for a"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo bar for a</ref>"}'><a href="#cite_note-1" data-parsoid="{}">[1]</a></span>
18612 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref group=\"X\" name=\"b\" />"}'><a href="#cite_note-b-2" data-parsoid="{}">[X 1]</a></span></p>
18614 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-1-0" data-parsoid="{}">↑</a></span> foo bar for a</li></ol>
18616 <ol class="references" typeof="mw:Extension/references" about="#mwt8" data-parsoid='{"src":"<references group=\"X\">\n<ref name=\"b\">foo</ref>\n</references>","group":"X"}' data-mw='{"name":"references","body":{"extsrc":"<ref name=\"b\">foo</ref>","html":"\n<span about=\"#mwt10\" class=\"reference\" data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"b\"}}' rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-b-2\">[X 1]</a></span>\n"},"attrs":{"group":"X"}}'><li about="#cite_note-b-2" id="cite_note-b-2" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-b-2-0" data-parsoid="{}">↑</a></span> foo</li></ol>
18620 Entities in ref name
18624 <ref name="test & me">hi</ref>
18626 <p data-parsoid='{}'><span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"hi"},"attrs":{"name":"test & me"}}' id="cite_ref-test & me-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"test &amp; me\">hi</ref>"}'><a href="#cite_note-test & me-1" data-parsoid="{}">[1]</a></span></p>
18629 # This test is wt2html only because we're permitting the serializer to produce
18630 # dirty diffs, normalizing the unclosed references to the self-closed version.
18632 Generate references for unclosed references tag
18640 <p data-parsoid='{}'>a<span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo</ref>"}'><a href="#cite_note-1" data-parsoid="{}">[1]</a></span></p>
18643 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-parsoid='{"src":"<references>"}' data-mw='{"name":"references","attrs":{}}'>
18644 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-1-0" data-parsoid="{}">↑</a></span> foo</li></ol>
18648 New reference serializes on its own line
18650 parsoid=wt2wt,html2wt
18655 foo<ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
18658 #### ----------------------------------------------------------------
18659 #### The following section of tests are primarily to test
18660 #### wikitext escaping capabilities of Parsoid. Given that
18661 #### escaping can be done any number of ways, the wikitext (input)
18662 #### is always adjusted to reflect how Parsoid adds nowiki
18665 #### We are marking several tests as parsoid-only since the
18666 #### HTML in the result section is different from what the
18667 #### PHP parser generates for it.
18668 #### ----------------------------------------------------------------
18671 #### --------------- Headings ---------------
18673 #### 1. Nested inside html <h1>=foo=</h1>
18674 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
18675 #### 3. Nested inside html with wikitext split by html tags
18676 #### 4. No escape needed
18677 #### 5. Empty headings <h1></h1>
18678 #### 6. Heading chars in SOL context
18679 #### ----------------------------------------
18681 Headings: 0. Unnested
18685 <nowiki>=foo=</nowiki>
18687 <nowiki> =foo= </nowiki>
18689 <nowiki>=foo=</nowiki>
18691 =foo''a''<nowiki>=</nowiki>
18693 <p><span typeof="mw:Nowiki">=foo=</span></p>
18695 <p><span typeof="mw:Nowiki"> =foo= </span>
18697 <span typeof="mw:Nowiki">=foo=</span></p>
18699 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
18703 Headings: 1. Nested inside html
18704 (New headings and existing headings are handled differently)
18714 =<nowiki>=foo=</nowiki>=
18715 ==<nowiki>=foo=</nowiki>==
18716 ===<nowiki>=foo=</nowiki>===
18717 ====<nowiki>=foo=</nowiki>====
18718 =====<nowiki>=foo=</nowiki>=====
18719 ======<nowiki>=foo=</nowiki>======
18726 <h1 data-parsoid='{}'>=foo=</h1>
18727 <h2 data-parsoid='{}'>=foo=</h2>
18728 <h3 data-parsoid='{}'>=foo=</h3>
18729 <h4 data-parsoid='{}'>=foo=</h4>
18730 <h5 data-parsoid='{}'>=foo=</h5>
18731 <h6 data-parsoid='{}'>=foo=</h6>
18735 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
18740 <nowiki>*</nowiki>bar
18746 <nowiki>=bar=</nowiki>
18754 Headings: 3. Nested inside html with wikitext split by html tags
18758 = ='''bold'''<nowiki>foo=</nowiki> =
18760 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
18764 Headings: 4a. No escaping needed (testing just h1 and h2)
18782 = <nowiki>=</nowiki> =
18790 <h1><i>=</i>foo=</h1>
18791 <h1><span typeof="mw:Nowiki">=</span></h1>
18795 Headings: 4b. No escaping needed (inside p-tags)
18810 Headings: 5. Empty headings
18822 =====<nowiki/>=====
18824 ======<nowiki/>======
18835 Headings: 6a. Heading chars in SOL context (with trailing spaces)
18839 <nowiki>=a=</nowiki>
18841 <nowiki>=a=</nowiki>
18843 <nowiki>=a=</nowiki>
18845 <nowiki>=a=</nowiki>
18854 Headings: 6b. Heading chars in SOL context (with trailing newlines)
18882 Headings: 6c. Heading chars in SOL context (leading newline break)
18887 <nowiki>=b=</nowiki>
18894 Headings: 6d. Heading chars in SOL context (with interspersed comments)
18898 <!--c0--><nowiki>=a=</nowiki>
18900 <!--c1--><nowiki>=a=</nowiki> <!--c2--> <!--c3-->
18902 <p><!--c0-->=a=</p>
18903 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
18907 Headings: 6d. Heading chars in SOL context (No escaping needed)
18916 #### --------------- Lists ---------------
18917 #### 0. Outside nests (*foo, etc.)
18918 #### 1. Nested inside html <ul><li>*foo</li></ul>
18919 #### 2. Inside definition lists
18920 #### 3. Only bullets at start should be escaped
18921 #### 4. No escapes needed
18922 #### 5. No unnecessary escapes
18923 #### 6. Escape bullets in SOL position
18924 #### 7. Escape bullets in a multi-line context
18925 #### ----------------------------------------
18928 Lists: 0. Outside nests
18930 <nowiki>*</nowiki>foo
18932 <nowiki>#</nowiki>foo
18934 <nowiki>;Foo:</nowiki>bar
18943 Lists: 1. Nested inside html
18945 *<nowiki>*foo</nowiki>
18947 *<nowiki>#foo</nowiki>
18949 *<nowiki>:foo</nowiki>
18951 *<nowiki>;foo</nowiki>
18953 #<nowiki>*foo</nowiki>
18955 #<nowiki>#foo</nowiki>
18957 #<nowiki>:foo</nowiki>
18959 #<nowiki>;foo</nowiki>
18961 <ul><li>*foo</li></ul>
18962 <ul><li>#foo</li></ul>
18963 <ul><li>:foo</li></ul>
18964 <ul><li>;foo</li></ul>
18965 <ol><li>*foo</li></ol>
18966 <ol><li>#foo</li></ol>
18967 <ol><li>:foo</li></ol>
18968 <ol><li>;foo</li></ol>
18973 Lists: 2. Inside definition lists
18975 ;<nowiki>;foo</nowiki>
18977 ;<nowiki>:foo</nowiki>
18979 ;<nowiki>:foo</nowiki>
18982 :<nowiki>:foo</nowiki>
18984 <dl><dt>;foo</dt></dl>
18985 <dl><dt>:foo</dt></dl>
18988 <dl><dd>:foo</dd></dl>
18993 Lists: 3. Only bullets at start of text should be escaped
18995 *<nowiki>*foo*bar</nowiki>
18997 *<nowiki>*foo</nowiki>''it''*bar
18999 <ul><li>*foo*bar</li></ul>
19000 <ul><li>*foo<i>it</i>*bar</li></ul>
19005 Lists: 4. No escapes needed
19026 <li><a rel="mw:WikiLink" href="Foo">Foo</a>: bar
19030 <li><a rel="mw:WikiLink" href="Foo">Foo</a>*bar
19036 Lists: 5. No unnecessary escapes
19038 * bar <span><nowiki>[[foo]]</nowiki></span>
19040 *=bar <span><nowiki>[[foo]]</nowiki></span>
19042 *[[bar <span><nowiki>[[foo]]</nowiki></span>
19044 *]]bar <span><nowiki>[[foo]]</nowiki></span>
19046 *=bar <span>foo]]</span>=
19050 <ul><li> bar <span>[[foo]]</span></li></ul>
19051 <ul><li>=bar <span>[[foo]]</span></li></ul>
19052 <ul><li>[[bar <span>[[foo]]</span></li></ul>
19053 <ul><li>]]bar <span>[[foo]]</span></li></ul>
19054 <ul><li>=bar <span>foo]]</span>=</li></ul>
19055 <ul><li> <s></s>: a</li></ul>
19060 Lists: 6. Escape bullets in SOL position
19064 <!--cmt--><nowiki>*foo</nowiki>
19066 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
19070 Lists: 7. Escape bullets in a multi-line context
19073 <nowiki>*</nowiki>b
19080 #### --------------- HRs ---------------
19081 #### 1. Single line
19082 #### -----------------------------------
19085 HRs: 1. Single line
19089 ----<nowiki>----</nowiki>
19093 <hr><span typeof="mw:Nowiki">----</span>
19098 #### --------------- Tables ---------------
19099 #### 1a. Simple example
19100 #### 1b. No escaping needed (!foo)
19101 #### 1c. No escaping needed (|foo)
19102 #### 1d. No escaping needed (|}foo)
19104 #### 2a. Nested in td (<td>foo|bar</td>)
19105 #### 2b. Nested in td (<td>foo||bar</td>)
19106 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
19108 #### 3a. Nested in th (<th>foo!bar</th>)
19109 #### 3b. Nested in th (<th>foo!!bar</th>)
19110 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
19114 #### 4c. No escaping needed
19115 #### --------------------------------------
19118 Tables: 1a. Simple example
19129 Tables: 1b. No escaping needed
19138 Tables: 1c. No escaping needed
19147 Tables: 1d. No escaping needed
19156 Tables: 2a. Nested in td
19161 |<nowiki>foo|bar</nowiki>
19163 |x<div><nowiki>a|b</nowiki></div>
19167 <td>foo|bar</td></tr>
19168 <tr><td>x<div>a|b</div></td>
19173 Tables: 2b. Nested in td
19178 |<nowiki>foo||bar</nowiki>
19179 |''it''<nowiki>foo||bar</nowiki>
19183 <td><span typeof="mw:Nowiki">foo||bar</span></td>
19184 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
19188 Tables: 2c. Nested in td -- no escaping needed
19196 <table><tbody><tr><td>foo!!bar
19197 </td></tr></tbody></table>
19202 Tables: 3a. Nested in th
19210 <table><tbody><tr><th>foo!bar
19211 </th></tr></tbody></table>
19216 Tables: 3b. Nested in th
19221 !<nowiki>foo!!bar</nowiki>
19225 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
19230 Tables: 3c. Nested in th -- no escaping needed
19235 !<nowiki>foo||bar</nowiki>
19239 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
19243 Tables: 4a. Escape -
19250 |<nowiki>-bar</nowiki>
19254 <tr><th>-bar</th></tr>
19256 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
19260 Tables: 4b. Escape +
19267 |<nowiki>+bar</nowiki>
19271 <tr><th>+bar</th></tr>
19273 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
19277 Tables: 4c. No escaping needed
19298 <tr><td>foo-bar</td><td>foo+bar</td></tr>
19299 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
19305 <div>a|b</div></td>
19310 Tables: 4d. No escaping needed
19321 <tbody><tr><td><a rel="mw:WikiLink" href="./Foo">Foo</a>-bar</td>
19322 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>+1</td>
19323 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>-2</td></tr>
19328 Tables: Digest broken attributes on table and tr tag
19344 #### --------------- Links ----------------
19345 #### 1. Quote marks in link text
19346 #### 2. Wikilinks: Escapes needed
19347 #### 3. Wikilinks: No escapes needed
19348 #### 4. Extlinks: Escapes needed
19349 #### 5. Extlinks: No escapes needed
19350 #### --------------------------------------
19352 Links 1. Quote marks in link text
19356 [[Foo|Foo<nowiki>''boo''</nowiki>]]
19358 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
19362 Links 2. WikiLinks: Escapes needed
19367 [[Foo|<nowiki>Foobar]</nowiki>]]
19368 [[Foo|x [Foobar] x]]
19369 [[Foo|x <nowiki>[http://google.com g]</nowiki> x]]
19370 [[Foo|<nowiki>[[Bar]]</nowiki>]]
19371 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
19372 [[Foo|<nowiki>|Bar</nowiki>]]
19373 [[Foo|<nowiki>]]bar</nowiki>]]
19374 [[Foo|<nowiki>[[bar</nowiki>]]
19375 [[Foo|<nowiki>x [[ y</nowiki>]]
19376 [[Foo|<nowiki>x ]] y</nowiki>]]
19377 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
19379 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
19380 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
19381 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
19382 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
19383 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
19384 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
19385 <a href="Foo" rel="mw:WikiLink">|Bar</a>
19386 <a href="Foo" rel="mw:WikiLink">]]bar</a>
19387 <a href="Foo" rel="mw:WikiLink">[[bar</a>
19388 <a href="Foo" rel="mw:WikiLink">x [[ y</a>
19389 <a href="Foo" rel="mw:WikiLink">x ]] y</a>
19390 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
19394 Links 3. WikiLinks: No escapes needed
19401 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
19402 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
19406 Links 4. ExtLinks: Escapes needed
19410 [http://google.com <nowiki>[google]</nowiki>]
19411 [http://google.com <nowiki>google]</nowiki>]
19413 <nowiki>[http://google.com]</nowiki>
19415 <nowiki>[http://google.com google]</nowiki>
19418 <p><a href="http://google.com" rel="mw:ExtLink">[google]</a>
19419 <a href="http://google.com" rel="mw:ExtLink">google]</a></p>
19420 <p>[http://google.com]</p>
19421 <p>[http://google.com google]</p>
19425 Links 5. ExtLinks: No escapes needed
19429 [http://google.com [google]
19431 <a href="http://google.com" rel="mw:ExtLink">[google</a>
19435 Links 6. Add <nowiki/>s between text-nodes and url-links when required (bug 64300)
19437 <p>x<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>y
19438 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>?x
19439 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>&x
19440 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>'x
19441 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,x
19442 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.x
19443 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
19444 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>:x
19445 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
19446 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>!x
19447 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>=x
19448 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>(x)
19449 <a rel="mw:ExtLink" href="http://example.com(x" data-parsoid='{"stx":"url"}'>http://example.com(x</a>)
19452 x<nowiki/>http://example.com<nowiki/>y
19453 http://example.com<nowiki/>?x
19454 http://example.com<nowiki/>&x
19455 http://example.com<nowiki/>'x
19456 http://example.com<nowiki/>,x
19457 http://example.com<nowiki/>.x
19458 http://example.com<nowiki/>;x
19459 http://example.com<nowiki/>:x
19460 http://example.com<nowiki/>;x
19461 http://example.com<nowiki/>!x
19462 http://example.com<nowiki/>=x
19463 http://example.com<nowiki/>(x)
19464 http://example.com(x<nowiki/>)
19468 Links 7a. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
19471 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>
19473 "<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>"
19474 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>)
19475 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>) foo
19476 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,
19477 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>, foo
19483 "http://example.com"
19484 (http://example.com)
19485 (http://example.com) foo
19486 http://example.com,
19487 http://example.com, foo
19490 ## Parsoid currently fails wt2html on this one!
19492 Links 7b. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
19494 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.,;:!?</p>
19496 http://example.com.,;:!?
19500 Links 8. Add <nowiki/>s between text-nodes and RFC-links when required (bug 64300)
19502 <p><a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>4</p>
19508 Links 9. Don't add spurious <nowiki/>s between text-nodes and RFC-links (bug 64300)
19510 <p>x<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
19511 X<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
19512 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>?foo
19513 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>&foo
19523 Links 10. Add <nowiki/>s between text-nodes and PMID-links when required (bug 64300)
19525 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>4
19531 Links 11. Don't add spurious <nowiki/>s between text-nodes and PMID-links (bug 64300)
19533 <p>x<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
19534 X<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
19535 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>?foo
19536 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>&foo
19546 Links 12. Add <nowiki/>s between text-nodes and ISBN-links when required (bug 64300)
19548 <p><a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>1
19549 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>x
19550 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>b
19553 ISBN 1234567890<nowiki/>1
19554 ISBN 1234567890<nowiki/>x
19555 ISBN 1234567890<nowiki/>b
19559 Links 12. Don't add spurious <nowiki/>s between text-nodes and ISBN-links (bug 64300)
19561 <p><a href="./Special:BookSources/1234567890" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>'s
19566 #### --------------- Quotes ---------------
19567 #### 1. Quotes inside <b> and <i>
19568 #### 2. Link fragments separated by <i> and <b> tags
19569 #### 3. Link fragments inside <i> and <b>
19570 #### 4. No escaping needed
19571 #### --------------------------------------
19573 1. Quotes inside <b> and <i>
19575 parsoid=html2wt,wt2wt
19577 ''<nowiki>'foo'</nowiki>''
19578 ''<nowiki>''foo''</nowiki>''
19579 ''<nowiki>'''foo'''</nowiki>''
19581 '''<nowiki>'foo'</nowiki>'''
19582 '''<nowiki>''foo''</nowiki>'''
19583 '''<nowiki>'''foo'''</nowiki>'''
19584 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
19585 '''foo'''<nowiki/>'s
19588 '<nowiki/>''foo''<nowiki/>'
19590 '''foo'''<nowiki/>'
19591 '<nowiki/>'''foo'''<nowiki/>'
19592 ''fools'<span> errand</span>''
19593 ''<span>fool</span>'s errand''
19602 <b>foo'<i>bar'</i>baz</b>
19610 <i>fools'<span> errand</span></i>
19611 <i><span>fool</span>'s errand</i>
19615 2. Link fragments separated by <i> and <b> tags
19617 [[''foo''<nowiki>hello]]</nowiki>
19619 [['''foo'''<nowiki>hello]]</nowiki>
19621 <p>[[<i>foo</i>hello]]
19622 </p><p>[[<b>foo</b>hello]]
19627 3. Link fragments inside <i> and <b>
19628 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
19629 this is one of the shortcomings of this format)
19631 ''[[foo''<nowiki>]]</nowiki>
19633 '''[[foo'''<nowiki>]]</nowiki>
19636 </p><p><b>[[foo</b>]]
19641 4. No escaping needed
19643 '<span>''bar''</span>'
19644 '<span>'''bar'''</span>'
19646 <p>'<span><i>bar</i></span>'
19647 '<span><b>bar</b></span>'
19651 #### ----------- Paragraphs ---------------
19652 #### 1. No unnecessary escapes
19653 #### --------------------------------------
19656 1. No unnecessary escapes
19658 bar <span><nowiki>[[foo]]</nowiki></span>
19660 =bar <span><nowiki>[[foo]]</nowiki></span>
19662 [[bar <span><nowiki>[[foo]]</nowiki></span>
19664 ]]bar <span><nowiki>[[foo]]</nowiki></span>
19666 =bar <span>foo]]</span><nowiki>=</nowiki>
19668 <p>bar <span>[[foo]]</span>
19669 </p><p>=bar <span>[[foo]]</span>
19670 </p><p>[[bar <span>[[foo]]</span>
19671 </p><p>]]bar <span>[[foo]]</span>
19672 </p><p>=bar <span>foo]]</span>=
19676 #### ----------------------- PRE --------------------------
19677 #### 1. Leading whitespace in SOL context should be escaped
19678 #### ------------------------------------------------------
19680 1. Leading whitespace in SOL context should be escaped
19684 <nowiki> </nowiki>a
19686 <nowiki> </nowiki> a
19688 <nowiki> </nowiki>a(tab)
19690 <nowiki> </nowiki> a
19692 <nowiki> </nowiki> a
19695 <nowiki> </nowiki>b
19698 <nowiki> </nowiki>b
19701 <nowiki> </nowiki> b
19707 <p><!--cmt--> a</p>
19717 2. Leading whitespace in non-indent-pre contexts should not be escaped
19724 <p>foo <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"<i data-parsoid='{\"dsr\":[9,14,2,2]}'>a</i>\n b"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
19728 3. Leading whitespace in indent-pre suppressing contexts should not be escaped
19747 4. Leading whitespace in indent-pre suppressing contexts should not be escaped
19751 [[File:Foobar.jpg|thumb|caption]]
19754 <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>
19758 5. Nowiki escaping should account for indent-pres
19767 #### --------------- Behavior Switches --------------------
19769 1. Valid behavior switches should be escaped
19773 <nowiki>__TOC__</nowiki>
19774 ''<nowiki>__TOC__</nowiki>''
19781 2. Invalid behavior switches should not be escaped
19792 #### --------------- HTML tags ---------------
19795 #### 3. multi-line html tag
19796 #### 4. extension tags
19797 #### -----------------------------------------
19803 <a href="http://google.com">google</a>
19805 <a href="http://google.com">google</a>
19811 <nowiki><div>foo</div>
19812 <div style="color:red">foo</div></nowiki>
19814 <p><div>foo</div>
19815 <div style="color:red">foo</div>
19820 3. multi-line html tag
19835 <nowiki><ref>foo</ref></nowiki>
19837 <nowiki><ref>bar</nowiki>
19839 baz<nowiki></ref></nowiki>
19841 <p><ref>foo</ref>
19842 </p><p><ref>bar
19843 </p><p>baz</ref>
19847 #### --------------- Others ---------------
19851 <nowiki>foo</nowiki>
19853 <p><nowiki>foo</nowiki>
19857 ## The quote-char in the input is necessary for triggering the bug
19859 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
19861 parsoid=wt2wt,html2wt
19870 Tag-like HTML structures are passed through as text
19892 </p><p>1<d e>f
19897 # This was a bug in the PHP parser (see bug 17663 and its dups,
19898 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
19900 Tag names followed by punctuation should not be recognized as tags
19904 <p><s.ome> text
19909 HTML tag with necessary entities in attributes
19911 <span title="&amp;">foo</span>
19913 <p><span title="&amp;">foo</span>
19918 HTML tag with 'unnecessary' entity encoding in attributes
19920 <span title="&">foo</span>
19922 <p><span title="&">foo</span>
19927 HTML tag with broken attribute value quoting
19929 <span title="Hello world>Foo</span>
19931 <p><span>Foo</span>
19936 Parsoid-only: HTML tag with broken attribute value quoting
19940 <span title="Hello world>Foo</span>
19942 <p><span title="Hello world">Foo</span>
19947 Table with broken attribute value quoting
19950 | title="Hello world|Foo
19961 Table with broken attribute value quoting on consecutive lines
19964 | title="Hello world|Foo
19965 | style="color:red|Bar
19978 Parsoid-only: Table with broken attribute value quoting on consecutive lines
19983 | title="Hello world|Foo
19984 | style="color:red|Bar
19989 <td title="Hello world">Foo
19990 </td><td style="color: red">Bar
19991 </td></tr></tbody></table>
19996 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
20006 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
20016 Accept empty td cell attribute
20019 | align="center" | foo || |
20024 <td align="center"> foo </td>
20031 Non-empty attributes in th-cells
20034 ! Foo !! style="color: red" | Bar
20040 <th style="color: red"> Bar
20046 Accept empty attributes in th-cells
20061 Empty table rows go away
20082 ### Parsoid-centric tests for testing RTing of inter-element separators
20083 ### Edge cases not tested by existing parser tests and specific to
20084 ### Parsoid-specific serialization strategies.
20088 RT-ed inter-element separators should be valid separators
20101 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
20102 (Parsoid-only since PHP parser relies on Tidy for correct output)
20118 Empty TD followed by TD with tpl-generated attribute
20123 |{{echo|style='color:red'}}|foo
20137 Indented table with an empty td
20156 Indented block & table
20163 <div data-parsoid='{"stx":"html"}'>foo</div>
20165 <tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>foo</td></tr>
20170 Indent and comment before table row
20177 <table data-parsoid='{}'>
20178 <!--hi--><tbody data-parsoid='{}'><tr data-parsoid='{"startTagSrc":"|-","autoInsertedEnd":true}'>
20179 <td data-parsoid='{"autoInsertedEnd":true}'> there</td></tr>
20184 Empty TR followed by a template-generated TR
20185 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
20191 {{echo|<tr><td>foo</td></tr>}}
20197 <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}}]}'>
20202 ## PHP and parsoid output differ for this, and since this is primarily
20203 ## for testing Parsoid's serializer, marking this Parsoid only
20205 Empty TR followed by mixed-ws-comment line should RT correctly
20221 <!--c--> </tr><!--d-->
20227 Multi-line image caption generated by templates with/without trailing newlines
20231 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
20232 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
20234 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC</div></div></div>
20235 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC\n\n</div></div></div>
20240 New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
20244 <includeonly>foo</includeonly>
20251 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>foo</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><p>new para</p>
20253 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid=''/><h1>new heading</h1>
20256 ## PHP emits broken html for this, and since this is primarily
20257 ## a Parsoid serializer test, marking this Parsoid only
20259 Improperly nested inline or quotes tags with whitespace in between
20263 <span> <s>x</span> </s>
20266 <p><span> <s>x</s></span><s> </s>
20267 <b> <i>x</i></b><i> </i>
20272 Encapsulate protected attributes from wt
20276 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
20278 <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>
20282 ## Currently the p-wrapper is fragile in how it adds / removes transformations.
20283 ## Having nested or stray pre tags results in the attempt to add duplicates,
20284 ## causing an assertion fail. This test tries to prevent that situation.
20286 Ensure ParagraphWrapper can deal with stray closing pre tags
20296 1. Ensure fostered text content is wrapped in spans
20300 <table>hi</table><table>ho</table>
20309 2. Ensure fostered text content is wrapped in spans (traps regressions around fostered marker on the span getting lost)
20311 parsoid=wt2html,wt2wt
20318 <span> || ||</span>
20327 Encapsulation properly handles null DSR information from foster box
20329 parsoid=wt2html,wt2wt
20331 {{echo|<table>foo<tr><td>bar</td></tr></table>}}
20333 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"
20336 <td>bar</td></tr></table>"}},"i":0}}]}">foo</span>
20340 <td>bar</td></tr></tbody></table>
20344 1. Encapsulate foster-parented transclusion content
20346 parsoid=wt2wt,wt2html
20348 <table>{{echo|foo<tr><td>bar</td></tr>}}</table>
20350 <span typeof="mw:Transclusion" data-mw="{"parts":["
20351 <table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo
20353 <td>bar</td></tr>"}},"i":0}},"</table>"]}">foo</span>
20357 <td>bar</td></tr></tbody></table>
20361 2. Encapsulate foster-parented transclusion content
20363 parsoid=wt2wt,wt2html
20365 <table><div>{{echo|foo}}</div><tr><td>bar</td></tr></table>
20367 <div typeof="mw:Transclusion" data-mw="{"parts":["
20369 <div>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}},"</div>
20371 <td>bar</td></tr></table>"]}">foo</div>
20375 <td>bar</td></tr></tbody></table>
20379 3. Encapsulate foster-parented transclusion content
20381 parsoid=wt2wt,wt2html
20383 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
20385 <div typeof="mw:Transclusion" data-mw="{"parts":["
20388 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div>
20390 <td>"}},"i":0}},"bar</td></tr></table>"]}">
20395 <td>bar</td></tr></tbody></table>
20399 4. Encapsulate foster-parented transclusion content
20401 parsoid=wt2wt,wt2html
20403 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
20405 <div typeof="mw:Transclusion" data-mw="{"parts":["
20408 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div>
20410 <td>"}},"i":0}},"bar</td></tr></table>"]}">
20415 <td>bar</td></tr></tbody></table>
20419 5. Encapsulate foster-parented transclusion content
20421 parsoid=wt2wt,wt2html
20423 <table><tr><td><div><p>{{echo|foo</p></div></td>foo}}</tr></table>
20425 <span typeof="mw:Transclusion" data-mw="{"parts":["
20430 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo"}},"i":0}},"</tr></table>"]}">foo</span>
20436 <p>foo</p></div></td></tr></tbody></table>
20440 6. Encapsulate foster-parented transclusion content
20442 parsoid=wt2wt,wt2html
20444 <table><tr><td><div><p>{{echo|foo</p></div></td>foo</tr></table>}}<p>ok</p>
20446 <span typeof="mw:Transclusion" data-mw="{"parts":["
20451 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo</tr></table>"}},"i":0}}]}">foo</span>
20457 <p>foo</p></div></td></tr></tbody></table>
20462 7. Encapsulate foster-parented transclusion content
20464 parsoid=wt2wt,wt2html
20466 <table>{{echo|<p>foo</p>}}<td>bar</td></table>
20468 <p typeof="mw:Transclusion" data-mw="{"parts":["
20469 <table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"
20470 <p>foo</p>"}},"i":0}},"
20471 <td>bar</td></table>"]}">foo</p>
20475 <td>bar</td></tr></tbody></table>
20479 8. Encapsulate foster-parented transclusion content
20481 parsoid=wt2wt,wt2html
20484 }}{|{{echo|style='color:red'}}
20489 <p typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n"}},"i":0}}]}">a</p><span typeof="mw:Transclusion" data-mw="{"parts":["{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"style":{"wt":"'color:red'"}},"i":0}},"\n|-\n|b\n|}"]}">{{{1}}}</span>
20493 <td>b</td></tr></tbody></table>
20497 9. Encapsulate foster-parented transclusion content
20499 parsoid=wt2wt,wt2html
20501 <table>{{echo|hi</table>hello}}
20503 <span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"hi</table>hello"}},"i":0}}]}' data-parsoid='{"fostered":true,"autoInsertedEnd":true,"autoInsertedStart":true,"pi":[[{"k":"1","spc":["","","",""]}]]}'>hi</span>
20504 <table about="#mwt2" data-parsoid='{"stx":"html"}'></table><span about="#mwt2" data-parsoid="{}">hello</span>
20508 Table in fosterable position
20510 parsoid=wt2html,wt2wt
20519 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"OpenTable","href":"./Template:OpenTable"},"params":{},"i":0}},"\n<div>"]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[]]}'></div><span about="#mwt1" data-parsoid="{}">
20521 <table about="#mwt1" data-parsoid='{"autoInsertedEnd":true}'></table>
20527 # Parsoid only for bug 64747
20529 Properly encapsulate empty-content transclusions in fosterable positions
20537 <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>"}'>
20543 Support <object> element with .data attribute
20547 <object data="test.swf"></object>
20549 <object data="test.swf"></object>
20552 # -----------------------------------------------------------------
20553 # The following section of tests are primarily to spec requirements
20554 # around serialization of new/edited content.
20556 # All these tests are marked Parsoid html2wt and html2html only
20557 # ----------------------------------------------------------------
20560 Serialize interwiki links pointing to the current wiki as plain wiki links (bug 65869)
20567 <p><a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/Foo">Foo</a></p>
20571 Image: Modifying size of an image (1)
20574 "modes": ["wt2wt"],
20576 ["img[height]", "attr", "height", "22"],
20577 ["img[width]", "attr", "width", "200"]
20581 [[Image:Foobar.jpg|230x230px]]
20583 [[Image:Foobar.jpg|200x200px]]
20587 Image: Modifying size of an image (2)
20590 "modes": ["wt2wt"],
20592 ["img[height]", "attr", "height", "100"],
20593 ["img[width]", "attr", "width", "500"]
20597 [[Image:Foobar.jpg|230x230px]]
20599 [[Image:Foobar.jpg|500x500px]]
20602 # Change in size is ignored so long as class='mw-default-size'
20604 Image: Modifying size of an image (3)
20607 "modes": ["wt2wt"],
20609 ["figure[class]", "removeClass", "mw-default-size"],
20610 ["figure img", "attr", "height", "19"],
20611 ["figure img", "attr", "width", "170"]
20615 [[Image:Foobar.jpg|thumb]]
20617 [[Image:Foobar.jpg|thumb|170x170px]]
20621 Image: Modifying alignment of an image (bug 48665)
20624 "modes": ["wt2wt"],
20626 ["figure[class]", "removeClass", "mw-halign-right"],
20627 ["figure[class]", "addClass", "mw-halign-left"]
20631 [[Image:Foobar.jpg|thumb|caption|right]]
20633 [[Image:Foobar.jpg|thumb|caption|left]]
20637 Image: Modifying mw-default-size of an frameless image (bug 62805)
20640 "modes": ["wt2wt"],
20642 ["figure.mw-default-size", "removeClass", "mw-default-size"]
20646 [[Image:Foobar.jpg|frameless|right]]
20648 [[Image:Foobar.jpg|frameless|right|220x220px]]
20652 Image: Modifying valign of an image (bug 49221)
20655 "modes": ["wt2wt"],
20657 ["*[typeof=\"mw:Image\"]", "removeClass", "mw-valign-middle"],
20658 ["*[typeof=\"mw:Image\"]", "addClass", "mw-valign-text-top"]
20662 [[File:Foobar.jpg|20px|middle]]
20664 [[File:Foobar.jpg|20px|text-top]]
20668 Image: Modifying alt attribute of an image (bug 56400)
20671 "modes": ["wt2wt"],
20673 ["img[alt]", "attr", "alt", "some alternate edited text"]
20677 [[File:Foobar.jpg|thumb|some caption|alt=some alternate text]]
20679 [[File:Foobar.jpg|thumb|some caption|alt=some alternate edited text]]
20683 Image: Modifying caption of an image
20686 "modes": ["wt2wt"],
20688 ["figcaption", "text", "new caption"]
20692 [[Image:Foobar.jpg|thumb|original caption]]
20694 [[Image:Foobar.jpg|thumb|new caption]]
20698 Image: empty alt attribute (bug 48924)
20702 [[File:Foobar.jpg|thumb|alt=|bar]]
20704 <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>
20708 #Image: new attributes should be serialized in wiki's language for RTL languages (bug 51852)
20713 #[[Imagen:Foobar.jpg|derecha|miniaturadeimagen]]
20715 #<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>
20719 Image: Block level image should have \n before and after
20724 [[File:Foobar.jpg|right|thumb|150x150px]]
20727 <p>123</p><figure typeof="mw:Image/Thumb" class="mw-halign-right"><a href="./File:Foobar.png"><img src="http://192.168.142.128/mw/images/thumb/b/bc/Foobar.png/131px-Foobar.png" width="131" height="150" resource="./File:Foobar.png" data-parsoid='{"a":{"resource":"./File:Foobar.png","width":"131"},"sa":{"resource":"File:Foobar.png","width":"150"}}'></a></figure><p>456</p>
20731 Image: New block level image should have \n before and after (existing
20737 [[File:Foobar.jpg|right|thumb|150x150px]]
20740 <p data-parsoid='{"dsr":[0,3,0,0]}'>123</p>
20741 <figure class="mw-halign-right" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"right","ak":"right"},{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"150x150px"}],"dsr":[4,45,2,2]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"dsr":[6,43,null,null]}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/150px-Foobar.jpg" height="17" width="150" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"17","width":"150"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></figure>
20742 <p data-parsoid='{"dsr":[46,49,0,0]}'>456</p>
20746 Image: upright option (parsoid)
20750 [[File:Foobar.jpg|thumb|upright|caption]]
20751 [[File:Foobar.jpg|thumb|upright=0.5|caption]]
20752 [[File:Foobar.jpg|thumb|500x500px|upright=0.5|caption]]
20754 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="19" width="170"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="12" width="110"/></a><figcaption>caption</figcaption></figure><figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="57" width="500"/></a><figcaption>caption</figcaption></figure>
20758 Image: upright option is ignored on inline and frame images (parsoid)
20762 [[File:Foobar.jpg|500x500px|upright=0.5|caption]]
20764 <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>
20768 Image: from basic HTML (1)
20772 <span typeof="mw:Image">
20773 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
20776 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
20780 Image: from basic HTML (2)
20784 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
20786 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
20790 Image: from basic HTML (3)
20794 <a href="Main"><img src="File:Foobar.jpg" width=100 height=100 alt="Alt"></a>
20796 [[File:Foobar.jpg|link=Main|alt=Alt|100x100px]]
20800 Image: from basic HTML (4)
20804 <img src="File:Foobar.jpg">
20806 [[File:Foobar.jpg|link=]]
20810 Lists: Serialize correctly even when list content is wrapped in p-tags (like VE does)
20817 <li><p>foo</p></li>
20822 Lists: Serialize correctly even when list tags has unneeded whitespace between tags
20828 <ul> <li>foo</li></ul>
20832 Don't strip leading whitespace when handling indent-pre suppressing tags
20840 '''This is very bold of you!'''
20844 indented cell (no pre-wrapping!)
20851 <tr><td> indented row</td></tr>
20854 <b>This is very bold of you!</b>
20857 indented cell (no pre-wrapping!)
20865 Nowiki-wrap leading whitespace when handling indent-pre inducing tags
20870 <nowiki> </nowiki><span>bar</span>
20873 <nowiki> </nowiki></span>bar2
20876 <nowiki> </nowiki><span>bar</span>
20879 <nowiki> </nowiki><span>foo</span>
20897 Lists: Add space after bullets
20903 * <span> baz</span>
20908 <li><span> baz</span></li>
20913 Lists: Dont insert newlines in a serialized list item.
20920 <ul><li>a<br>b</li><li>c</li></ul>
20924 Headings: Add space before/after == (Bug 51744)
20934 == <span> baz</span> ==
20939 <h2><span> baz</span></h2>
20943 Parsoid: Serialize positional parameters with = in them as named parameter
20949 {{echo|1 = f=oo|2 = bar}}
20951 <!--Orig params with data-parsoid has heuristics for handling = chars-->
20952 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
20953 {{echo|<nowiki>f=oo</nowiki>|bar}}
20955 <p about="#mwt1" typeof="mw:Transclusion"
20956 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}}]}'>foo</p>
20958 <p about="#mwt1" typeof="mw:Transclusion"
20959 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}, "2":{"wt":"bar"}},"i":0}}]}'>foo</p>
20961 <!--Orig params with data-parsoid has heuristics for handling = chars-->
20962 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
20963 <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>
20967 Parsoid: Correctly serialize block-node children when they are a combination of text and p-nodes
20983 <div>a<p>b</p></div>
20992 Substrings resembling wikitext in hrefs should not get nowiki escapes
20998 <a rel="mw:WikiLink" href="./Foo''bar''baz">Foo''bar''baz</a>
21001 #-----------------------------
21002 # I/B quote minimization tests
21003 #-----------------------------
21006 1. I/B quote minimization: wikitext-only tags should be combined
21026 <p><i>A</i><i>B</i></p>
21027 <p><b>A</b><b>B</b></p>
21028 <p><i>A</i><b><i>B</i></b></p>
21029 <p><b>A</b><i><b>B</b></i></p>
21030 <p><b>A</b><i><b>B</b><b>C</b></i><b>D</b></p>
21031 <p><i><b>A</b></i><i><b>B</b></i></p>
21032 <p><i><b>A</b></i><b><i>B</i></b></p>
21033 <p><b><i>A</i></b><i><b>B</b></i></p>
21037 2. I/B quote minimization: wikitext and html tags should not be combined
21043 ''A'''''<i>B</i>'''
21045 <p><i>A</i><i data-parsoid='{"stx":"html"}'>B</i></p>
21046 <p><i>A</i><b><i data-parsoid='{"stx":"html"}'>B</i></b></p>
21050 3. I/B quote minimization: templated content stops minimization
21054 ''A''{{echo|''B''}}
21056 ''A''{{echo|'''''B'''''}}
21058 <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>
21059 <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>
21063 4. I/B quote minimization: new content should be mimimized with adjacent old content
21073 <p><i>A</i><i data-parsoid='{}'>B</i></p>
21074 <p><b data-parsoid='{}'>A</b><b>B</b></p>
21075 <p><i>A</i><b data-parsoid='{}'><i data-parsoid='{}'>B</i></b></p>
21078 #------------------------------------
21079 # End of I/B quote minimization tests
21080 #------------------------------------
21083 Bug 54262: New entities
21089 <span typeof="mw:Entity"> </span>
21092 ## Note that there is no wikitext output for 'unknownproperty' ##
21093 ## Unknown magic words are silently dropped ##
21108 __NOCONTENTCONVERT__
21110 <meta property='mw:PageProp/toc' />
21111 <meta property='mw:PageProp/notoc' />
21112 <meta property='mw:PageProp/forcetoc' />
21113 <meta property='mw:PageProp/index' />
21114 <meta property='mw:PageProp/noindex' />
21115 <meta property='mw:PageProp/nogallery' />
21116 <meta property='mw:PageProp/noeditsection' />
21117 <meta property='mw:PageProp/notitleconvert' />
21118 <meta property='mw:PageProp/nocontentconvert' />
21119 <meta property='mw:PageProp/unknownproperty' />
21123 Consecutive <pre>s should not get merged
21125 parsoid=html2wt,html2html
21141 <pre>a</pre><pre>b</pre>
21155 Edited ISBN links not serializable as ISBN links should serialize as wikilinks
21159 [[Special:BookSources/1234567890|ISBN 1234567895]]
21161 <a rel="mw:ExtLink" href="./Special:BookSources/1234567890">ISBN 1234567895</a>
21165 Edited RFC links not serializable as RFC links should serialize as extlinks
21169 [//tools.ietf.org/html/rfc123 New RFC]
21171 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink">New RFC</a>
21175 Edited PMID links not serializable as PMID links should serialize as extlinks
21179 [//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract New PMID]
21181 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink">New PMID</a>
21185 Edited Redirect link should emit a non-piped wikitext link
21191 <link rel="mw:PageProp/redirect" href="Bar" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>
21194 # -----------------------------------------------------------------
21195 # End of section for Parsoid-only html2wt tests for serialization
21197 # -----------------------------------------------------------------
21204 Try for 100% code coverage