1 # MediaWiki Parser test cases
2 # Some taken from https://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 # (ignored by Parsoid, since it emits <link>s)
18 # ill add inter-language links
19 # (ignored by Parsoid, since it emits <link>s)
20 # subpage enable subpages (disabled by default)
21 # title=[[XXX]] run test using article title XXX
22 # language=XXX set content language to XXX for this test
23 # variant=XXX set the variant of language for this test (eg zh-tw)
24 # disabled do not run test
25 # parsoid parsoid-specific options (not run by PHP parser unless
26 # the test includes an html/php section)
27 # php php-only test (not run by the parsoid parser unless
28 # the test includes an html/parsoid section)
29 # showtitle make the first line the title
30 # showindicators make the first lines the page status indicators
31 # comment run through Linker::formatComment() instead of main parser
32 # local format section links in edit comment text as local links
33 # notoc disable table of contents
34 # thumbsize=NNN set the default thumb size to NNNpx for this test
36 # You can also set the following parser properties via test options:
37 # wgEnableUploads, wgAllowExternalImages, wgMaxTocLevel,
38 # wgLinkHolderBatchSize, wgRawHtml, wgInterwikiMagic,
41 # For testing purposes, temporary articles can created:
42 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
43 # where '/' denotes a newline.
45 # This is the standard article assumed to exist.
82 MediaWiki:bad image list
84 * [[File:Bad.jpg]] except [[Nasty page]]
112 Template:echo_with_span
118 Template:echo_with_div
131 Template:table_attribs
134 |</noinclude>style="color:red;"|Foo
138 Template:table_attribs_2
141 |</noinclude>style="color:red;"|Foo
146 Template:table_attribs_3
149 |</noinclude>style{{=}}"background:#f9f9f9;"|Foo
153 Template:table_attribs_4
155 | style="background-color:#DC241f;" width="10px" |
159 Template:table_attribs_5
162 |</noinclude>style="color:red;"||Bar
166 Template:table_attribs_6
168 style="background: <nowiki>
175 Template:table_attribs_7
178 |</noinclude>style{{=}}"background:#f9f9f9;"|Foo<ref>foo</ref>
182 Template:table_header_cells
184 {{table_attribs}}!!style='color:red;'|''Bar''||style='color:brown;'|''Foo'' and Baz
190 {{table_attribs}}||style='color:red;'|''Bar''||style='color:brown;'|''Foo'' and Baz
194 Template:PartialTable
201 Template:image_attribs
204 [[File:foobar.jpg|</noinclude>right|Caption text<noinclude>]]</noinclude>
207 ## See T48811 for details
209 Template:mixed_attr_content_template
211 style="color:red;" title="T48811"
217 Template:definition_list
264 Template:EmptyTRWithHTMLAttrTest
267 <tr align="center"></tr>
268 <tr><td>foo</td></tr>
269 <tr align="center"></tr>
270 <tr><td>bar</td></tr>
277 <ref>{{CircularRef}}</ref>
295 <p><span about="#mwt1" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"CircularRef","href":"./Template:CircularRef"},"params":{},"i":0}}]}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></p>
296 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">Error: Expansion loop detected at <a data-parsoid='{"a":{"href":null},"sa":{"href":"Template:CircularRef"}}'>Template:CircularRef</a></span></li></ol>
302 This is a simple paragraph.
304 <p>This is a simple paragraph.
309 Paragraphs with extra newline spacing
332 Paragraphs with newline spacing with comment lines in between
340 <!--foo--><!--More than 1 comment, still stripped-->
344 <!--foo--> <!----> <!-- bar -->
405 Paragraphs with newline spacing with non-empty white-space lines in between
432 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
440 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
479 Extra newlines: More paragraphs with indented comment
494 Extra newlines followed by heading
509 <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>
510 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
513 <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>
518 Extra newlines between heading and content are swallowed
526 <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>
527 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
532 Heading with line break in nowiki
539 <h2><span class="mw-headline" id="A_B.0AC">A B
540 C</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 B C">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
543 <h2 id="A_B.0AC">A <span typeof="mw:Nowiki">B
550 http://fr.wikipedia.org/wiki/🍺
551 <!-- EasterEgg we love beer, better be able be able to link to it -->
553 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
557 # Note that the html+tidy output removes the spaces after the <li>,
558 # which is a bug (https://sourceforge.net/p/tidy/bugs/945/, etc).
559 # This is an issue for all tests with lists. We intentionally do
560 # *not* add html+tidy clauses for these, as we don't want to
561 # document/test the broken behavior. (Parsoid matches the non-tidy
562 # output in these cases.)
571 <li> Item 2</li></ul>
579 * plain''italic''plain
580 * plain''italic''plain''italic''plain
581 * plain'''bold'''plain
582 * plain'''bold'''plain'''bold'''plain
583 * plain''italic''plain'''bold'''plain
584 * plain'''bold'''plain''italic''plain
585 * plain''italic'''bold-italic'''italic''plain
586 * plain'''bold''bold-italic''bold'''plain
587 * plain'''''bold-italic'''italic''plain
588 * plain'''''bold-italic''bold'''plain
589 * plain''italic'''bold-italic'''''plain
590 * plain'''bold''bold-italic'''''plain
591 * plain l'''italic''plain
592 * plain l''''bold''' plain
595 <li> plain<i>italic</i>plain</li>
596 <li> plain<i>italic</i>plain<i>italic</i>plain</li>
597 <li> plain<b>bold</b>plain</li>
598 <li> plain<b>bold</b>plain<b>bold</b>plain</li>
599 <li> plain<i>italic</i>plain<b>bold</b>plain</li>
600 <li> plain<b>bold</b>plain<i>italic</i>plain</li>
601 <li> plain<i>italic<b>bold-italic</b>italic</i>plain</li>
602 <li> plain<b>bold<i>bold-italic</i>bold</b>plain</li>
603 <li> plain<i><b>bold-italic</b>italic</i>plain</li>
604 <li> plain<b><i>bold-italic</i>bold</b>plain</li>
605 <li> plain<i>italic<b>bold-italic</b></i>plain</li>
606 <li> plain<b>bold<i>bold-italic</i></b>plain</li>
607 <li> plain l'<i>italic</i>plain</li>
608 <li> plain l'<b>bold</b> plain</li></ul>
612 # this example taken from the [[simple:Moon]] article (bug 47326)
614 Italics and possessives (1)
616 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
618 <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
622 # this example taken from [[en:Flaming Pie]] (bug 49926)
624 Italics and possessives (2)
626 '''''Flaming Pie''''' is ... released in 1997. In ''Flaming Pie'''s liner notes
628 <p><i><b>Flaming Pie</b></i> is ... released in 1997. In <i>Flaming Pie'</i>s liner notes
632 # this example taken from [[en:Dictionary]] (bug 49926)
634 Italics and possessives (3)
636 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''.
638 <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>.
644 ### 2-quote opening sequence tests
647 Italics and bold: 2-quote opening sequence: (2,2)
656 Italics and bold: 2-quote opening sequence: (2,3)
665 Italics and bold: 2-quote opening sequence: (2,4)
675 # same html as previous, but wikitext adjusted to match parsoid html2wt
677 Italics and bold: 2-quote opening sequence: (2,4) w/ nowiki
679 ''foo<nowiki>''</nowiki>''
685 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
687 Italics and bold: 2-quote opening sequence: (2,5)
700 # same html as previous, but wikitext adjusted to match parsoid html2wt
702 Italics and bold: 2-quote opening sequence: (2,5+3) w/ nowiki
704 ''foo'''''<nowiki/>'''
715 ### 3-quote opening sequence tests
719 Italics and bold: 3-quote opening sequence: (3,2)
728 Italics and bold: 3-quote opening sequence: (3,3)
737 Italics and bold: 3-quote opening sequence: (3,4)
745 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
747 Italics and bold: 3-quote opening sequence: (3,5)
760 # same html as previous, but wikitext adjusted to match parsoid html2wt
762 Italics and bold: 3-quote opening sequence: (3,5+2) w/ nowiki
764 '''foo'''''<nowiki/>''
775 ### 4-quote opening sequence tests
779 Italics and bold: 4-quote opening sequence: (4,2)
789 # same html as previous, but wikitext adjusted to match parsoid html2wt
791 Italics and bold: 4-quote opening sequence: (4,2) w/ nowiki
793 <nowiki>''</nowiki>''foo''
800 Italics and bold: 4-quote opening sequence: (4,3)
809 Italics and bold: 4-quote opening sequence: (4,4)
819 # same html as previous, but wikitext adjusted to match parsoid html2wt
821 Italics and bold: 4-quote opening sequence: (4,4) w/ nowiki
829 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
831 Italics and bold: 4-quote opening sequence: (4,5)
840 <p>'<b>foo</b><i></i>
844 # same html as previous, but wikitext adjusted to match parsoid html2wt
846 Italics and bold: 4-quote opening sequence: (4,5+2) w/ nowiki
848 '<nowiki/>'''foo'''''<nowiki/>''
853 <p>'<b>foo</b><i></i>
859 ### 5-quote opening sequence tests
863 Italics and bold: 5-quote opening sequence: (5,2)
873 # same html as previous, but wikitext adjusted to match parsoid html2wt
875 Italics and bold: 5-quote opening sequence: (5,2+3)
884 Italics and bold: 5-quote opening sequence: (5,3)
894 # same html as previous, but wikitext adjusted to match parsoid html2wt
896 Italics and bold: 5-quote opening sequence: (5,3+2)
905 Italics and bold: 5-quote opening sequence: (5,4)
911 <p><i><b>foo'</b></i>
916 Italics and bold: 5-quote opening sequence: (5,5)
925 Italics and bold: 5-quote opening sequence: (5,6)
929 <p><i><b>foo'</b></i>
934 ### multiple quote sequences in a line
937 Italics and bold: multiple quote sequences: (2,4,2)
943 <p><i>foo'<b>bar</b></i>
948 # same html as previous, but wikitext adjusted to match parsoid html2wt
950 Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
952 ''foo'<nowiki/>'''bar'''''
954 <p><i>foo'<b>bar</b></i>
960 Italics and bold: multiple quote sequences: (2,4,3)
966 <p><i>foo'<b>bar</b></i>
971 # same html as previous, but wikitext adjusted to match parsoid html2wt
973 Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
975 ''foo'<nowiki/>'''bar'''''
977 <p><i>foo'<b>bar</b></i>
983 Italics and bold: multiple quote sequences: (2,4,4)
989 <p><i>foo'<b>bar'</b></i>
994 # same html as previous, but wikitext adjusted to match parsoid html2wt
996 Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
998 ''foo'<nowiki/>'''bar'<nowiki/>'''''
1000 <p><i>foo'<b>bar'</b></i>
1005 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
1007 Italics and bold: multiple quote sequences: (3,4,2)
1016 <p><b>foo'</b>bar<i></i>
1020 # same html as previous, but wikitext adjusted to match parsoid html2wt
1022 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
1026 '''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
1031 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
1036 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
1038 Italics and bold: multiple quote sequences: (3,4,3)
1047 <p><b>foo'</b>bar<b></b>
1051 # same html as previous, but wikitext adjusted to match parsoid html2wt
1053 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
1055 '''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
1060 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
1065 ### other quote tests
1068 Italics and bold: other quote tests: (2,3,5)
1070 ''this is about '''foo's family'''''
1072 <p><i>this is about <b>foo's family</b></i>
1078 Italics and bold: other quote tests: (2,(3,3),2)
1080 ''this is about '''foo's''' family''
1082 <p><i>this is about <b>foo's</b> family</i>
1088 Italics and bold: other quote tests: (3,2,3,2)
1092 '''this is about ''foo'''s family''
1094 <p><b>this is about <i>foo</i></b><i>s family</i>
1099 # same html as previous, but wikitext adjusted to match parsoid html2wt
1101 Italics and bold: other quote tests: (3,2,3+2+2,2)
1103 '''this is about ''foo'''''<nowiki/>''s family''
1105 <p><b>this is about <i>foo</i></b><i>s family</i>
1111 Italics and bold: other quote tests: (3,2,3,3)
1113 '''this is about ''foo'''s family'''
1115 <p>'<i>this is about </i>foo<b>s family</b>
1121 Italics and bold: other quote tests: (3,(2,2),3)
1123 '''this is about ''foo's'' family'''
1125 <p><b>this is about <i>foo's</i> family</b>
1131 Italicized possessive
1133 The ''[[Main Page]]'''s talk page.
1135 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
1138 <p>The <i><a rel="mw:WikiLink" href="Main_Page" title="Main Page">Main Page</a>'</i>s talk page.</p>
1142 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
1143 (Requires tidy for PHP parser output to be fixed up)
1145 parsoid=wt2html,wt2wt
1162 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
1163 <td><i>a</i></td><td><i>b</i></td></tr>
1172 Non-html5 tags should be accepted
1174 <center>''foo''</center>
1176 <font>''foo''</font>
1177 <strike>''foo''</strike>
1180 <center><i>foo</i></center>
1181 <p><big><i>foo</i></big>
1182 <font><i>foo</i></font>
1183 <strike><i>foo</i></strike>
1189 <wbr> is valid wikitext (bug 52468)
1197 # <strike> is HTML4, <s> is HTML4/5.
1199 <s> or <strike> for strikethrough
1201 <strike>strike</strike>
1205 <p><strike>strike</strike>
1213 Text-level semantic html elements in wikitext
1216 <strong>text</strong>
1232 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1239 <strong>text</strong>
1255 <ruby><rb>明日</rb><rp>(</rp><rt>Ashita</rt><rp> </rp><rtc>あした</rtc><rp>)</rp></ruby>
1263 # test cases taken from
1264 # https://www.w3.org/TR/html5/text-level-semantics.html#the-ruby-element
1266 Ruby markup (W3C-style)
1268 ; Mono-ruby for individual base characters
1269 : <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby>
1271 : <ruby>今日<rt>きょう</rt></ruby>
1273 : <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby>
1275 : <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby>
1277 : <ruby><rb>旧</rb><rb>金</rb><rb>山</rb><rt>jiù</rt><rt>jīn</rt><rt>shān</rt><rtc>San Francisco</rtc></ruby>
1279 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1280 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1281 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1284 <dl><dt> Mono-ruby for individual base characters</dt>
1285 <dd> <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby></dd>
1286 <dt> Group ruby</dt>
1287 <dd> <ruby>今日<rt>きょう</rt></ruby></dd>
1288 <dt> Jukugo ruby</dt>
1289 <dd> <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby></dd>
1290 <dt> Inline ruby</dt>
1291 <dd> <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby></dd>
1292 <dt> Double-sided ruby</dt>
1293 <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>
1295 <rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang="fr"><rt>Cœur</rt></rtc>
1296 <rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang="fr"><rt>Trèfle</rt></rtc>
1297 <rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang="fr"><rt>Étoile</rt></rtc>
1302 # The next two test different paths in the sanitizer.
1304 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
1306 <blockquote|>a</blockquote>
1308 <b→> doesn't terminate </b→>
1310 <bä> doesn't terminate </bä>
1312 <boo> doesn't terminate </boo>
1314 <s.foo> doesn't terminate </s.foo>
1318 <p><blockquote|>a</blockquote>
1319 </p><p><b→> doesn't terminate </b→>
1320 </p><p><bä> doesn't terminate </bä>
1321 </p><p><boo> doesn't terminate </boo>
1322 </p><p><s.foo> doesn't terminate </s.foo>
1323 </p><p><sub-ID#1>
1327 # There is a tidy bug here: https://sourceforge.net/p/tidy/bugs/946/
1328 # If the non-word-character tag made it through the sanitizer, tidy
1329 # would munge it up.
1331 Non-word characters don't terminate tag names + tidy
1333 <blockquote|>a</blockquote>
1335 <b→> doesn't terminate </b→>
1337 <bä> doesn't terminate </bä>
1339 <boo> doesn't terminate </boo>
1341 <s.foo> doesn't terminate </s.foo>
1345 <p><blockquote|>a</p>
1346 <p><b→> doesn't terminate </b→></p>
1347 <p><bä> doesn't terminate </bä></p>
1348 <p><boo> doesn't terminate </boo></p>
1349 <p><s.foo> doesn't terminate </s.foo></p>
1350 <p><sub-ID#1></p>
1354 ### See tests/parser/parserTestsParserHook.php for the <tåg> extension)
1355 ### This checks that HTML5 tags (with non-word characters in the tag
1356 ### name) make it safely through the parser -- the Sanitizer will
1357 ### munge them later, as it should.
1360 Non-word characters are valid in extension tags (T19663)
1371 <pre typeof="mw:Extension/tåg" data-mw='{"name":"tåg","attrs":{},"body":{"extsrc":"tåg"}}' data-parsoid='{}' about="#mwt2"></pre>
1375 Isolated close tags should be treated as literal text (bug 52760)
1383 <p><s.foo>s</p>
1385 <p><s.foo>s</p>
1389 ### Special characters
1393 Bare pipe character (bug 52363)
1402 Bare pipe character from a template (bug 52363)
1411 ### <nowiki> test cases
1415 <nowiki> unordered list
1417 <nowiki>* This is not an unordered list item.</nowiki>
1419 <p>* This is not an unordered list item.
1422 <p><span typeof="mw:Nowiki">* This is not an unordered list item.</span></p>
1428 <nowiki>Lorem ipsum dolor
1436 <p>Lorem ipsum dolor
1445 <p><span typeof="mw:Nowiki">Lorem ipsum dolor
1455 Don't parse <nowiki><span class="error"></nowiki> (T149622)
1457 <nowiki><span class="error"></nowiki>
1459 <p><span class="error">
1462 <p><span typeof="mw:Nowiki"><span class="error"></span></p>
1468 :There is not nowiki.
1469 :There is <nowiki>nowiki</nowiki>.
1471 #There is not nowiki.
1472 #There is <nowiki>nowiki</nowiki>.
1474 *There is not nowiki.
1475 *There is <nowiki>nowiki</nowiki>.
1477 <dl><dd>There is not nowiki.</dd>
1478 <dd>There is nowiki.</dd></dl>
1479 <ol><li>There is not nowiki.</li>
1480 <li>There is nowiki.</li></ol>
1481 <ul><li>There is not nowiki.</li>
1482 <li>There is nowiki.</li></ul>
1485 <dl><dd data-parsoid='{}'>There is not nowiki.</dd>
1486 <dd data-parsoid='{}'>There is <span typeof="mw:Nowiki">nowiki</span>.</dd></dl>
1488 <ol><li data-parsoid='{}'>There is not nowiki.</li>
1489 <li data-parsoid='{}'>There is <span typeof="mw:Nowiki">nowiki</span>.</li></ol>
1491 <ul><li data-parsoid='{}'>There is not nowiki.</li>
1492 <li data-parsoid='{}'>There is <span typeof="mw:Nowiki">nowiki</span>.</li></ul>
1496 Entities inside <nowiki>
1498 <nowiki><</nowiki>
1505 Entities inside template parameters
1511 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}}]}'>–</span></p>
1515 Properly escape nowiki when combined with other wiki markup
1519 <p>* </nowiki> tag</p>
1521 <nowiki>*</nowiki> <nowiki></nowiki></nowiki> tag
1525 T93824: Put escaped HTML tags inside nowiki
1529 <p><h2>foo</h2></p>
1531 <nowiki><h2>foo</h2></nowiki>
1535 T71950: 1. Put nowiki as close to cause as possible, even with non-quote escapable chars
1539 <p>This text: L'<a rel="mw:WikiLink" href="./Foo">Foo</a>
1540 This text: L''<a rel="mw:WikiLink" href="./Foo">Foo</a>
1541 This text: L'''<a rel="mw:WikiLink" href="./Foo">Foo</a>''</p>
1543 This text: L'[[Foo]]
1544 This text: L<nowiki>''</nowiki>[[Foo]]
1545 This text: L<nowiki>'''</nowiki>[[Foo]]<nowiki>''</nowiki>
1548 # This test fails because wikitext whitespace is not normalized before comparing.
1550 T71950: 2. Put nowiki as close to cause as possible, after ' :'
1554 <p>This text : L''<a rel="mw:WikiLink" href="./Foo">Foo</a>
1557 This text : L<nowiki>''</nowiki>[[Foo]]
1560 # This test and the next one are html2wt only as they test that incorrect wikitext
1561 # passed in template arguments gets escaped or wrapped in nowikis where required.
1563 T71482: Use {{!}} instead of nowiki for single pipe in template argument
1567 <p><span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo|bar"}},"i":0}}]}" about="#mwt1"></span>
1568 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo|bar |[["}},"i":0}}]}" about="#mwt2"></p>
1570 {{echo|foo{{!}}bar}}
1571 {{echo|<nowiki>foo|bar |[[</nowiki>}}
1575 T53961: Output correct nowikis in template arguments
1579 <p><span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a [ b"}},"i":0}}]}" about="#mwt1"></span>
1580 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a }} b"}},"i":0}}]}" about="#mwt2"></span>
1581 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a [[ b"}},"i":0}}]}" about="#mwt3"></span>
1582 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a | {{ ]]"}},"i":0}}]}" about="#mwt4"></span>
1583 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a }"}},"i":0}}]}" about="#mwt5"></span></p>
1586 {{echo|<nowiki>a }} b</nowiki>}}
1587 {{echo|<nowiki>a [[ b</nowiki>}}
1588 {{echo|<nowiki>a | {{ ]]</nowiki>}}
1589 {{echo|a <nowiki>}</nowiki>}}
1593 Cases where "!!" needs nowiki protection
1598 <tr><th>this needs protection !! here</th></tr>
1602 <tr><th>this does not need
1603 protection !! here</th></tr>
1607 !<nowiki>this needs protection !! here</nowiki>
1620 Comments and Indent-Pre
1622 <!-- comment 1 --> asdf
1624 <!-- comment 1 --> asdf
1627 <!-- comment 1 --> asdf
1628 <!-- comment 2 -->xyz
1630 <!-- comment 1 --> asdf
1631 <!-- comment 2 --> xyz
1687 asdf<!-- comment 1 -->jkl
1697 <!-- foo --> b <!-- bar -->
1711 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1717 Comment semantics and delimiters
1719 <!-- --><!----><!-----><!------>
1723 <!-- --><!----><!-----><!------>
1727 Comment semantics and delimiters, redux
1729 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1730 -- foo -- funky huh? ... -->
1734 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1735 -- foo -- funky huh? ... -->
1739 Comment semantics and delimiters: directors cut
1741 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1742 everything starting with < followed by !-- until the first -- and > we see,
1743 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1749 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1750 everything starting with < followed by !-- until the first -- and > we see,
1751 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1756 Comment semantics: nesting
1758 <!--<!-- no, we're not going to do anything fancy here -->-->
1763 <!--<!-- no, we're not going to do anything fancy here --><p>--></p>
1766 # Parsoid closes the unclosed comment, even if it means a slight
1769 Comment semantics: unclosed comment at end
1771 parsoid=wt2html,html2html
1773 <!--This comment will run out to the end of the document
1777 <!--This comment will run out to the end of the document-->
1781 Comment semantics: normalize comments to play nice with XML and browsers
1783 <!-- Browsers --!> think this is closed -->
1784 <!--> This would normally be text -->
1785 <!---> As would this -->
1786 <!-- XML doesn't like trailing dashes -------->
1787 <!-- Nor doubled hyphens -- anywhere in the data -->
1788 But this is not a comment.
1790 <p>But this is not a comment.
1793 <!-- Browsers --!> think this is closed -->
1794 <!--> This would normally be text -->
1795 <!---> As would this -->
1796 <!-- XML doesn't like trailing dashes -------->
1797 <!-- Nor doubled hyphens -- anywhere in the data -->
1798 <p>But this is not a comment.</p>
1802 Comment semantics: round-trip even text which contains encoded -->
1804 <!-- hello & goodbye - > --> --&gt; --&xx -->
1806 <!-- hello & goodbye - > --> --&gt; --&xx -->
1810 Comment in template title
1819 Comment on its own line post-expand
1831 Comment on its own line post-expand with non-significant whitespace
1843 Multiple comments should still parse as SOL-transparent
1845 parsoid=wt2html,wt2wt
1848 <!--c2--><!--c3--><!--c4-->*b
1857 <!--c2--><!--c3--><!--c4-->
1864 ### paragraph wrapping tests
1879 Block tag on one line (<div>)
1895 Block tag on one line (<blockquote>)
1897 a <blockquote>foo</blockquote>
1901 a <blockquote>foo</blockquote>
1913 Block tag on both lines (<div>)
1930 Block tag on both lines (<blockquote>)
1932 a <blockquote>foo</blockquote>
1934 b <blockquote>foo</blockquote>
1936 a <blockquote>foo</blockquote>
1937 b <blockquote>foo</blockquote>
1951 Multiple lines without block tags
1975 # Tidy strips out the empty <div> tags. Parsoid doesn't.
1976 # So, we have a separate section for Parsoid. We don't want
1977 # to mimic this stripping behavior in Parsoid. It affects
1978 # editing experience and also requires us to maintain additional
1981 Empty lines between lines with block tags
2019 <div data-parsoid='{"stx":"html"}'></div>
2022 <div data-parsoid='{"stx":"html"}'></div><p>a</p>
2025 <div data-parsoid='{"stx":"html"}'>a</div><p>b</p>
2027 <div data-parsoid='{"stx":"html"}'>b</div><p>d</p>
2030 <div data-parsoid='{"stx":"html"}'>e</div>
2033 ## PHP parser emits output which is broken
2035 Unclosed HTML p-tags should be handled properly
2048 <div data-parsoid='{"stx":"html"}'><p data-parsoid='{"stx":"html", "autoInsertedEnd":true}'>foo</p></div>
2053 ## SSS FIXME: I can come up with other scenarios where this doesn't work because
2054 ## of eager output of buffered tokens in the p-wrapper. But, I'm going to ignore
2057 1. P-wrapping should leave sol-transparent tags outside p-tags where possible
2061 a [[Category:A1]] [[Category:A2]]
2066 <link rel="mw:PageProp/Category" href="./Category:A1"/> <link rel="mw:PageProp/Category" href="./Category:A2"/> <link rel="mw:PageProp/Category" href="./Category:A3"/> <link rel="mw:PageProp/Category" href="./Category:A4"/>
2070 2. P-wrapping should leave sol-transparent tags outside p-tags where possible
2076 <link rel="mw:PageProp/Category" href="./Category:A1"/><p>a</p>
2080 ### Preformatted text
2089 And a [[Main Page|link]]
2095 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
2100 Tabs don't trigger preformatted text
2104 This is preformatted text.
2110 <pre>This is preformatted text.
2115 preformatted text.</p>
2116 <pre>This is preformatted text.
2121 Space before tab needs nowiki pre protection
2127 <nowiki> </nowiki> a
2131 Ident preformatting with inline content
2142 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
2159 Regression with preformatted in <center>
2173 Bug 52763: Preformatted in <blockquote>
2179 indented cell (no pre-wrapping!)
2189 <p> indented cell (no pre-wrapping!)
2197 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
2214 Bug 15491: <ins>/<del> in blockquote
2217 Foo <del>bar</del> <ins>baz</ins> quux
2221 <p>Foo <del>bar</del> <ins>baz</ins> quux
2227 # Note that the p-wrapping is newline sensitive, which could be
2228 # considered a bug: tidy will wrap only the 'Foo' in the example
2229 # below in a <p> tag. (see comment 23-25 of bug #6200)
2231 Bug 15491: <ins>/<del> in blockquote (2)
2233 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
2236 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
2242 <del>bar</del> <ins>baz</ins> quux</blockquote>
2246 <pre> with attributes (bug 3202)
2248 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
2250 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
2255 <pre> with width attribute (bug 3202)
2257 <pre width="8">Narrow screen goodies</pre>
2259 <pre width="8">Narrow screen goodies</pre>
2264 <pre> with forbidden attribute (bug 3202)
2266 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
2268 <pre width="8">Narrow screen goodies</pre>
2273 Entities inside <pre>
2282 <pre> with forbidden attribute values (bug 3202)
2284 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
2286 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
2291 <nowiki> inside <pre> (bug 13238)
2299 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
2307 <pre><nowiki>Foo</nowiki></pre>
2312 <nowiki> inside of #tag:pre
2314 {{#tag:pre|Foo <nowiki>→bar</nowiki>}}
2316 <pre>Foo →bar</pre>
2319 <pre about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"#tag:pre","function":"#tag"},"params":{"1":{"wt":"Foo <nowiki>&rarr;bar</nowiki>"}},"i":0}}]}'>Foo <span typeof="mw:Entity">→</span>bar</pre>
2323 <nowiki> and <pre> preference (first one wins)
2352 <pre data-parsoid='{"stx":"html","strippedNL":true}'><nowiki>
2354 <p><span typeof="mw:Placeholder" data-parsoid='{"src":"</nowiki>"}'></nowiki></span>
2357 <p><span typeof="mw:Nowiki">
2366 </pre> inside nowiki
2368 <nowiki></pre></nowiki>
2374 # Parsoid doesn't strip empty tags, like Tidy does.
2376 Empty pre; pre inside other HTML tags (bug 54946)
2378 parsoid=wt2html,wt2wt
2409 HTML pre followed by indent-pre
2419 # Note that tidy removes the empty <p> tags from the start and end.
2420 # Parsoid does not, by design.
2424 <p><pre>foo</pre></p>
2430 <p data-parsoid='{"stx":"html","autoInsertedEnd":true}'></p><pre data-parsoid='{"stx":"html"}'>foo</pre><p data-parsoid='{"autoInsertedStart":true,"stx":"html"}'></p>
2434 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
2442 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
2452 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
2464 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
2485 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
2489 {{echo| foo}}{{echo| bar}}
2494 {{echo|<!--cmt--> foo}}
2496 <!--cmt-->{{echo| foo}}
2498 {{echo|{{echo| }}bar}}
2516 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
2553 Pres with newline attributes
2558 <pre class="one two">hi</pre>
2562 two" data-parsoid='{"stx":"html"}'>hi</pre>
2566 Things that look like <pre> tags aren't treated as such
2568 Barack Obama <President> of the United States
2569 <President></President>
2571 <p>Barack Obama <President> of the United States
2572 <President></President>
2577 Handle broken pre-like tags (bug 64025)
2581 {{echo|<pre <pre>x</pre>}}
2583 <table><pre </table>
2586 <table><pre </table>
2594 <pre about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"a":{"<pre":null},"sa":{"<pre":""},"stx":"html","pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<pre <pre>x</pre>"}},"i":0}}]}'>x</pre>
2603 Parsoid: handle pre with space after attribute
2607 <pre style="width:50%;" >{{echo|foo}}</pre>
2609 <pre style="width:50%;">{{echo|foo}}</pre>
2612 <pre style="width:50%;">{{echo|foo}}</pre>
2615 # TODO / maybe: fix wt2wt for this
2617 Parsoid: Don't paragraph-wrap fosterable content
2643 Parsoid: Don't paragraph-wrap fosterable content even if table syntax is unbalanced
2671 #--------------------------------------------------------------------
2672 # Transclusion parameter whitespace stripping tests
2673 # Behavior is different for positional and named parameters
2674 #--------------------------------------------------------------------
2676 Templates: Strip leading and trailing whitespace from named-param values
2680 {{echo|1= {{echo|b}} }}
2693 <ul><li> d</li></ul>
2698 Templates: Don't strip whitespace from positional-param values
2702 {{echo|{{echo|b}} }}
2734 <ul><li> f</li></ul>
2742 Templates: Handle empty comment-and-ws-only lines correctly
2745 <!--should be ignored-->
2746 <!--should be ignored as well-->
2753 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo\n<!--should be ignored-->\n <!--should be ignored as well-->\nbar"}},"i":0}}]}'>foo <!--should be ignored--> <!--should be ignored as well--> bar</p>
2757 Templates: Handle comments in the target
2760 <!-- should be ignored -->
2764 <!-- should be ignored and spaces on next line should not trip us up (T147742) -->
2767 {{echo<!-- should be ignored -->
2770 {{echo<!-- should be ignored -->|foo}}
2772 {{<!-- should be ignored -->echo|foo}}
2781 <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>
2783 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n ","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2785 <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>
2787 <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>
2789 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2793 Templates: Handle comments in parameter names (bug 67657)
2796 <!-- should be ignored -->
2800 <!-- should be ignored -->
2803 {{echo|1<!-- should be ignored -->=foo}}
2805 {{echo|<!-- should be ignored -->1=foo}}
2813 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"1\n<!-- should be ignored -->"}}},"i":0}}]}'>foo</p>
2815 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"<!-- should be ignored -->\n1"}}},"i":0}}]}'>foo</p>
2817 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"1<!-- should be ignored -->"}}},"i":0}}]}'>foo</p>
2819 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo","key":{"wt":"<!-- should be ignored -->1"}}},"i":0}}]}'>foo</p>
2823 Templates: Other wikitext in parameter names (bug 67657)
2830 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"''1''":{"wt":"foo"}},"i":0}}]}'>{{{1}}}</p>
2833 #--------------------------------------------------------------------
2834 # Transclusion parameter escaping tests
2835 #--------------------------------------------------------------------
2837 Templates: Parsoid parameter escaping test 1
2839 {{echo|[foo]|{{echo|[bar]}}}}
2843 <p about="#mwt1" typeof="mw:Transclusion"
2844 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}}]}'>[foo]</p>
2848 Parsoid: Pipes in external links in template parameter
2850 {{echo|[{{echo|http://example.com}} link]}}
2852 <p><a rel="nofollow" class="external text" href="http://example.com">link</a></p>
2854 <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>
2858 Parsoid: pipe in transclusion parameter
2860 {{echo|http://foo.com/a|b}}
2862 <p><a rel="nofollow" class="external free" href="http://foo.com/a%7Cb">http://foo.com/a%7Cb</a></p>
2864 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2865 typeof="mw:Transclusion"
2866 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>
2870 Parsoid: Pipe in external link target and content in template parameter
2872 parsoid=html2wt,wt2wt
2874 {{echo|[http://foo.com/a|b a|b]}}
2876 <p><a rel="nofollow" class="external text" href="http://foo.com/a%7Cb">a|b</a></p>
2878 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2879 typeof="mw:Transclusion"
2880 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},
2881 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}}]}'>a|b</a></p>
2885 Parsoid: Pipe in template with nested template in external link target in template parameter (seriously)
2889 {{echo|[{{fullurl:{{FULLPAGENAME}}|action=edit}} bar]}}
2891 <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>
2895 Templates: Don't escape already nowiki-escaped text in template parameters
2897 parsoid=html2wt,wt2wt
2899 {{echo|foo<nowiki>|</nowiki>bar}}
2900 {{echo|<nowiki><div></nowiki>}}
2901 {{echo|<nowiki></nowiki>}}
2903 <p>foo|bar <div></p>
2905 <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>
2906 <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>
2907 <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>
2913 Templates: '=' char in nested transclusions should not trigger nowiki escapes or conversion to named param
2915 parsoid=html2wt,wt2wt
2917 {{echo|{{echo|1=bar}}}}
2921 <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>
2926 Templates parameters with special tokenizing behavior dont get modified because of arg escaping
2932 <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:DisplaySpace mw:Placeholder" data-parsoid='{"isDisplayHack":true}'> </span>: b</p>
2937 Templates: Preserve blank parameter names
2943 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"":{"wt":"foo"}},"i":0}}]}'>{{{1}}}</p>
2947 Templates: Preserve blank parameter names in other positions
2949 {{blank_param|bar|=foo}}
2953 <p about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"},{"k":"","named":true}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"blank_param","href":"./Template:Blank_param"},"params":{"1":{"wt":"bar"},"":{"wt":"foo"}},"i":0}}]}'>bar
2958 ### Parsoid-centric tests for testing RT edge cases for pre
2962 1a. Indent-Pre and Comments
2975 1b. Indent-Pre and Comments
2988 1c. Indent-Pre and Comments
3001 1d. Indent-Pre and Comments
3002 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
3015 2a. Indent-Pre and tables
3036 2b. Indent-Pre and tables
3052 2c. Indent-Pre and tables (bug 42252)
3069 2d. Indent-Pre and tables
3086 <tbody><tr><td> b</td></tr>
3091 2e. Indent-Pre and table-line syntax
3104 2f. Indent-pre started by table-line syntax
3123 2g. Indented table markup mixed with indented pre content (proposed in bug 6200)
3128 Text that should be rendered preformatted
3136 <pre>Text that should be rendered preformatted
3145 3a. Indent-Pre and block tags (single-line html)
3149 c <blockquote> foo </blockquote>
3154 c <blockquote> foo </blockquote>
3155 <pre><span> foo </span>
3158 <p>a </p><p data-parsoid='{"stx":"html"}'> foo </p>
3159 <p>b </p><div data-parsoid='{"stx":"html"}'> foo </div>
3160 <p>c </p><blockquote data-parsoid='{"stx":"html"}'> foo </blockquote>
3161 <pre><span> foo </span>
3178 3b. Indent-Pre and block tags (multi-line html)
3183 <pre>a <span>foo</span>
3188 <pre>a <span data-parsoid='{"stx":"html"}'>foo</span></pre>
3189 b <div data-parsoid='{"stx":"html"}'> foo </div>
3199 3c. Indent-Pre and block tags (pre-content on separate line)
3263 4. Indent-Pre and extension tags
3274 a <pre typeof="mw:Extension/tag" about="#mwt2" data-parsoid='{}' data-mw='{"name":"tag","attrs":{},"body":null}'></pre>
3278 Render paragraphs when indent-pre is suppressed in blocklevels
3295 4. Multiple spaces at start-of-line
3313 ## NOTE: the leading white-space chars on empty line are significant
3315 5a. White-space in indent-pre
3327 ## NOTE: the leading white-space chars on empty line are significant
3329 5b. White-space in indent-pre
3348 5c. White-space in indent-pre
3361 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
3384 7a. Indent-pre and category links
3386 parsoid=wt2html,wt2wt
3388 [[Category:foo]] <!-- No pre-wrapping -->
3389 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
3392 <link rel="mw:PageProp/Category" href="./Category:Foo"> <!-- No pre-wrapping -->
3393 <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":" [[Category:foo]]"}},"i":0}}]}'> </span><link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1"> <!-- No pre-wrapping -->
3396 ## We used to, but no longer wt2wt this test since the default serializer
3397 ## will normalize all categories to serialize on their own line.
3398 ## This wikitext usage is going to be fairly uncommon in production and
3399 ## selser will take care of preserving formatting in those scenarios.
3401 7b. Indent-pre and category links
3406 [[Category:foo]] {{echo|b}}
3408 <pre><link rel="mw:PageProp/Category" href="./Category:Foo"> a
3409 <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>
3413 Indent-Pre: Newlines in comments shouldn't affect sol state
3427 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
3431 HTML-pre: 1. embedded newlines
3466 <pre data-parsoid='{"stx":"html"}'>foo</pre>
3468 <pre data-parsoid='{"stx":"html","strippedNL":"\n"}'>
3472 <pre data-parsoid='{"stx":"html"}'>
3477 <pre data-parsoid='{"stx":"html"}'>
3485 HTML-pre: big spaces
3521 <pre data-parsoid='{"stx":"html"}'>
3540 HTML-pre: 2: indented text
3553 HTML-pre: 3: other wikitext
3572 <pre data-parsoid='{"stx":"html","strippedNL":true}'>* foo
3581 ### Definition lists
3588 <dl><dt> name </dt>
3589 <dd> Definition</dd></dl>
3594 Definition list for indentation only
3598 <dl><dd> Indented text</dd></dl>
3603 Definition list with no space
3608 <dd>Definition</dd></dl>
3613 Definition list with URL link
3615 ; http://example.com/ : definition
3617 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt>
3618 <dd> definition</dd></dl>
3623 Definition list with bracketed URL link
3625 ;[http://www.example.com/ Example]:Something about it
3627 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt>
3628 <dd>Something about it</dd></dl>
3633 Definition list with wikilink containing colon
3635 ; [[Help:FAQ]]: The least-read page on Wikipedia
3637 <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>
3638 <dd> The least-read page on Wikipedia</dd></dl>
3642 # At Brion's and JeLuF's insistence... :)
3644 Definition list with news link containing colon
3646 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
3648 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt>
3649 <dd> This isn't even a real newsgroup!</dd></dl>
3652 <dl><dt> <a rel="mw:ExtLink" href="news:alt.wikipedia.rox" data-parsoid='{"stx":"url"}'>news:alt.wikipedia.rox</a></dt><dd data-parsoid='{"stx":"row"}'> This isn't even a real newsgroup!</dd></dl>
3656 Malformed definition list with colon
3658 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
3660 <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>
3665 Definition lists: colon in external link text
3667 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
3669 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt>
3670 <dd> OK, I made that up</dd></dl>
3675 Definition lists: colon in HTML attribute
3677 ;<b style="display: inline">bold</b>
3679 <dl><dt><b style="display: inline">bold</b></dt></dl>
3684 Definition lists: self-closed tag
3686 ;one<br/>two : two-line fun
3688 <dl><dt>one<br />two </dt>
3689 <dd> two-line fun</dd></dl>
3694 Bug 11748: Literal closing tags
3698 <dd>test test test test test</dd>
3700 <dd>test test test test test</dd>
3705 <dd>test test test test test</dd>
3707 <dd>test test test test test</dd>
3713 Definition and unordered list using wiki syntax nested in unordered list using html tags.
3716 ; term : description
3721 <dl><dt> term </dt>
3722 <dd> description</dd></dl>
3723 <ul><li> unordered</li></ul>
3729 Definition list with empty definition and following paragraph
3741 Nested definition lists using html syntax
3754 Definition Lists: No nesting: Multiple dd's
3767 Definition Lists: Indentation: Regular
3775 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3780 Definition Lists: Indentation: Missing 1st level
3786 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
3791 Definition Lists: Indentation: Multi-level indent
3795 <dl><dd><dl><dd><dl><dd>i3</dd></dl></dd></dl></dd></dl>
3800 Definition Lists: Hacky use to indent tables
3807 should be left alone
3809 <dl><dd><dl><dd><table>
3814 </td></tr></table></dd></dl></dd></dl>
3816 should be left alone
3821 Definition Lists: Hacky use to indent tables, with comments (bug 63979)
3829 should be left alone
3832 <dl><dd><dl><dd><table><tr>
3835 </tr></table><!-- bar --></dd></dl></dd></dl>
3837 should be left alone</p>
3841 Definition Lists: Hacky use to indent tables, with comment before table
3847 <dl><dd><dl><dd><!-- foo --><table><tr>
3849 </tr></table></dd></dl></dd></dl>
3852 # The trailing whitespace in this test is to catch a regression in
3853 # Parsoid after T54473.
3855 Definition Lists: Hacky use to indent tables (WS-insensitive)
3864 </td></tr></table></dd></dl>
3868 <tbody><tr><td>a</td></tr>
3869 </tbody></table> </dd></dl>
3872 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
3873 ## as an empty dt item. It also ignores all but the last ";" when followed
3874 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
3875 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
3878 ## Ex: ";;t2 ::d2" is transformed into:
3890 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
3891 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
3902 ## All Parsoid only definition list tests have this difference.
3904 ## See also: https://phabricator.wikimedia.org/T8569
3905 ## and https://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
3908 Table / list interaction: indented table with lists in table contents
3923 <ul><li> b</li></ul>
3927 <ul><li> d</li></ul>
3928 </td></tr></table></dd></dl>
3933 Table / list interaction: lists nested in tables nested in indented lists
3956 </td></tr></table></dd></dl>
3963 Definition Lists: Nesting: Multi-level (Parsoid only)
3993 Definition Lists: Nesting: Test 2 (Parsoid only)
4020 Definition Lists: Nesting: Test 3 (Parsoid only)
4063 Definition Lists: Nesting: Test 4
4068 <dl><dd><dl><dd><dl><dt>t3</dt>
4069 <dd>d3</dd></dl></dd></dl></dd></dl>
4074 ## The Parsoid team believes the following three test exposes a
4075 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
4076 ## wrong to close the <dl> after the <dt> containing the <ul>.)
4077 ## It also exposes a "misfeature" in tidy, which doesn't like
4078 ## <dl> tags with a single <dt> child; it converts the <dt> into
4079 ## a <dd> in that case. (Parsoid leaves the <dt> alone!)
4081 Definition Lists: Mixed Lists: Test 1
4087 <dl><dd><dl><dt><ul><li> foo</li>
4088 <li> bar</li></ul></dt></dl>
4089 <dl><dt> baz</dt></dl></dd></dl>
4124 Definition Lists: Mixed Lists: Test 2
4129 <ul><li><dl><dd> d1</dd>
4130 <dd> d2</dd></dl></li></ul>
4136 Definition Lists: Mixed Lists: Test 3
4141 <ul><li><dl><dd><dl><dd><dl><dd> d1</dd>
4142 <dd> d2</dd></dl></dd></dl></dd></dl></li></ul>
4148 Definition Lists: Mixed Lists: Test 4
4153 <ul><li><dl><dt>d1 </dt>
4156 <dd>d4</dd></dl></li></ul>
4162 Definition Lists: Mixed Lists: Test 5
4168 <dl><dd> d2</dd></dl></dd></dl></li></ul>
4174 Definition Lists: Mixed Lists: Test 6
4179 <ol><li><ul><li><dl><dd>d1
4180 <dl><dd><dl><dd> d3</dd></dl></dd></dl></dd></dl></li></ul></li></ol>
4186 Definition Lists: Mixed Lists: Test 7
4191 <dl><dd><ul><li> d1</li>
4192 <li> d2</li></ul></dd></dl>
4198 Definition Lists: Mixed Lists: Test 8
4203 <dl><dd><ul><li> d1</li></ul>
4204 <dl><dd><ul><li> d2</li></ul></dd></dl></dd></dl>
4210 Definition Lists: Mixed Lists: Test 9
4214 <ul><li><dl><dt>foo </dt>
4215 <dd>bar</dd></dl></li></ul>
4221 Definition Lists: Mixed Lists: Test 10
4225 <ul><li><ol><li><dl><dt>foo </dt>
4226 <dd>bar</dd></dl></li></ol></li></ul>
4230 # The Parsoid team disagrees with the PHP parser's seemingly-random
4231 # rules regarding dd/dt on the next two tests. Parsoid is more
4232 # consistent, and recognizes the shared nesting and keeps the
4233 # still-open tags around until the nesting is complete.
4234 # (And tidy again converts <dt> to <dd> before 'bar'.)
4237 Definition Lists: Mixed Lists: Test 11
4242 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt>
4243 <dd><ul><li><dl><dt><dl><dt>bar</dt></dl></dd></dl></li></ul></dd></dl>
4244 <dl><dt>boo </dt>
4245 <dd>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
4300 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
4301 <dd data-parsoid='{"stx":"row"}'>bar</dd>
4305 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
4306 <dd data-parsoid='{"stx":"row"}'>baz</dd>
4315 # Another case where tidy converts a <dt> to a <dd> (but Parsoid doesn't).
4317 # * The test is wrong, there are two colons where there should be :;
4318 # * The PHP parser is wrong to close the <dl> after the <dt> containing the <ul>.
4320 Definition Lists: Weird Ones: Test 1
4322 *#;*::;; foo : bar (who uses this?)
4324 <ul><li><ol><li><dl><dt> foo </dt>
4325 <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>
4344 <dt>bar (who uses this?)</dt>
4376 <dt> foo<span typeof="mw:DisplaySpace mw:Placeholder" data-parsoid='{"src":" ","isDisplayHack":true}'> </span></dt>
4377 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd>
4389 Definition Lists: colons occurring in tags
4407 <dt><span>a:b</span></dt>
4434 <dl><dt>a</dt><dd data-parsoid='{"stx":"row"}'>b</dd>
4436 <dt><i data-parsoid='{"stx":"html"}'>a:b</i></dt>
4437 <dt><span data-parsoid='{"stx":"html"}'>a:b</span></dt>
4438 <dt><div data-parsoid='{"stx":"html"}'>a:b</div></dt>
4439 <dt><div data-parsoid='{"stx":"html","autoInsertedEnd":true}'>a</div></dt>
4441 <dt><span about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a:b"}},"i":0}}]}'>a:b</span></dt>
4442 <dt><i about="#mwt2" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"''a:b''"}},"i":0}}]}'>a:b</i>
4443 <dl><dt><dl><dt><i>a:b</i></dt></dl></dt></dl></dt></dl>
4447 Definition Lists: colons and tables 1
4459 </td></tr></table></dd></dl>
4463 </td></tr></table></dd></dl>
4467 # Parsoid's output (as documented below) differs from php's in this case.
4468 # This is probably a bug. If we fixup parsoid to match php's output, the
4469 # above test should pass and the below test case can be removed. It is
4470 # unclear which output is more desirable.
4473 Definition Lists: colons and tables 2
4485 </td></tr></table></dd>
4489 </td></tr></table></dd></dl>
4493 Definition Lists: template interaction
4495 ::{{definition_list}}
4498 ::{{definition_list}}
4503 <dl><dd><dl data-parsoid='{}'><dd about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[":",{"template":{"target":{"wt":"definition_list","href":"./Template:Definition_list"},"params":{},"i":0}}]}'>one</dd><span about="#mwt1">
4504 </span><dd about="#mwt1">two</dd></dl></dd></dl>
4506 <dl><dd data-parsoid='{}'>one
4507 <dl><dd about="#mwt2" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":["::",{"template":{"target":{"wt":"definition_list","href":"./Template:Definition_list"},"params":{},"i":0}},"\n:::two\n:::three"]}'>one</dd><span about="#mwt2">
4508 </span><dd about="#mwt2">two
4510 <dd>three</dd></dl></dd>
4511 <dd data-parsoid='{}'>four</dd></dl></dd></dl>
4519 External links: non-bracketed
4521 Non-bracketed: http://example.com
4523 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4527 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4529 External links: numbered
4531 Numbered: [http://example.com]
4532 Numbered: [http://example.net]
4533 Numbered: [http://example.com]
4535 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
4536 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
4537 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
4540 <p>Numbered: <a rel="mw:ExtLink" href="http://example.com"></a>
4541 Numbered: <a rel="mw:ExtLink" href="http://example.net"></a>
4542 Numbered: <a rel="mw:ExtLink" href="http://example.com"></a></p>
4546 External links: specified text
4548 Specified text: [http://example.com link]
4550 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
4555 External links: trail
4557 Linktrails should not work for external links: [http://example.com link]s
4559 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
4564 External links: dollar sign in URL
4566 http://example.com/1$2345
4568 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
4572 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4574 External links: dollar sign in URL (autonumber)
4576 [http://example.com/1$2345]
4578 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
4581 <p><a rel="mw:ExtLink" href="http://example.com/1$2345"></a></p>
4585 External links: open square bracket forbidden in URL (bug 4377)
4587 parsoid=wt2html,wt2wt,html2html
4589 http://example.com/1[2345
4591 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
4594 <p><a rel="mw:ExtLink" href="http://example.com/1">http://example.com/1</a>[2345</p>
4598 External links: open square bracket forbidden in URL (named) (bug 4377)
4600 parsoid=wt2html,html2html
4602 [http://example.com/1[2345]
4604 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
4607 <p><a rel="mw:ExtLink" href="http://example.com/1">[2345</a></p>
4610 # parsoid adds a space before the link name
4612 External links: open square bracket forbidden in URL (named) (bug 4377)
4615 [http://example.com/1 [2345]
4617 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
4622 External links: nowiki in URL link text (bug 6230)
4624 [http://example.com/ <nowiki>''example site''</nowiki>]
4626 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
4631 External links: newline forbidden in text (bug 6230 regression check)
4633 [http://example.com/ first
4636 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
4642 External links: Pipe char between url and text
4644 [http://example.com | link]
4646 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
4651 External links: protocol-relative URL in brackets
4653 [//example.com/ Test]
4655 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
4659 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
4661 External links: protocol-relative URL in brackets without text
4665 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
4668 <p><a rel="mw:ExtLink" href="//example.com"></a></p>
4672 External links: protocol-relative URL in free text is left alone
4676 <p>//example.com/Foo
4681 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
4683 foo//example.com/Foo
4685 <p>foo//example.com/Foo
4690 External links: with no contents
4692 [http://en.wikipedia.org/wiki/Foo]
4694 [[wikipedia:Foo|Bar]]
4696 [[wikipedia:Foo|<span>Bar</span>]]
4698 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/wiki/Foo">[1]</a>
4699 </p><p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo">Bar</a>
4700 </p><p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo"><span>Bar</span></a>
4703 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo"></a></p>
4704 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="wikipedia:Foo">Bar</a></p>
4705 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="wikipedia:Foo"><span>Bar</span></a></p>
4709 External links: Free with trailing punctuation
4719 http://example.com/url_with_(brackets)
4720 (http://example.com/url_without_brackets)
4721 http://example.com/url_with_entity&
4722 http://example.com/url_with_entity&
4723 http://example.com/url_with_entity&
4724 http://example.com/url_with_entity
4725 http://example.com/url_with_entity 
4726 http://example.com/url_with_entity 
4727 http://example.com/url_with_entity<
4728 http://example.com/url_with_entity<
4729 http://example.com/url_with_entity<
4731 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>,
4732 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>;
4733 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>\
4734 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>.
4735 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>:
4736 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>!
4737 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>?
4738 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4739 <a rel="nofollow" class="external free" href="http://example.com/url_with_(brackets)">http://example.com/url_with_(brackets)</a>
4740 (<a rel="nofollow" class="external free" href="http://example.com/url_without_brackets">http://example.com/url_without_brackets</a>)
4741 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity&">http://example.com/url_with_entity&</a>
4742 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity&">http://example.com/url_with_entity&</a>
4743 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity&">http://example.com/url_with_entity&</a>
4744 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a> 
4745 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a> 
4746 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a> 
4747 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><
4748 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><
4749 <a rel="nofollow" class="external free" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><
4752 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>,
4753 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>;
4754 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>\
4755 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>.
4756 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>:
4757 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>!
4758 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>?
4759 <a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)
4760 <a rel="mw:ExtLink" href="http://example.com/url_with_(brackets)">http://example.com/url_with_(brackets)</a>
4761 (<a rel="mw:ExtLink" href="http://example.com/url_without_brackets">http://example.com/url_without_brackets</a>)
4762 <a rel="mw:ExtLink" href="http://example.com/url_with_entity&">http://example.com/url_with_entity&</a>
4763 <a rel="mw:ExtLink" href="http://example.com/url_with_entity&">http://example.com/url_with_entity&</a>
4764 <a rel="mw:ExtLink" href="http://example.com/url_with_entity&">http://example.com/url_with_entity&</a>
4765 <a rel="mw:ExtLink" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span>
4766 <a rel="mw:ExtLink" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><span typeof="mw:Entity" data-parsoid='{"src":"&#xA0;","srcContent":" "}'> </span>
4767 <a rel="mw:ExtLink" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><span typeof="mw:Entity" data-parsoid='{"src":"&#160;","srcContent":" "}'> </span>
4768 <a rel="mw:ExtLink" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><span typeof="mw:Entity" data-parsoid='{"src":"&lt;","srcContent":"<"}'><</span>
4769 <a rel="mw:ExtLink" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><span typeof="mw:Entity" data-parsoid='{"src":"&#x3C;","srcContent":"<"}'><</span>
4770 <a rel="mw:ExtLink" href="http://example.com/url_with_entity">http://example.com/url_with_entity</a><span typeof="mw:Entity" data-parsoid='{"src":"&#60;","srcContent":"<"}'><</span></p>
4774 External links: tricky Parsoid html2html case
4776 parsoid=wt2html,wt2wt,html2html
4778 http://example.com/url_with_entity&amp;
4780 <p><a rel="nofollow" class="external free" href="http://example.com/url_with_entity&amp">http://example.com/url_with_entity&amp</a>;
4783 <p><a rel="mw:ExtLink" href="http://example.com/url_with_entity&amp">http://example.com/url_with_entity&amp</a>;</p>
4787 External links: Free with trailing quotes (T113666)
4789 '''News:''' Stuff here
4793 <p><b>News:</b> Stuff here
4794 </p><p><a rel="nofollow" class="external free" href="news:'a'b">news:'a'b</a><i>c</i>d e
4797 <p><b>News:</b> Stuff here</p>
4798 <p><a rel="mw:ExtLink" href="news:'a'b">news:'a'b</a><i>c</i>d e</p>
4802 External links: Lone protocols are never linked (T105697)
4821 External links: No preceding word characters allowed (bug 65278)
4823 NOPEhttp://example.com
4824 N0http://example.com
4825 ok:http://example.com
4826 ok-http://example.com
4828 <p>NOPEhttp://example.com
4829 N0http://example.com
4830 ok:<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4831 ok-<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4836 External links: nofollow domain exception
4838 A [https://no-nofollow.org/foobar link], and another [https://example.org link].
4840 <p>A <a class="external text" href="https://no-nofollow.org/foobar">link</a>, and another <a rel="nofollow" class="external text" href="https://example.org">link</a>.
4847 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4849 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png"/>
4854 External image from https
4856 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4858 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png"/>
4863 External image (when not allowed)
4865 wgAllowExternalImages=0
4867 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
4869 <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>
4874 Link to non-http image, no img tag
4876 Link to non-http image, no img tag: ftp://example.com/test.jpg
4878 <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>
4883 External links: terminating separator
4885 Terminating separator: http://example.com/thing,
4887 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
4892 External links: intervening separator
4894 Intervening separator: http://example.com/1,2,3
4896 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
4901 External links: old bug with URL in query
4903 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
4905 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
4910 External links: old URL-in-URL bug, mixed protocols
4912 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
4914 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
4918 # Since Parsoid is starting to emit canonical wikitext for links,
4919 # [http://example.com http://example.com] will not RT back to that
4922 External links: URL in text
4926 URL in text: [http://example.com http://example.com]
4928 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4931 <p>URL in text: <a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
4935 External links: Clickable images
4937 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
4939 <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>
4942 <p>ja-style clickable images: <a rel="mw:ExtLink" href="http://example.com"><img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" data-parsoid='{"type":"extlink"}'/></a></p>
4946 External links: raw ampersand
4948 Old & use: http://x&y
4950 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
4955 External links: encoded ampersand
4957 Old & use: http://x&y
4959 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
4962 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y">http://x&y</a></p>
4966 External links: encoded equals (bug 6102)
4968 http://example.com/?foo=bar
4970 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
4973 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a></p>
4977 ## Note that parsoid doesn't explicit mark autonumbered links, nor
4978 ## does it number them. As discussed in bug 53505, we can identify
4979 ## autonumbered links via CSS.
4983 External links: [raw ampersand]
4985 Old & use: [http://x&y]
4987 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
4990 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
4993 # note that parsoid html is identical to [raw ampersand] case; so html2wt
4994 # mode will return the [raw ampersand] wikitext
4996 External links: [encoded ampersand]
4998 parsoid=wt2html,wt2wt,html2html
5000 Old & use: [http://x&y]
5002 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
5005 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
5009 External links: [raw equals]
5011 [http://example.com/?foo=bar]
5013 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
5016 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
5019 # note that parsoid html is identical to [raw equals] case; so html2wt
5020 # mode will return the [raw equals] wikitext
5022 External links: [encoded equals] (bug 6102)
5024 parsoid=wt2html,wt2wt,html2html
5026 [http://example.com/?foo=bar]
5028 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
5031 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
5034 # xxx parsoid strips the IDN character, so the round-trip tests will
5035 # obviously fail and are disabled. --cscott
5037 External links: [IDN ignored character reference in hostname; strip it right off]
5039 parsoid=wt2html,wt2wt,html2html
5041 [http://e‌xample.com/]
5043 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
5046 <p><a rel="mw:ExtLink" href="http://example.com/"></a></p>
5049 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
5050 # Where an external link could easily circumvent the sanitization of the text of
5051 # a link like this (where an IDN-ignore character is in the URL somewhere), this
5052 # test demands a higher standard. That's a bit strange.
5056 # http://example.com -> [http://example.com|http://example.com]
5057 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
5059 # The first example is sanitized, but the second is not. Any security benefits
5060 # from this production are trivial to circumvent. Either remove this test and
5061 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
5062 # the test accordingly.
5066 # xxx parsoid strips the IDN character, so the round-trip tests will
5067 # obviously fail and are disabled. --cscott
5069 External links: IDN ignored character reference in hostname; strip it right off
5071 parsoid=wt2html,html2html
5073 http://e‌xample.com/
5075 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
5078 <p><a rel="mw:ExtLink" href="http://example.com/">http://example.com/</a></p>
5082 External links: www.jpeg.org (bug 554)
5086 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
5090 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
5092 External links: URL within URL (original bug 2)
5094 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
5096 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
5099 <p><a rel="mw:ExtLink" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp"></a></p>
5103 BUG 361: URL inside bracketed URL
5105 [http://www.example.com/foo http://www.example.com/bar]
5107 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
5112 BUG 361: URL within URL, not bracketed
5114 http://www.example.com/foo?=http://www.example.com/bar
5116 <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>
5121 BUG 289: ">"-token in URL-tail
5123 http://www.example.com/<hello>
5125 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
5130 BUG 289: literal ">"-token in URL-tail
5132 http://www.example.com/<b>html</b>
5134 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
5137 <p><a rel="mw:ExtLink" href="http://www.example.com/" data-parsoid='{"stx":"url"}'>http://www.example.com/</a><b data-parsoid='{"stx":"html"}'>html</b></p>
5141 BUG 289: ">"-token in bracketed URL
5143 [http://www.example.com/<hello> stuff]
5145 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
5150 BUG 289: literal ">"-token in bracketed URL
5152 [http://www.example.com/<b>html</b> stuff]
5154 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
5159 BUG 289: literal double quote at end of URL
5161 http://www.example.com/"hello"
5163 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
5168 BUG 289: literal double quote in bracketed URL
5170 [http://www.example.com/"hello" stuff]
5172 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
5177 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
5179 [http://www.example.com test]
5181 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
5186 External links: link text with spaces
5188 [http://www.example.com a b c]
5189 [http://www.example.com ''a'' ''b'']
5191 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
5192 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
5197 External links: wiki links within external link (Bug 3695)
5199 parsoid=wt2html,html2html
5201 [http://example.com [[wikilink]] embedded in ext link]
5203 <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>
5206 <p><a rel="mw:ExtLink" href="http://example.com"></a><a rel="mw:WikiLink" href="./Wikilink" title="Wikilink">wikilink</a><span> embedded in ext link</span></p>
5210 BUG 787: Links with one slash after the url protocol are invalid
5214 [http:/example.com title]
5216 <p>http:/example.com
5217 </p><p>[http:/example.com title]
5222 Bracketed external links with template-generated invalid target
5224 [{{echo|http:/example.com}} title]
5226 <p>[http:/example.com title]
5231 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
5233 ''[http://example.com text'']
5234 [http://example.com '''text]'''
5235 ''Something [http://example.com in italic'']
5236 ''Something [http://example.com mixed''''', even bold]'''
5237 '''''Now [http://example.com both''''']
5239 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
5240 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
5241 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
5242 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
5243 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
5249 Bug 4781: %26 in URL
5251 http://www.example.com/?title=AT%26T
5253 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
5256 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a></p>
5259 # According to https://www.w3.org/TR/2011/WD-html5-20110525/Overview.html#parsing-urls a plain
5260 # % is actually legal in HTML5. Any change in output would need testing though.
5262 Bug 4781, 5267: %25 in URL
5264 http://www.example.com/?title=100%25_Bran
5266 <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>
5269 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a></p>
5273 Bug 4781, 5267: %28, %29 in URL
5275 http://www.example.com/?title=Ben-Hur_%281959_film%29
5277 <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>
5280 <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>
5285 Bug 4781: %26 in autonumber URL
5287 [http://www.example.com/?title=AT%26T]
5289 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
5292 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T"></a></p>
5296 Bug 4781, 5267: %26 in autonumber URL
5298 [http://www.example.com/?title=100%25_Bran]
5300 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
5303 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran"></a></p>
5307 Bug 4781, 5267: %28, %29 in autonumber URL
5309 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
5311 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
5314 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29"></a></p>
5319 Bug 4781: %26 in bracketed URL
5321 [http://www.example.com/?title=AT%26T link]
5323 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
5326 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">link</a></p>
5330 Bug 4781, 5267: %25 in bracketed URL
5332 [http://www.example.com/?title=100%25_Bran link]
5334 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
5339 Bug 4781, 5267: %28, %29 in bracketed URL
5341 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
5343 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
5346 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a></p>
5350 External link containing a period in the anchor. (bug 63947)
5352 [//foo.org/bar#baz. bang]
5354 [//foo.org/bar. bang]
5356 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
5357 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
5360 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
5361 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
5365 External link containing a single quote. (bug 63947)
5369 [//foo.org/bar'baz bang]
5371 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
5372 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
5375 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
5376 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
5380 External link containing double-single-quotes in text '' (bug 4598 sanity check)
5382 Some [http://example.com/ pretty ''italics'' and stuff]!
5384 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
5389 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
5391 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
5393 <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>
5398 External link containing double-single-quotes with no space separating the url from text in italics
5400 [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]].]
5402 <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>
5405 <p><a rel="nofollow" class="external text" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de</a> <a href="/index.php?title=Museo_Picasso_(Par%C3%ADs)&action=edit&redlink=1" class="new" title="Museo Picasso (París) (page does not exist)">Museo Picasso</a>.</p>
5407 <p><a rel="mw:ExtLink" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de </a><a rel="mw:WikiLink" href="./Museo_Picasso_(París)" title="Museo Picasso (París)">Museo Picasso</a><span>.</span></p>
5411 External link with comments in link text
5413 [http://www.google.com Google <!-- comment -->]
5415 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
5418 <p><a rel="mw:ExtLink" href="http://www.google.com">Google <!-- comment --></a></p>
5422 External link to bare IPv4 address
5424 [http://192.168.0.1 Link]
5426 <p><a rel="nofollow" class="external text" href="http://192.168.0.1">Link</a>
5429 <p><a rel="mw:ExtLink" href="http://192.168.0.1">Link</a></p>
5433 URL-encoding in URL functions (single parameter)
5435 {{localurl:Some page|amp=&}}
5437 <p>/index.php?title=Some_page&amp=&
5442 URL-encoding in URL functions (multiple parameters)
5444 {{localurl:Some page|q=?&=&}}
5446 <p>/index.php?title=Some_page&q=?&amp=&
5453 http://example.com/index.php?foozoid%5B%5D=bar
5455 http://example.com/index.php?foozoid[]=bar
5457 <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>
5458 </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>
5461 <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>
5463 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid[]=bar">http://example.com/index.php?foozoid[]=bar</a></p>
5467 IPv6 urls, autolink format (T23261)
5469 http://[2404:130:0:1000::187:2]/index.php
5471 Examples from RFC 2373, section 2.2:
5472 * http://[1080::8:800:200C:417A]/unicast
5473 * http://[FF01::101]/multicast
5474 * http://[::1]/loopback
5475 * http://[::]/unspecified
5476 * http://[::13.1.68.3]/ipv4compat
5477 * http://[::FFFF:129.144.52.38]/ipv4compat
5479 Examples from RFC 2732, section 2:
5480 * http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html
5481 * http://[1080:0:0:0:8:800:200C:417A]/index.html
5482 * http://[3ffe:2a00:100:7031::1]
5483 * http://[1080::8:800:200C:417A]/foo
5484 * http://[::192.9.5.5]/ipng
5485 * http://[::FFFF:129.144.52.38]:80/index.html
5486 * http://[2010:836B:4179::836B:4179]
5489 <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>
5490 </p><p>Examples from <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc2373">RFC 2373</a>, section 2.2:
5492 <ul><li> <a rel="nofollow" class="external free" href="http://[1080::8:800:200C:417A]/unicast">http://[1080::8:800:200C:417A]/unicast</a></li>
5493 <li> <a rel="nofollow" class="external free" href="http://[FF01::101]/multicast">http://[FF01::101]/multicast</a></li>
5494 <li> <a rel="nofollow" class="external free" href="http://[::1]/loopback">http://[::1]/loopback</a></li>
5495 <li> <a rel="nofollow" class="external free" href="http://[::]/unspecified">http://[::]/unspecified</a></li>
5496 <li> <a rel="nofollow" class="external free" href="http://[::13.1.68.3]/ipv4compat">http://[::13.1.68.3]/ipv4compat</a></li>
5497 <li> <a rel="nofollow" class="external free" href="http://[::FFFF:129.144.52.38]/ipv4compat">http://[::FFFF:129.144.52.38]/ipv4compat</a></li></ul>
5498 <p>Examples from <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc2732">RFC 2732</a>, section 2:
5500 <ul><li> <a rel="nofollow" class="external free" href="http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html">http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html</a></li>
5501 <li> <a rel="nofollow" class="external free" href="http://[1080:0:0:0:8:800:200C:417A]/index.html">http://[1080:0:0:0:8:800:200C:417A]/index.html</a></li>
5502 <li> <a rel="nofollow" class="external free" href="http://[3ffe:2a00:100:7031::1]">http://[3ffe:2a00:100:7031::1]</a></li>
5503 <li> <a rel="nofollow" class="external free" href="http://[1080::8:800:200C:417A]/foo">http://[1080::8:800:200C:417A]/foo</a></li>
5504 <li> <a rel="nofollow" class="external free" href="http://[::192.9.5.5]/ipng">http://[::192.9.5.5]/ipng</a></li>
5505 <li> <a rel="nofollow" class="external free" href="http://[::FFFF:129.144.52.38]:80/index.html">http://[::FFFF:129.144.52.38]:80/index.html</a></li>
5506 <li> <a rel="nofollow" class="external free" href="http://[2010:836B:4179::836B:4179]">http://[2010:836B:4179::836B:4179]</a></li></ul>
5509 <p><a rel="mw:ExtLink" href="http://[2404:130:0:1000::187:2]/index.php">http://[2404:130:0:1000::187:2]/index.php</a></p>
5511 <p>Examples from <a href="//tools.ietf.org/html/rfc2373" rel="mw:ExtLink">RFC 2373</a>, section 2.2:</p>
5512 <ul><li> <a rel="mw:ExtLink" href="http://[1080::8:800:200C:417A]/unicast">http://[1080::8:800:200C:417A]/unicast</a></li>
5513 <li> <a rel="mw:ExtLink" href="http://[FF01::101]/multicast">http://[FF01::101]/multicast</a></li>
5514 <li> <a rel="mw:ExtLink" href="http://[::1]/loopback">http://[::1]/loopback</a></li>
5515 <li> <a rel="mw:ExtLink" href="http://[::]/unspecified">http://[::]/unspecified</a></li>
5516 <li> <a rel="mw:ExtLink" href="http://[::13.1.68.3]/ipv4compat">http://[::13.1.68.3]/ipv4compat</a></li>
5517 <li> <a rel="mw:ExtLink" href="http://[::FFFF:129.144.52.38]/ipv4compat">http://[::FFFF:129.144.52.38]/ipv4compat</a></li></ul>
5519 <p>Examples from <a href="//tools.ietf.org/html/rfc2732" rel="mw:ExtLink">RFC 2732</a>, section 2:</p>
5520 <ul><li> <a rel="mw:ExtLink" href="http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html">http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html</a></li>
5521 <li> <a rel="mw:ExtLink" href="http://[1080:0:0:0:8:800:200C:417A]/index.html">http://[1080:0:0:0:8:800:200C:417A]/index.html</a></li>
5522 <li> <a rel="mw:ExtLink" href="http://[3ffe:2a00:100:7031::1]">http://[3ffe:2a00:100:7031::1]</a></li>
5523 <li> <a rel="mw:ExtLink" href="http://[1080::8:800:200C:417A]/foo">http://[1080::8:800:200C:417A]/foo</a></li>
5524 <li> <a rel="mw:ExtLink" href="http://[::192.9.5.5]/ipng">http://[::192.9.5.5]/ipng</a></li>
5525 <li> <a rel="mw:ExtLink" href="http://[::FFFF:129.144.52.38]:80/index.html">http://[::FFFF:129.144.52.38]:80/index.html</a></li>
5526 <li> <a rel="mw:ExtLink" href="http://[2010:836B:4179::836B:4179]">http://[2010:836B:4179::836B:4179]</a></li></ul>
5530 IPv6 urls, bracketed format (T23261)
5532 [http://[2404:130:0:1000::187:2]/index.php test]
5534 Examples from RFC 2373, section 2.2:
5535 * [http://[1080::8:800:200C:417A] unicast]
5536 * [http://[FF01::101] multicast]
5537 * [http://[::1]/ loopback]
5538 * [http://[::] unspecified]
5539 * [http://[::13.1.68.3] ipv4compat]
5540 * [http://[::FFFF:129.144.52.38] ipv4compat]
5542 Examples from RFC 2732, section 2:
5543 * [http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html 1]
5544 * [http://[1080:0:0:0:8:800:200C:417A]/index.html 2]
5545 * [http://[3ffe:2a00:100:7031::1] 3]
5546 * [http://[1080::8:800:200C:417A]/foo 4]
5547 * [http://[::192.9.5.5]/ipng 5]
5548 * [http://[::FFFF:129.144.52.38]:80/index.html 6]
5549 * [http://[2010:836B:4179::836B:4179] 7]
5552 <p><a rel="nofollow" class="external text" href="http://[2404:130:0:1000::187:2]/index.php">test</a>
5553 </p><p>Examples from <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc2373">RFC 2373</a>, section 2.2:
5555 <ul><li> <a rel="nofollow" class="external text" href="http://[1080::8:800:200C:417A]">unicast</a></li>
5556 <li> <a rel="nofollow" class="external text" href="http://[FF01::101]">multicast</a></li>
5557 <li> <a rel="nofollow" class="external text" href="http://[::1]/">loopback</a></li>
5558 <li> <a rel="nofollow" class="external text" href="http://[::]">unspecified</a></li>
5559 <li> <a rel="nofollow" class="external text" href="http://[::13.1.68.3]">ipv4compat</a></li>
5560 <li> <a rel="nofollow" class="external text" href="http://[::FFFF:129.144.52.38]">ipv4compat</a></li></ul>
5561 <p>Examples from <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc2732">RFC 2732</a>, section 2:
5563 <ul><li> <a rel="nofollow" class="external text" href="http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html">1</a></li>
5564 <li> <a rel="nofollow" class="external text" href="http://[1080:0:0:0:8:800:200C:417A]/index.html">2</a></li>
5565 <li> <a rel="nofollow" class="external text" href="http://[3ffe:2a00:100:7031::1]">3</a></li>
5566 <li> <a rel="nofollow" class="external text" href="http://[1080::8:800:200C:417A]/foo">4</a></li>
5567 <li> <a rel="nofollow" class="external text" href="http://[::192.9.5.5]/ipng">5</a></li>
5568 <li> <a rel="nofollow" class="external text" href="http://[::FFFF:129.144.52.38]:80/index.html">6</a></li>
5569 <li> <a rel="nofollow" class="external text" href="http://[2010:836B:4179::836B:4179]">7</a></li></ul>
5572 <p><a rel="mw:ExtLink" href="http://[2404:130:0:1000::187:2]/index.php">test</a></p>
5574 <p>Examples from <a href="//tools.ietf.org/html/rfc2373" rel="mw:ExtLink">RFC 2373</a>, section 2.2:</p>
5575 <ul><li> <a rel="mw:ExtLink" href="http://[1080::8:800:200C:417A]">unicast</a></li>
5576 <li> <a rel="mw:ExtLink" href="http://[FF01::101]">multicast</a></li>
5577 <li> <a rel="mw:ExtLink" href="http://[::1]/">loopback</a></li>
5578 <li> <a rel="mw:ExtLink" href="http://[::]">unspecified</a></li>
5579 <li> <a rel="mw:ExtLink" href="http://[::13.1.68.3]">ipv4compat</a></li>
5580 <li> <a rel="mw:ExtLink" href="http://[::FFFF:129.144.52.38]">ipv4compat</a></li></ul>
5582 <p>Examples from <a href="//tools.ietf.org/html/rfc2732" rel="mw:ExtLink">RFC 2732</a>, section 2:</p>
5583 <ul><li> <a rel="mw:ExtLink" href="http://[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html">1</a></li>
5584 <li> <a rel="mw:ExtLink" href="http://[1080:0:0:0:8:800:200C:417A]/index.html">2</a></li>
5585 <li> <a rel="mw:ExtLink" href="http://[3ffe:2a00:100:7031::1]">3</a></li>
5586 <li> <a rel="mw:ExtLink" href="http://[1080::8:800:200C:417A]/foo">4</a></li>
5587 <li> <a rel="mw:ExtLink" href="http://[::192.9.5.5]/ipng">5</a></li>
5588 <li> <a rel="mw:ExtLink" href="http://[::FFFF:129.144.52.38]:80/index.html">6</a></li>
5589 <li> <a rel="mw:ExtLink" href="http://[2010:836B:4179::836B:4179]">7</a></li></ul>
5593 Non-extlinks in brackets
5602 [{{echo|foo}} ''bar'']
5603 [{{echo|foo}}l's] errand
5604 [{{echo|foo}}l's errand]
5606 [url=http://example.com]
5607 [http:// bare protocols don't count]
5620 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
5621 [http:// bare protocols don't count]
5629 [<span typeof="mw:Placeholder" data-parsoid='{"src":"{{echo|foo}}"}'>foo</span>]
5630 [<span typeof="mw:Placeholder" data-parsoid='{"src":"{{echo|foo}}"}'>foo</span> bar]
5631 [<span typeof="mw:Placeholder" data-parsoid='{"src":"{{echo|foo}}"}'>foo</span> <i>bar</i>]
5632 [<span typeof="mw:Placeholder" data-parsoid='{"src":"{{echo|foo}}l's"}'>fool's</span>] errand
5633 [<span typeof="mw:Placeholder" data-parsoid='{"src":"{{echo|foo}}l's"}'>fool's</span> errand]
5634 [<span typeof="mw:Placeholder" data-parsoid='{"src":"url={{echo|foo}}"}'>url=foo</span>]
5635 [url=<a rel="mw:ExtLink" href="http://example.com">http://example.com</a>]
5636 [http:// bare protocols don't count]</p>
5640 Percent encoding in external links
5642 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
5644 <p><a rel="nofollow" class="external text" href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a>
5647 <p><a rel="mw:ExtLink"
5648 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
5652 Use url link syntax for links where the content is equal the link target
5656 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
5659 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
5663 Parenthesis in external links, especially URL links
5667 http://example.com/test)
5669 http://example.com/(test)
5671 http://example.com/((test)
5673 (http://example.com/(test))
5675 (http://example.com/(test)))))
5677 http://example.com/a)b
5679 [http://example.com) foo]
5681 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
5682 </p><p><a rel="nofollow" class="external free" href="http://example.com/test">http://example.com/test</a>)
5683 </p><p><a rel="nofollow" class="external free" href="http://example.com/(test)">http://example.com/(test)</a>
5684 </p><p><a rel="nofollow" class="external free" href="http://example.com/((test)">http://example.com/((test)</a>
5685 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test))">http://example.com/(test))</a>
5686 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test)))))">http://example.com/(test)))))</a>
5687 </p><p><a rel="nofollow" class="external free" href="http://example.com/a)b">http://example.com/a)b</a>
5688 </p><p><a rel="nofollow" class="external text" href="http://example.com)">foo</a>
5691 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)</p>
5692 <p><a rel="mw:ExtLink" href="http://example.com/test">http://example.com/test</a>)</p>
5693 <p><a rel="mw:ExtLink" href="http://example.com/(test)">http://example.com/(test)</a></p>
5694 <p><a rel="mw:ExtLink" href="http://example.com/((test)">http://example.com/((test)</a></p>
5695 <p>(<a rel="mw:ExtLink" href="http://example.com/(test))">http://example.com/(test))</a></p>
5696 <p>(<a rel="mw:ExtLink" href="http://example.com/(test)))))">http://example.com/(test)))))</a></p>
5697 <p><a rel="mw:ExtLink" href="http://example.com/a)b">http://example.com/a)b</a></p>
5698 <p><a rel="mw:ExtLink" href="http://example.com)">foo</a></p>
5702 Parenthesis in external links, w/ transclusion or comment
5704 (http://example.com/{{echo|hi}})
5706 (http://example.com<!-- hi -->)
5708 <p>(<a rel="nofollow" class="external free" href="http://example.com/hi">http://example.com/hi</a>)
5709 </p><p>(<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
5712 <p>(<a typeof="mw:ExpandedAttrs" about="#mwt2" rel="mw:ExtLink" href="http://example.com/hi" data-parsoid='{"stx":"url","a":{"href":"http://example.com/hi"},"sa":{"href":"http://example.com/{{echo|hi}}"}}' data-mw='{"attribs":[[{"txt":"href"},{"html":"http://example.com/<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[20,31,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"hi\"}},\"i\":0}}]}'>hi</span>"}]]}'>http://example.com/hi</a>)</p>
5714 <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>
5718 Serialize <a> tags with invalid link targets as plain text
5720 parsoid={ "modes": ["html2wt"], "suppressErrors": true }
5722 <a rel="mw:WikiLink" href="[[foo]]">text</a>
5723 <a rel="mw:WikiLink" href="[[foo]]">*text</a>
5724 <a rel="mw:WikiLink" href="[[foo]]">[[foo]]</a>
5725 <a rel="mw:WikiLink" href="[[foo]]">*a [[foo]]</a>
5728 <nowiki>*</nowiki>text
5729 <nowiki>[[foo]]</nowiki>
5730 <nowiki>*</nowiki>a <nowiki>[[foo]]</nowiki>
5734 mw:ExtLink -vs- mw:WikiLink (T94723)
5738 <a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid='{"stx":"piped","a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>Bar</a>
5739 <a rel="mw:WikiLink" href="./Foo" title="Foo">Bar</a>
5740 <a rel="mw:WikiLink" href="http://en.wikipedia.org/wiki/Foo" title="Foo">Bar</a>
5741 <a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" title="Foo">Bar</a>
5743 <a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/European_Robin">European Robin</a>
5744 <a rel="mw:WikiLink" href="http://en.wikipedia.org/wiki/European_Robin">European Robin</a>
5749 [[wikipedia:Foo|Bar]]
5750 [[wikipedia:Foo|Bar]]
5752 [[wikipedia:European_Robin|European Robin]]
5753 [[wikipedia:European_Robin|European Robin]]
5757 mw:ExtLink linking to a interwiki URL can be round-tripped losslessly (T94723)
5761 [http://en.wikipedia.org/wiki/European_Robin European Robin]
5763 THIS SECTION IS NOT USED (but Parsoid won't run the test without it)
5774 Normal text. '''Bold text.''' Normal text. ''Italic text.''
5776 Normal text. '''''Bold italic text.''''' Normal text.
5778 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
5779 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
5784 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
5785 # parser strips. The wikitext contains just the first half of the bold
5788 Unclosed and unmatched quotes
5790 '''''Bold italic text '''with bold deactivated''' in between.'''''
5792 '''''Bold italic text ''with italic deactivated'' in between.'''''
5796 ..spanning two paragraphs (should not work).'''
5798 '''Bold tag left open
5800 ''Italic tag left open
5804 <!-- Unmatching number of opening, closing tags: -->
5805 '''This year''''s election ''should'' beat '''last year''''s.
5807 ''Tom'''s car is bigger than ''Susan'''s.
5809 Plain ''italic'''s plain
5811 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
5812 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
5813 </p><p><b>Bold text..</b>
5814 </p><p>..spanning two paragraphs (should not work).
5815 </p><p><b>Bold tag left open</b>
5816 </p><p><i>Italic tag left open</i>
5818 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
5819 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
5820 </p><p>Plain <i>italic'</i>s plain
5823 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
5824 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
5825 </p><p><b>Bold text..</b>
5826 </p><p>..spanning two paragraphs (should not work).<b></b>
5827 </p><p><b>Bold tag left open</b>
5828 </p><p><i>Italic tag left open</i>
5831 <!-- Unmatching number of opening, closing tags: -->
5832 <p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
5833 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
5834 </p><p>Plain <i>italic'</i>s plain
5841 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
5844 # This should not produce <table></table> as <table><tr><td></td></tr></table>
5845 # is the bare minimum required by the spec, see:
5846 # https://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
5847 # Parsoid team replies: empty table tags are legal in HTML5
5849 A table with no data.
5862 A table with stray table end tags on start tag line (wt2html)
5866 {|style="color: red;"|}
5868 {|style="color: red;" |}
5872 {|style="color: red;"|} id="foo"
5876 {|style="color: red;" |} id="foo"
5880 <table style="color: red;"></table>
5882 <table style="color: red;">
5888 <table style="color: red;" id="foo">
5894 <table style="color: red;" id="foo">
5903 A table with no data (take 2)
5911 # A table with nothing but a caption is invalid XHTML, we might want to render
5912 # this as <p>caption</p>
5913 # Parsoid team replies: table with only a caption is legal in HTML5
5915 A table with nothing but a caption
5923 </caption><tr><td></td></tr></table>
5926 <table><caption> caption</caption></table>
5930 A table with caption with default-spaced attributes and a table row
5933 |+ style="color: red;" | caption1
5939 <caption style="color: red;"> caption1
5948 A table with captions with non-default spaced attributes and a table row
5951 |+style="color: red;"|caption2
5952 |+ style="color: red;"| caption3
5958 <caption style="color: red;">caption2
5960 <caption style="color: red;"> caption3
5969 Table td-cell syntax variations
5973 | foo bar foo || baz
5974 | style='color:red;' | baz
5975 | style='color:red;' || baz
5982 <td> foo bar foo </td>
5985 <td style="color:red;"> baz
5987 <td> style='color:red;' </td>
6015 Simple table but with multiple dashes for row wikitext
6034 Multiplication table
6036 {| border="1" cellpadding="2"
6037 |+Multiplication table
6039 ! × !! 1 !! 2 !! 3
6057 <table border="1" cellpadding="2">
6058 <caption>Multiplication table
6105 Accept "||" in table headings
6120 Accept "!!" in table data
6134 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'> Foo!! </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'></td></tr>
6139 Accept "||" in indented table headings
6149 </th></tr></table></dd></dl>
6154 Accept "!!" in templates
6168 <tbody><tr><th typeof="mw:Transclusion" about="#mwt1" data-parsoid='{"autoInsertedEnd":true,"pi":[[{"k":"1"}]]}' data-mw='{"parts":["!a ",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b!!c"}},"i":0}}]}'>a b</th><th about="#mwt1">c</th></tr>
6172 Accept "!!" in table headings after newline
6189 <p>b!!c</p></th></tr>
6194 Accept "!!" in table data of mixed wikitext / html syntax
6198 <tr><td>b!!c</td></tr>
6211 <tbody><tr><th>a</th></tr>
6212 <tr data-parsoid='{"stx":"html"}'><td data-parsoid='{"stx":"html"}'>b!!c</td></tr>
6217 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
6234 Accept "| !" at start of line in tables (ignore !-attribute)
6238 | !style="color:red" | bar
6250 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 +/-
6254 |style='color:red;'|+1
6255 |style='color:blue;'|-1
6267 <td style="color:red;">+1
6269 <td style="color:blue;">-1
6293 |rowspan=2| Cell 2, row 1 (and 2)
6304 <td rowspan="2"> Cell 2, row 1 (and 2)
6322 {| bgcolor=#ABCDEF border=2
6327 |the original table again
6335 <table bgcolor="#ABCDEF" border="2">
6343 <td>the original table again
6349 Invalid attributes in table cell (bug 1830)
6363 Table cell attributes: Pipes protected by nowikis should be treated as a plain character
6367 | title="foo<nowiki>|</nowiki>" |bar
6368 | title="foo<nowiki>|</nowiki>" bar
6375 <td title="foo|">bar
6377 <td> title="foo|" bar
6382 <tbody><tr><td title="foo">bar</td>
6383 <td title="foo|" data-parsoid='{"a":{"title":"foo|"},"sa":{"title":"foo<nowiki>|</nowiki>"},"autoInsertedEnd":true}'>bar</td>
6384 <td> title="foo<span typeof="mw:Nowiki">|</span>" bar</td></tr>
6388 # See: http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html
6389 # N.B. The "|}" to close the table is missing from the input, so parsoid's
6390 # *2wt modes will fail.
6392 Table security: embedded pipes
6394 parsoid=wt2html,html2html
6397 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
6401 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
6402 <td>]" onmouseover="alert(document.cookie)">test
6410 <td data-parsoid='{"startTagSrc":"| ","attrSepSrc":"|","autoInsertedEnd":true}'><a rel="mw:ExtLink" href="ftp://|x||"></a>" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
6414 Element attributes with double ! should not be broken up by <th>
6417 ! hi <div class="!!">ha</div> ho
6422 <th> hi <div class="!!">ha</div> ho
6427 <tbody><tr><th> hi <div class="!!" data-parsoid='{"stx":"html"}'>ha</div> ho</th></tr>
6432 ! and || in element attributes should not be parsed as <th>/<td>
6435 | <div style="color: red !important;" data-contrived="put this here ||">hi</div>
6440 <td> <div style="color: red !important;" data-contrived="put this here ||">hi</div>
6445 <tbody><tr><td> <div style="color: red !important;" data-contrived="put this here ||" data-parsoid='{"stx":"html"}'>hi</div></td></tr>
6449 # FIXME: The output seems broken. Filed as T110268.
6451 ! and || in td attributes should not be parsed as <th>/<td>
6456 | style="color: red !important;" data-contrived="put this here ||" | foo
6461 <td> style="color: red !important;" data-contrived="put this here </td>
6467 <tbody><tr><td> style="color: red !important;" data-contrived="put this here </td><td data-parsoid='{"stx_v":"row","a":{"\"":null},"sa":{"\"":""},"autoInsertedEnd":true}'> foo</td></tr>
6472 Break on | in element attribute in template
6474 parsoid=wt2html,html2html
6476 {{echo|1=<div class="hi|ho">ha</div>}}
6478 <p>ho">ha</div>
6481 <span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"ho\">ha</div>"}},"i":0}}]}'>ho">ha</span>
6485 Break on | in element attribute name in template
6487 {{echo|<div cla|ss="hiho">ha</div>}}
6489 <p about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"},{"k":"ss","named":true}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div cla"},"ss":{"wt":"\"hiho\">ha</div>"}},"i":0}}]}'><div cla</p>
6493 Don't break on | in extension attribute in template
6495 {{echo|<ref name="hi|ho">ha</ref>}}
6499 <p><span about="#mwt2" class="mw-ref" id="cite_ref-hi.7Cho_1-0" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<ref name=\"hi|ho\">ha</ref>"}},"i":0}}]}'><a href="./Main_Page#cite_note-hi.7Cho-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></p>
6501 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-hi.7Cho-1" id="cite_note-hi.7Cho-1"><a href="./Main_Page#cite_ref-hi.7Cho_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-hi.7Cho-1" class="mw-reference-text">ha</span></li></ol>
6504 ## We don't support roundtripping of these attributes in Parsoid.
6505 ## Selective serialization takes care of preventing dirty diffs.
6506 ## But, on edits, we dirty-diff the invalid attribute text.
6508 Invalid text in table attributes should be discarded
6512 {| <span>boo</span> style='border:1px solid black'
6513 | <span>boo</span> style='color:blue' | 1
6514 |<span>boo</span> style='color:blue'| 2
6517 <table style="border:1px solid black">
6519 <td style="color:blue"> 1
6521 <td style="color:blue"> 2
6525 <table style="border:1px solid black">
6527 <td style="color:blue"> 1</td>
6528 <td style="color:blue"> 2</td>
6534 Invalid text in table attributes should be preserved by selective serializer
6537 "modes": ["selser"],
6539 ["td:first-child", "text", "abc"],
6540 ["td + td", "text", "xyz"]
6544 {| <span>boo</span> style='border:1px solid black'
6545 | <span>boo</span> style='color:blue' | 1
6546 |<span>boo</span> style='color:blue'| 2
6549 {| <span>boo</span> style='border:1px solid black'
6550 | <span>boo</span> style='color:blue' |abc
6551 |<span>boo</span> style='color:blue'|xyz
6556 1. Template-generated table cell attributes and cell content
6561 || {{table_attribs_5}}
6562 | <!--foo--> <!--bar--> <!--baz--> {{table_attribs}}
6563 |align=center {{table_attribs}}
6564 | <!--foo--> align=center <!--bar--> {{table_attribs}}
6569 <td style="color:red;">Foo
6571 <td style="color:red;">Foo
6573 <td> style="color:red;"</td>
6576 <td style="color:red;">Foo
6578 <td align="center" style="color:red;">Foo
6580 <td align="center" style="color:red;">Foo
6586 2. Template-generated table cell attributes and cell content
6589 |{{table_attribs_2}}
6594 <td style="color:red;">Foo
6602 <tbody><tr><td about="#mwt1" typeof="mw:Transclusion" style="color:red;" data-mw='{"parts":["|",{"template":{"target":{"wt":"table_attribs_2","href":"./Template:Table_attribs_2"},"params":{},"i":0}}]}'>Foo</td>
6603 <td about="#mwt1">Bar</td><td about="#mwt1">Baz</td></tr>
6608 3. Template-generated table cell attributes and cell content
6611 !align=center {{table_header_cells}}
6613 |align=center {{table_cells}}
6618 <th align="center" style="color:red;">Foo</th>
6619 <th style="color:red;"><i>Bar</i></th>
6620 <th style="color:brown;"><i>Foo</i> and Baz
6623 <td align="center" style="color:red;">Foo</td>
6624 <td style="color:red;"><i>Bar</i></td>
6625 <td style="color:brown;"><i>Foo</i> and Baz
6630 <tbody><tr><th align="center" style="color:red;" typeof="mw:Transclusion" about="#mwt1" data-mw='{"parts":["!align=center ",{"template":{"target":{"wt":"table_header_cells","href":"./Template:Table_header_cells"},"params":{},"i":0}}]}'>Foo</th><th about="#mwt1" style="color:red;"><i about="#mwt1">Bar</i></th><th about="#mwt1" style="color:brown;"><i about="#mwt1">Foo</i> and Baz</th></tr><tr>
6631 <td align="center" style="color:red;" typeof="mw:Transclusion" about="#mwt1" data-mw='{"parts":["|align=center ",{"template":{"target":{"wt":"table_cells","href":"./Template:Table_cells"},"params":{},"i":0}}]}'>Foo</td><td about="#mwt1" style="color:red;"><i about="#mwt1">Bar</i></td><td about="#mwt1" style="color:brown;"><i about="#mwt1">Foo</i> and Baz</td></tr>
6636 4. Template-generated table cell attributes and cell content inside a templated table
6639 !align=center {{table_header_cells}}
6641 |align=center {{table_cells}}
6646 <th align="center" style="color:red;">Foo</th>
6647 <th style="color:red;"><i>Bar</i></th>
6648 <th style="color:brown;"><i>Foo</i> and Baz
6651 <td align="center" style="color:red;">Foo</td>
6652 <td style="color:red;"><i>Bar</i></td>
6653 <td style="color:brown;"><i>Foo</i> and Baz
6657 <table about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[],[],[],[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"tbl-start","href":"./Template:Tbl-start"},"params":{},"i":0}},"\n!align=center ",{"template":{"target":{"wt":"table_header_cells","href":"./Template:Table_header_cells"},"params":{},"i":1}},"\n|-\n|align=center ",{"template":{"target":{"wt":"table_cells","href":"./Template:Table_cells"},"params":{},"i":2}},"\n",{"template":{"target":{"wt":"tbl-end","href":"./Template:Tbl-end"},"params":{},"i":3}}]}'>
6658 <tbody><tr><th align="center" style="color:red;">Foo</th><th style="color:red;"><i>Bar</i></th><th style="color:brown;"><i>Foo</i> and Baz</th></tr>
6660 <td align="center" style="color:red;">Foo</td><td style="color:red;"><i>Bar</i></td><td style="color:brown;"><i>Foo</i> and Baz</td></tr>
6664 ## Edge case fix to prevent future regressions
6666 T107652: <ref>s in templates that also generate table cell attributes should be rendered properly
6669 |{{table_attribs_7}}
6674 <tbody><tr><td style="background:#f9f9f9;" typeof="mw:Transclusion" about="#mwt1" data-mw='{"parts":["|",{"template":{"target":{"wt":"table_attribs_7","href":"./Template:Table_attribs_7"},"params":{},"i":0}}]}'>Foo<span class="mw-ref" id="cite_ref-1" rel="dc:references" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></td></tr>
6676 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo</span></li></ol>
6680 Table with row followed by newlines and table heading
6682 parsoid=wt2html,html2html
6700 Table with empty line following the start tag
6702 parsoid=wt2html,html2html
6720 Table attributes with empty value
6722 parsoid=wt2html,html2html
6735 <tbody><tr><td style=""> hello</td></tr>
6740 Wikitext table with a lot of comments
6763 Wikitext table comments represented in parsoid dom
6765 {|<!--c1--><!--c2-->
6776 <table><!--c1--><!--c2-->
6777 <tbody><tr data-parsoid='{"startTagSrc":"|-","autoInsertedEnd":true}'><!--c3-->
6778 <td data-parsoid='{"autoInsertedEnd":true}'> x</td></tr>
6783 Wikitext table with double-line table cell
6800 Table cell with a single comment
6817 Table-cell after a comment-only-empty-line
6834 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>a</td>
6836 <!--c2--><td data-parsoid='{"autoInsertedEnd":true}'> b</td></tr>
6842 Build table with {{!}}
6844 {{{!}} class="wikitable"
6847 {{!}}- style="color:red;"
6848 {{!}} data {{!}}{{!}} style="color:red;" {{!}} second data
6851 <table class="wikitable">
6857 <tr style="color:red;">
6859 <td style="color:red;"> second data
6865 Build table with pipe as data
6867 {| class="wikitable"
6870 |- style="color:red;"
6871 | data || style="color:red;" | second data
6873 | style="color:red;" | data with | || style="color:red;" | second data with |
6875 || data with | ||| second data with |
6878 <table class="wikitable">
6884 <tr style="color:red;">
6886 <td style="color:red;"> second data
6889 <td style="color:red;"> data with | </td>
6890 <td style="color:red;"> second data with |
6893 <td> data with | </td>
6894 <td> second data with |
6900 Build table with wikilink
6902 {| class="wikitable"
6903 ! header || second header
6904 |- style="color:red;"
6905 | data [[Main Page|linktext]] || second data [[Main Page|linktext]]
6907 | data || second data [[Main Page|link|text with pipe]]
6910 <table class="wikitable">
6915 <tr style="color:red;">
6916 <td> data <a href="/wiki/Main_Page" title="Main Page">linktext</a> </td>
6917 <td> second data <a href="/wiki/Main_Page" title="Main Page">linktext</a>
6921 <td> second data <a href="/wiki/Main_Page" title="Main Page">link|text with pipe</a>
6926 # The expected HTML structure in this test is debatable. The PHP parser does
6927 # not parse this kind of table at all. The main focus for Parsoid is on
6928 # round-tripping, so this output is ok for now. TODO: revisit!
6930 Wikitext table with html-syntax row
6940 <td>foo</td></tr></tbody></table>
6943 ## Note that Parsoid output differs from PHP and PHP+tidy here.
6944 ## The lack of <tr> tags in the PHP output is arguably a bug in the
6945 ## PHP parser, which tidy then compounds by fostering the content
6946 ## entirely out of the table. Parsoid recognizes the table context
6947 ## and generates <tr> and <td> wrappers as needed. Hopefully nobody
6948 ## depends on PHP's treatment of broken table markup!
6950 Implicit <td> after a |-
6952 parsoid=wt2html,html2html
6972 # Again, Parsoid adds implicit <td>s here, PHP and Tidy strip the b out.
6974 <pre> tags should be recognized in an explicit <td> context, but not in an implicit <td> context
6976 parsoid=wt2html,html2html
7009 <tr><td><pre>a</pre></td></tr>
7010 <tr><td> b</td></tr>
7015 # PHP + Tidy strips the list out of the table; Parsoid wraps it.
7016 # Parsoid generates the missing <td>, so wt2wt won't succeed.
7018 Lists should be recognized in an implicit <td> context
7020 parsoid=wt2html,html2html
7047 Table cells not properly parsed in an implicit-td context
7051 {{table_attribs_4}} || a || b
7056 <td style="background-color:#DC241f;" width="10px"></td>
7063 <tbody><tr data-parsoid='{"startTagSrc":"|-","autoInsertedEnd":true}'>
7064 <td style="background-color:#DC241f;" width="10px" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"autoInsertedEnd":true,"pi":[[]]}' data-mw='{"parts":["",{"template":{"target":{"wt":"table_attribs_4","href":"./Template:Table_attribs_4"},"params":{},"i":0}}," "]}'> </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'> a </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'> b</td></tr>
7069 Parsoid: Round-trip tables directly followed by content (bug 51219)
7071 parsoid=wt2html,wt2wt
7096 Parsoid: Default to a newline after tables in new content (bug 51219)
7101 <tr><td>foo</td></tr></tbody></table> bar
7103 <tr><td>baz</td></tr></tbody></table><b>quux</b>
7108 <nowiki> </nowiki>bar
7116 Parsoid: newline inducing block nodes don't suppress <nowiki>
7128 Parsoid: Row-syntax table headings followed by comment & table cells
7130 parsoid=wt2html,wt2wt
7134 <!-- foo --> || baz || quux
7148 <tbody><tr><th> foo </th><th> bar
7149 <!-- foo --> </th><td> baz </td><td> quux</td></tr>
7154 Parsoid: Recover better from broken table attributes
7174 <p>foo</p></td></tr>
7179 Tables: Digest broken attributes on table and tr tag
7195 # T137406: Whitespace in the HTML
7197 1. Generate correct wikitext for tables with thead/tbody/tfoot
7202 <caption>Test</caption>
7243 <caption>Test</caption>
7263 # T137406: No whitespace in the HTML
7265 2. Generate correct wikitext for tables with thead/tbody/tfoot
7269 <table><thead><tr><th>heading</th></tr></thead><tbody><tr><td>foo</td></tr></tbody></table>
7279 Testing serialization after deletion in references
7288 hi <ref><div id="x">ho</div></ref>
7298 Testing serialization after deletion of table cells
7301 "modes": ["wt2wt", "selser"],
7309 | id="x" |c1 {{!}}{{!}}{{!}}c2 |||c3
7319 Testing selser after addition of new row before first row (T125419)
7322 "modes": ["wt2wt", "selser"],
7324 [ "tr", "before", "<tr><td>X</td></tr>" ]
7340 Serialize new table rows in a HTML table using HTML tags
7343 "modes": ["wt2wt", "selser"],
7345 [ "tr", "before", "<tr><td>X</td></tr>" ]
7349 <table><tr><td>a</td></tr></table>
7351 <table><tr><td>X</td></tr><tr><td>a</td></tr></table>
7355 Serialize new table cells in a HTML row using HTML tags
7358 "modes": ["wt2wt", "selser"],
7360 [ "td", "before", "<td>X</td>" ]
7364 <table><tr><td>a</td></tr></table>
7366 <table><tr><td>X</td><td>a</td></tr></table>
7370 Wikitext tables can be nested inside HTML tables
7374 <table data-parsoid='{"stx":"html"}'>
7377 <tr><td>foo</td></tr>
7392 Serialize wikitext list items as HTML list items when embedded in a HTML list
7396 <ul data-parsoid='{"stx": "html"}'>
7397 <li data-parsoid='{}'>a</li>
7407 # SSS FIXME: Is this actually a good thing given the
7408 # odd nested list output that is generated by MW?
7409 # <ul><li>foo<ul>..</ul></li></ul> instead of
7410 # <ul><li>foo</li><ul>..</ul></ul>
7412 Wikitext lists can be nested inside HTML lists
7416 <ul data-parsoid='{"stx": "html"}'>
7417 <li data-parsoid='{"stx": "html"}'>a
7422 <ul data-parsoid='{"stx": "html"}'>
7445 Plain link, capitalized
7449 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
7454 Plain link, uncapitalized
7458 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
7465 [[Main Page|The Main Page]]
7467 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
7472 Piped link with comment in link text
7474 [[Main Page|The Main<!--front--> Page]]
7476 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
7481 Piped link with multiple pipe characters in link text
7483 [[Main Page||The|Main|Page|]]
7485 <p><a href="/wiki/Main_Page" title="Main Page">|The|Main|Page|</a>
7488 <p><a rel="mw:WikiLink" href="Main_Page" title="Main Page">|The|Main|Page|</a></p>
7492 Piped link with no link text
7494 [[Thomas Bek (bishop of St David's)|]]
7496 <p>[[Thomas Bek (bishop of St David's)|]]
7499 <p>[[Thomas Bek (bishop of St David's)|]]</p>
7503 Piped link with empty link text
7505 [[Main Page|<nowiki />]] - empty nowiki
7506 [[Main Page| ]] - empty space
7507 [[Main Page| ]] - empty non breaking space
7509 <p><a href="/wiki/Main_Page" title="Main Page"></a> - empty nowiki
7510 <a href="/wiki/Main_Page" title="Main Page"> </a> - empty space
7511 <a href="/wiki/Main_Page" title="Main Page"> </a> - empty non breaking space
7514 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page"><meta typeof="mw:Placeholder" data-parsoid='{"src":"<nowiki />"}'/></a> - empty nowiki
7515 <a rel="mw:WikiLink" href="./Main_Page" title="Main Page"> </a> - empty space
7516 <a rel="mw:WikiLink" href="./Main_Page" title="Main Page"><span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span></a> - empty non breaking space</p>
7524 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
7529 Broken link with fragment
7531 [[Zigzagzogzagzig#zug]]
7533 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
7538 Special page link with fragment
7540 [[Special:Version#anchor]]
7542 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
7547 Nonexistent special page link with fragment
7549 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
7551 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
7558 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
7560 <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>
7567 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
7569 <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>!!!
7580 Bug 43661: Piped links with identical prefixes
7582 [[prefixed article|prefixed articles with spaces]]
7584 [[prefixed article|prefixed articlesaoeu]]
7586 [[Main Page|Main Page test]]
7588 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
7589 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
7590 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
7596 Link with HTML entity in suffix / tail
7598 [[Main Page]]", [[Main Page]]a
7600 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
7603 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a><span typeof="mw:Entity" data-parsoid='{"src":"&quot;","srcContent":"\""}'>"</span>, <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a><span typeof="mw:Entity" data-parsoid='{"src":"&#97;","srcContent":"a"}'>a</span></p>
7607 Link with 3 brackets
7618 Link with 4 brackets
7622 <p>[[<a href="/wiki/Main_Page" title="Main Page">Main Page</a>]]
7627 Piped link with 3 brackets
7629 [[[main page|the main page]]]
7631 <p>[[[main page|the main page]]]
7636 Piped link with extlink-like text
7639 [[Main Page|This is a [bar]]]
7641 <p><a href="/wiki/Main_Page" title="Main Page">[bar]</a>
7642 <a href="/wiki/Main_Page" title="Main Page">This is a [bar]</a>
7645 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page" data-parsoid='{"stx":"piped"}'>[bar]</a>
7646 <a rel="mw:WikiLink" href="./Main_Page" title="Main Page" data-parsoid='{"stx":"piped"}'>This is a [bar]</a></p>
7650 Link with multiple pipes
7652 [[Main Page|The|Main|Page]]
7654 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
7659 Anchor containing a #. (bug 63430)
7661 [[Main Page#And#Link]]
7663 <p><a href="/wiki/Main_Page#And.23Link" title="Main Page">Main Page#And#Link</a>
7666 <p><a rel="mw:WikiLink" href="./Main_Page#And.23Link" title="Main Page" data-parsoid='{"stx":"simple","a":{"href":"./Main_Page#And.23Link"},"sa":{"href":"Main Page#And#Link"}}'>Main Page#And#Link</a></p>
7672 [[Talk:Parser testing]], [[Meta:Disclaimers]]
7674 <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>
7679 Link with space in namespace
7681 [[User talk:Foo bar]]
7683 <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>
7688 MemoryAlpha:AlphaTest
7690 This is an article in the MemoryAlpha namespace
7691 (which shadows the memoryalpha interwiki link).
7695 Namespace takes precedence over interwiki link (bug 51680)
7697 [[MemoryAlpha:AlphaTest]]
7699 <p><a href="/wiki/MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
7703 # The previous test doesn't work correctly in html2*, due to not recognizing the
7704 # link as an internal one. This one checks for the correct behavior.
7706 Link to namespace preferred over interwiki with correct rel attribute
7708 parsoid=html2wt,html2html
7710 <p><a rel="mw:WikiLink" href="./MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a></p>
7712 [[MemoryAlpha:AlphaTest]]
7716 Piped link to namespace
7718 [[Meta:Disclaimers|The disclaimers]]
7720 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
7727 [[Usually caused by a typo (oops}]]
7729 <p>[[Usually caused by a typo (oops}]]
7736 Just a test of an article title containing a percent.
7740 Link containing % (not as a hex sequence)
7743 [[7% Solution|7%25 Solution]]
7745 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
7746 <a href="/wiki/7%25_Solution" title="7% Solution">7%25 Solution</a>
7749 <p><a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7% Solution</a>
7750 <a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7%25 Solution</a></p>
7753 # note that the parsoid HTML is identical to the previous test output,
7754 # so the previous test ensures that the html2wt mode will generate the
7755 # "not as a hex sequence" wikitext.
7757 Link containing % as a single hex sequence interpreted to char
7759 parsoid=wt2wt,wt2html,html2html
7762 [[7%25 Solution|7%25 Solution]]
7764 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
7765 <a href="/wiki/7%25_Solution" title="7% Solution">7%25 Solution</a>
7768 <p><a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7% Solution</a>
7769 <a rel="mw:WikiLink" href="./7%25_Solution" title="7% Solution">7%25 Solution</a></p>
7773 Link containing % as a double hex sequence interpreted to hex sequence
7777 <p>[[7%2525 Solution]]
7781 ## Example for such a section: == < ==
7783 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
7785 [[%23%3c]][[%23%3e]]
7787 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
7790 <p><a rel="mw:WikiLink" href="./Main_Page#.3C" title="Main Page" data-parsoid='{"stx":"simple","a":{"href":"./Main_Page#.3C"},"sa":{"href":"%23%3c"}}'>#<</a><a rel="mw:WikiLink" href="./Main_Page#.3E" title="Main Page" data-parsoid='{"stx":"simple","a":{"href":"./Main_Page#.3E"},"sa":{"href":"%23%3e"}}'>#></a></p>
7794 Link containing "<#" and ">#" as a hex sequences
7796 [[%3c%23]][[%3e%23]]
7798 <p>[[%3c%23]][[%3e%23]]
7803 Link containing an equals sign
7805 [[Special:BookSources/isbn=4-00-026157-6]]
7807 <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>
7810 <p><a rel="mw:WikiLink" href="./Special:BookSources/isbn=4-00-026157-6" title="Special:BookSources/isbn=4-00-026157-6">Special:BookSources/isbn=4-00-026157-6</a></p>
7816 Just a test of an article title containing a tilde.
7819 # note that links containing signatures, like [[Foo~~~~]], are
7820 # massaged by the pre-save transform (PST) and so the tildes are never
7821 # seen by the parser.
7823 Link containing a tilde
7827 <p><a href="/wiki/Foo~bar" title="Foo~bar">Foo~bar</a>
7830 <p><a rel="mw:WikiLink" href="./Foo~bar" title="Foo~bar">Foo~bar</a></p>
7834 Link containing double-single-quotes '' (bug 4598)
7836 [[Lista d''e paise d''o munno]]
7838 <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>
7841 <p><a rel="mw:WikiLink" href="./Lista_d''e_paise_d''o_munno" title="Lista d''e paise d''o munno">Lista d''e paise d''o munno</a></p>
7845 Link containing double-single-quotes '' in text (bug 4598 sanity check)
7847 Some [[Link|pretty ''italics'' and stuff]]!
7849 <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>!
7852 <p>Some <a rel="mw:WikiLink" href="Link" title="Link">pretty <i>italics</i> and stuff</a>!</p>
7856 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
7858 ''Some [[Link|pretty ''italics'' and stuff]]!''
7860 <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>
7865 Link with double quotes in title part (literal) and alternate part (interpreted)
7867 [[File:Denys_Savchenko_''Pentecoste''.jpg]]
7871 [[''Pentecoste''|Pentecoste]]
7873 [[''Pentecoste''|''Pentecoste'']]
7875 <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>
7876 </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>
7877 </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>
7878 </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>
7881 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Denys_Savchenko_''Pentecoste''.jpg"><img resource="./File:Denys_Savchenko_''Pentecoste''.jpg" src="./Special:FilePath/Denys_Savchenko_''Pentecoste''.jpg" height="220" width="220"/></a></span></p>
7882 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">''Pentecoste''</a></p>
7883 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''">Pentecoste</a></p>
7884 <p><a rel="mw:WikiLink" href="''Pentecoste''" title="''Pentecoste''"><i>Pentecoste</i></a></p>
7888 Broken image links with HTML captions (bug 39700)
7890 [[File:Nonexistent|<script></script>]]
7891 [[File:Nonexistent|100x100px|<script></script>]]
7892 [[File:Nonexistent|<]]
7893 [[File:Nonexistent|a<i>b</i>c]]
7895 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
7896 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
7897 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
7898 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
7901 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"<script></script>"}]}' data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"&lt;script>&lt;/script>"}'><a href="./File:Nonexistent" data-parsoid='{"a":{"href":"./File:Nonexistent"},"sa":{}}'><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="220" width="220" data-parsoid='{"a":{"resource":"./File:Nonexistent","height":"220","width":"220"},"sa":{"resource":"File:Nonexistent"}}'/></a></span>
7902 <span typeof="mw:Error mw:Image" data-parsoid='{"optList":[{"ck":"width","ak":"100x100px"},{"ck":"caption","ak":"<script></script>"}]}' data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"&lt;script>&lt;/script>"}'><a href="./File:Nonexistent" data-parsoid='{"a":{"href":"./File:Nonexistent"},"sa":{}}'><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="100" width="100" data-parsoid='{"a":{"resource":"./File:Nonexistent","height":"100","width":"100"},"sa":{"resource":"File:Nonexistent"}}'/></a></span>
7903 <span class="mw-default-size" typeof="mw:Error mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"&lt;"}]}' data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"<span typeof=\"mw:Entity\" data-parsoid='{\"src\":\"&amp;lt;\",\"srcContent\":\"&lt;\",\"dsr\":[107,111,null,null]}'>&lt;</span>"}'><a href="./File:Nonexistent" data-parsoid='{"a":{"href":"./File:Nonexistent"},"sa":{}}'><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="220" width="220" data-parsoid='{"a":{"resource":"./File:Nonexistent","height":"220","width":"220"},"sa":{"resource":"File:Nonexistent"}}'/></a></span>
7904 <span class="mw-default-size" typeof="mw:Error mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"a<i>b</i>c"}]}' data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"a<i data-parsoid='{\"stx\":\"html\",\"dsr\":[134,142,3,4]}'>b</i>c"}'><a href="./File:Nonexistent" data-parsoid='{"a":{"href":"./File:Nonexistent"},"sa":{}}'><img resource="./File:Nonexistent" src="./Special:FilePath/Nonexistent" height="220" width="220" data-parsoid='{"a":{"resource":"./File:Nonexistent","height":"220","width":"220"},"sa":{"resource":"File:Nonexistent"}}'/></a></span></p>
7910 [[http://www.example.com]]
7912 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
7915 <p>[<a rel="mw:ExtLink" href="http://www.example.com"></a>]</p>
7919 Plain link to URL with link text
7921 [[http://www.example.com Link text]]
7923 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
7928 Plain link to protocol-relative URL
7930 [[//www.example.com]]
7932 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
7935 <p>[<a rel="mw:ExtLink" href="//www.example.com"></a>]</p>
7939 Plain link to protocol-relative URL with link text
7941 [[//www.example.com Link text]]
7943 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
7948 Plain link to page with question mark in title
7954 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
7955 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
7960 # I'm fairly sure the expected result here is wrong.
7961 # We want these to be URL links, not pseudo-pages with URLs for titles....
7962 # However the current output is also pretty screwy.
7965 # I'm changing it to match the current output--it arguably makes more
7966 # sense in the light of the test above. Old expected result was:
7967 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
7969 # But I think this test is bordering on "garbage in, garbage out" anyway.
7974 Piped link to URL: [[http://www.example.com|an example URL]]
7976 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
7979 <p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com|an">example URL</a>]</p>
7983 BUG 2: [[page|http://url/]] should link to page, not http://url/
7985 [[Main Page|http://url/]]
7987 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
7990 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">http://url/</a></p>
7993 # Parsoid does not mark self-links, by design.
7995 BUG 337: Escaped self-links should be bold
7999 [[Bug462]] [[Bug462]]
8001 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
8004 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong></p>
8006 <p><a rel="mw:WikiLink" href="./Bug462" title="Bug462">Bug462</a> <a rel="mw:WikiLink" href="./Bug462" title="Bug462">Bug462</a></p>
8010 Self-link to section should not be bold
8014 [[Main Page#section]]
8016 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
8027 Self-link to numeric title
8033 <p><strong class="selflink">0</strong>
8038 Link to numeric-equivalent title
8044 <p><a href="/wiki/00" title="00">00</a>
8049 <nowiki> inside a link
8051 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
8053 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
8058 Non-breaking spaces in title
8060 [[ Main Page ]]
8062 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
8067 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
8073 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
8078 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
8084 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
8089 Internal link with en linktrail: no apostrophes (bug 27473)
8095 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
8100 Internal link with ca linktrail with apostrophes (bug 27473)
8106 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
8111 Internal link with kaa linktrail with apostrophes (bug 27473)
8117 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
8122 Link with multiple ":" in a subpage-supporting namespace (bug 63636)
8124 [[User:Foo/Test/63636:Bar|Test]]
8126 <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>
8129 <p><a rel="mw:WikiLink" href="./User:Foo/Test/63636:Bar" title="User:Foo/Test/63636:Bar">Test</a></p>
8132 ## Mainly a sanity check for Parsoid
8134 Handle title parsing for subpages
8154 Link to a subpage from a namespace other than main
8161 <p><a href="/wiki/User:Test/123" title="User:Test/123">/123</a>
8164 <p><a rel="mw:WikiLink" href="./User:Test/123" title="User:Test/123" data-parsoid='{"stx":"simple","a":{"href":"./User:Test/123"},"sa":{"href":"/123"}}'>/123</a></p>
8168 Ensure that transclusion titles are not url-decoded
8170 subpage title=[[Test]]
8173 {{Bar%C3%A9}} {{/Bar%C3%A9}}
8175 <p>{{Bar%C3%A9}} {{/Bar%C3%A9}}
8178 <p>{{Bar%C3%A9}} {{/Bar%C3%A9}}</p>
8182 Purely hash wikilink
8184 title=[[User:Test/123]]
8189 <p><a href="#a">b</a>
8192 <p><a rel="mw:WikiLink" href="./User:Test/123#a" data-parsoid='{"stx":"piped","a":{"href":"./User:Test/123#a"},"sa":{"href":"#a"}}'>b</a></p>
8196 1. Interaction of linktrail and template encapsulation
8202 <p><a rel="mw:WikiLink" href="Foo" title="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
8206 2. Interaction of linktrail and template encapsulation
8210 {{echo|Some [[Fool]]}}s
8212 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]"}},"i":0}},"s"]}' data-parsoid='{"pi":[[{"k":"1"}]]}'>Some </span><a rel="mw:WikiLink" href="./Fool" title="Fool" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a></p>
8216 3. Interaction of linktrail and template encapsulation
8220 {{echo|Some [[Fool]]s are '''bold and foolish'''}}
8222 <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"}]]}'>Some <a rel="mw:WikiLink" href="./Fool" title="Fool" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a> are <b>bold and foolish</b></p>
8232 Internal link with is link prefix
8236 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
8238 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
8249 Internal link with is link trail and link prefix
8253 [[mótmælendatrú|xxx]]ar
8255 mótmælenda[[söfnuður]]
8256 mótmælenda[[söfnuður|söfnuðir]]
8257 mótmælenda[[söfnuður|söfnuðir]]xxx
8259 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
8260 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
8261 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
8262 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
8263 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
8268 Parsoid link trail escaping
8270 parsoid=html2wt,html2html
8272 <p><a rel="mw:WikiLink" href="Apple" title="Apple">apple</a>s</p>
8278 Parsoid link prefix escaping
8281 parsoid=html2wt,html2html
8283 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður" title="Söfnuður">söfnuður</a></p>
8285 Aðrir mótmælenda<nowiki/>[[söfnuður]]
8289 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
8297 [http://wp.org ''foo'']
8299 <p><a href="/wiki/Foo" title="Foo"> bar</a>
8300 </p><p><a href="/wiki/Foo" title="Foo"> <i>bar</i></a>
8301 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
8302 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
8307 Parsoid: Scoped parsing should handle mixed transclusions and plain text
8311 [[Foo|{{echo|a}} b {{echo|c}}]]
8313 <p><a rel="mw:WikiLink" href="Foo" title="Foo"><span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span> b <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c"}},"i":0}}]}'>c</span></a></p>
8317 Link with angle bracket after anchor
8321 <p><a href="/wiki/Foo#.3Cbar.3E" title="Foo">Foo#<bar></a>
8324 <p><a rel="mw:WikiLink" href="./Foo#.3Cbar.3E" title="Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo#.3Cbar.3E"},"sa":{"href":"Foo#<bar>"}}'>Foo#<bar></a></p>
8328 ### Interwiki links (see maintenance/interwiki.sql)
8332 Inline interwiki link
8334 parsoid=wt2html,wt2wt,html2html
8336 [[MeatBall:SoftSecurity]]
8338 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
8341 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a></p>
8345 Inline interwiki link with empty title (bug 2372)
8347 parsoid=wt2html,wt2wt,html2html
8351 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
8354 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?" title="meatball:">MeatBall:</a></p>
8358 Interwiki link encoding conversion (bug 1636)
8360 *[[Wikipedia:ro:Olteniţa]]
8361 *[[Wikipedia:ro:Olteniţa]]
8363 <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>
8364 <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>
8368 <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>
8369 <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>
8374 Interwiki link with fragment (bug 2130)
8376 [[MeatBall:SoftSecurity#foo]]
8378 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
8383 Link scenarios with escaped fragments
8386 [[Foo#Is this great?]]
8387 [[meatball:Foo#Is this great?]]
8389 <p><a href="#Is_this_great.3F">#Is this great?</a>
8390 <a href="/wiki/Foo#Is_this_great.3F" title="Foo">Foo#Is this great?</a>
8391 <a href="http://www.usemod.com/cgi-bin/mb.pl?Foo#Is_this_great.3F" class="extiw" title="meatball:Foo">meatball:Foo#Is this great?</a>
8394 <p><a rel="mw:WikiLink" href="./Main_Page#Is_this_great.3F" data-parsoid='{"stx":"simple","a":{"href":"./Main_Page#Is_this_great.3F"},"sa":{"href":"#Is this great?"}}'>#Is this great?</a>
8395 <a rel="mw:WikiLink" href="./Foo#Is_this_great.3F" title="Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo#Is_this_great.3F"},"sa":{"href":"Foo#Is this great?"}}'>Foo#Is this great?</a>
8396 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?Foo#Is_this_great.3F" title="meatball:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://www.usemod.com/cgi-bin/mb.pl?Foo#Is_this_great.3F"},"sa":{"href":"meatball:Foo#Is this great?"},"isIW":true}'>meatball:Foo#Is this great?</a></p>
8399 # Ideally the wikipedia: prefix here should be proto-relative too
8400 # [CSA]: this is kind of a bogus test, as the PHP parser test doesn't
8401 # define the 'en' prefix, and originally the test used 'wikipedia',
8402 # which isn't a localinterwiki prefix hence the links to the 'en:Foo'
8405 Different interwiki prefixes mapping to the same URL
8413 [[:wikipedia:Foo|Foo]]
8415 [[wikipedia:en:Foo]]
8417 [[:wikipedia:en:Foo]]
8421 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}' title="en:Foo">en:Foo</a></p>
8423 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}' title="en:Foo">Foo</a></p>
8425 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true}' title="wikipedia:Foo">wikipedia:Foo</a></p>
8427 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":":wikipedia:Foo"},"isIW":true}' title="wikipedia:Foo">Foo</a></p>
8429 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":"wikipedia:en:Foo"},"isIW":true}' title="wikipedia:en:Foo">wikipedia:en:Foo</a></p>
8431 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":":wikipedia:en:Foo"},"isIW":true}' title="wikipedia:en:Foo">wikipedia:en:Foo</a></p>
8433 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":" wikiPEdia :Foo"},"isIW":true}' title="wikipedia:Foo"> wikiPEdia :Foo</a></p>
8437 Interwiki links that cannot be represented in wiki syntax
8440 [[meatball:ok#foo|ok with fragment]]
8441 [[meatball:ok_as_well?|ok ending with ? mark]]
8442 [http://de.wikipedia.org/wiki/Foo?action=history has query]
8443 [http://de.wikipedia.org/wiki/#foo is just fragment]
8446 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?ok" class="extiw" title="meatball:ok">meatball:ok</a>
8447 <a href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo" class="extiw" title="meatball:ok">ok with fragment</a>
8448 <a href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well%3F" class="extiw" title="meatball:ok as well?">ok ending with ? mark</a>
8449 <a rel="nofollow" class="external text" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
8450 <a rel="nofollow" class="external text" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a>
8453 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok" title="meatball:ok">meatball:ok</a>
8454 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo" title="meatball:ok">ok with fragment</a>
8455 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well?" title="meatball:ok as well?">ok ending with ? mark</a>
8456 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
8457 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a></p>
8461 Interwiki links: trail
8463 [[wikipedia:Foo|Ba]]r
8465 <p><a href="http://en.wikipedia.org/wiki/Foo" class="extiw" title="wikipedia:Foo">Bar</a>
8468 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true,"tail":"r"}' title="wikipedia:Foo">Bar</a></p>
8472 Local interwiki link
8474 parsoid=wt2html,wt2wt,html2html
8476 [[local:Template:Foo]]
8478 <p><a href="/wiki/Template:Foo" title="Template:Foo">local:Template:Foo</a>
8481 <p><a rel="mw:WikiLink" href="./Template:Foo" title="Template:Foo">local:Template:Foo</a></p>
8484 # Parsoid does not mark self-links, by design.
8486 Local interwiki link: self-link to current page
8489 parsoid=wt2html,wt2wt,html2html
8493 <p><strong class="selflink">local:Main Page</strong>
8496 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">local:Main Page</a></p>
8500 Local interwiki link: prefix only (bug 64167)
8502 parsoid=wt2html,wt2wt,html2html
8506 <p><a href="/wiki/Main_Page" title="Main Page">local:</a>
8509 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">local:</a></p>
8513 Local interwiki link: with additional interwiki prefix (bug 61357)
8515 parsoid=wt2html,wt2wt,html2html
8517 [[local:meatball:Hello]]
8519 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?Hello" class="extiw" title="meatball:Hello">local:meatball:Hello</a>
8522 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?Hello" title="meatball:Hello">local:meatball:Hello</a></p>
8526 Multiple local interwiki link prefixes
8528 [[local:local:local:local:mi:local:Foo]]
8530 parsoid=wt2html,wt2wt,html2html
8532 <p><a href="/wiki/Foo" title="Foo">local:local:local:local:mi:local:Foo</a>
8535 <p><a rel="mw:WikiLink" href="./Foo" title="Foo">local:local:local:local:mi:local:Foo</a></p>
8539 ### Interlanguage links
8540 ### Language links (so that searching for '### language' matches..)
8552 <p>Blah blah blah</p>
8553 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
8556 ## parsoid html2wt will lose the space variations
8558 Interlanguage link with spacing
8560 parsoid=wt2html,wt2wt,html2html
8568 <p>Blah blah blah</p>
8569 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
8573 Double interlanguage link
8582 <p>Blah blah blah</p>
8583 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish"/>
8584 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
8587 ## parsoid html2wt will lose the space variations
8589 Interlanguage link variations
8591 parsoid=wt2html,wt2wt,html2html
8601 <p>Blah blah blah</p>
8602 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish" />
8603 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese" />
8604 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Foo_bar" />
8608 Escaping of interlanguage links
8612 [[ : zh : Chinese ]]
8615 <a href="http://es.wikipedia.org/wiki/Spanish" class="extiw" title="es:Spanish">es:Spanish</a>
8616 <a href="http://zh.wikipedia.org/wiki/Chinese" class="extiw" title="zh:Chinese"> zh : Chinese </a>
8619 <p><a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/Spanish" title="es:Spanish">es:Spanish</a>
8620 <a rel="mw:ExtLink" href="http://zh.wikipedia.org/wiki/Chinese" title="zh:Chinese"> zh : Chinese </a></p>
8623 ## parsoid html2wt will normalize the space to _
8625 Space and question mark encoding in interlanguage links (T95473)
8627 parsoid=wt2html,wt2wt,html2html
8635 <p>Blah blah blah</p>
8636 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Foo_bar%3F" />
8640 Interlanguage link, with prefix links
8650 <p>Blah blah blah</p>
8651 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
8655 Double interlanguage link, with prefix links (bug 8897)
8666 <p>Blah blah blah</p>
8667 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Spanish"/>
8668 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/Chinese"/>
8672 "Extra" interlanguage links (bug 32189 / gerrit 111390)
8680 <p>Blah blah blah</p>
8681 <link rel="mw:PageProp/Language" title="Multilingual" href="http://wikisource.org/wiki/Article"/>
8684 ## PHP parser tests script needs an update
8685 ## Parsoid html2wt will normalize output to [[:zh:Chinese]]
8687 Language links render as inline links if $wgInterwikiMagic=false
8689 wgInterwikiMagic=false
8690 parsoid=wt2html,wt2wt,html2html
8695 <p>Blah blah blah <a rel="mw:ExtLink" href="http://zh.wikipedia.org/wiki/Chinese" title="zh:Chinese">zh:Chinese</a></p>
8698 ## PHP parser tests script needs an update
8699 ## Parsoid html2wt will normalize output to [[:zh:Chinese]]
8701 Language links render as inline links in the Talk namespace
8704 parsoid=wt2html,wt2wt,html2html
8709 <p>Blah blah blah <a rel="mw:ExtLink" href="http://zh.wikipedia.org/wiki/Chinese" title="zh:Chinese">zh:Chinese</a></p>
8713 Parsoid-specific test: Wikilinks with should RT properly
8719 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
8724 Parsoid bug 53221: Wikilinks should be properly entity-escaped
8726 parsoid={ "modes": ["html2wt"], "suppressErrors": true }
8728 <p>He&nbsp;llo <a href="Foo" rel="mw:WikiLink">He&nbsp;llo</a></p>
8729 <p>He&nbsp;llo <a href="He&nbsp;llo" rel="mw:WikiLink">He&nbsp;llo</a></p>
8731 He&nbsp;llo [[Foo|He&nbsp;llo]]
8733 He&nbsp;llo He&nbsp;llo
8735 <p>He&nbsp;llo <a href="/wiki/Foo" title="Foo">He&nbsp;llo</a>
8736 </p><p>He&nbsp;llo He&nbsp;llo
8740 # html2wt will fail because of title normalization without data-parsoid
8742 Parsoid: handle constructor well
8744 parsoid=wt2html,wt2wt
8750 <p><a href="/index.php?title=Constructor&action=edit&redlink=1" class="new" title="Constructor (page does not exist)">constructor</a>
8751 </p><p><a href="/index.php?title=Constructor:foo&action=edit&redlink=1" class="new" title="Constructor:foo (page does not exist)">constructor:foo</a>
8754 <p><a rel="mw:WikiLink" href="./Constructor" title="Constructor" data-parsoid='{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"}}'>constructor</a></p>
8756 <p><a rel="mw:WikiLink" href="./Constructor:foo" title="Constructor:foo" data-parsoid='{"stx":"simple","a":{"href":"./Constructor:foo"},"sa":{"href":"constructor:foo"}}'>constructor:foo</a></p>
8765 # Note that `ko` isn't a known interlanguage prefix
8767 Parsoid: recognize interlanguage links without a target page
8777 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/"/>
8779 <p><a rel="mw:WikiLink" href="./Ko:" title="Ko:">ko:</a></p>
8782 # Note that `ko` isn't a known interwiki prefix
8784 Parsoid: recognize interwiki links without a target page
8786 parsoid=wt2html,wt2wt,html2html
8792 <p><a href="http://es.wikipedia.org/wiki/" class="extiw" title="es:">es:</a>
8793 </p><p><a href="/wiki/Ko:" title="Ko:">ko:</a>
8796 <p><a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/" title="es:">es:</a></p>
8797 <p><a rel="mw:WikiLink" href="./Ko:" title="Ko:">ko:</a></p>
8801 Handle interwiki links pointing to the current wiki as plain wiki links (bug 45209)
8805 <p><a href="/wiki/Foo" title="Foo">mi:Foo</a>
8808 <p><a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"mi:Foo"}}'>mi:Foo</a></p>
8812 Interlanguage link with preceding local interwiki link (bug 68085)
8814 parsoid=wt2html,wt2wt,html2html
8817 [[local:es:Spanish]]
8820 <a href="http://es.wikipedia.org/wiki/Spanish" class="extiw" title="es:Spanish">local:es:Spanish</a>
8824 <a rel="mw:ExtLink" href="http://es.wikipedia.org/wiki/Spanish" title="es:Spanish">local:es:Spanish</a></p>
8828 Looks like an interlanguage link, but is actually a local interwiki
8830 parsoid=wt2html,wt2wt,html2html
8836 <a href="/wiki/Template:Foo" title="Template:Foo">mi:Template:Foo</a>
8840 <a rel="mw:WikiLink" href="./Template:Foo" title="Template:Foo">mi:Template:Foo</a></p>
8844 ### Redirects, Parsoid-only
8848 1. Simple redirect to page
8850 #REDIRECT [[Main Page]]
8852 <link rel="mw:PageProp/redirect" href="./Main_Page"/>
8856 2. Other redirect variants
8858 #REDIRECT [[Main_Page]]
8860 <link rel="mw:PageProp/redirect" href="./Main_Page" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./Main_Page"},"sa":{"href":"Main_Page"}}'/>
8863 # Not a valid redirect in PHP (although perhaps it was, once upon a time)
8864 # This tests the Parsoid bail-out code.
8866 3. Other redirect variants
8868 #REDIRECT [[<nowiki>[[Bar]]</nowiki>]]
8870 <ol><li data-parsoid>REDIRECT [[[[Bar]]]]</li></ol>
8874 4. Redirect to a templated destination
8876 #REDIRECT [[{{echo|Foo}}bar]]
8878 <link about="#mwt2" typeof="mw:ExpandedAttrs" rel="mw:PageProp/redirect" href="./Foobar" data-parsoid='{"a":{"href":"./Foobar"},"sa":{"href":"{{echo|Foo}}bar"}}' data-mw='{"attribs":[[{"txt":"href"},{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[12,24,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"Foo\"}},\"i\":0}}]}'>Foo</span>bar"}]]}'/>
8884 parsoid=wt2html,wt2wt
8889 <li>REDIRECT [[]]</li></ol>
8893 Optional colon in #REDIRECT
8895 # the colon is archaic syntax. we support it for wt2html, but we
8896 # don't care that it roundtrips back to the modern syntax.
8897 parsoid=wt2html,html2html
8899 #REDIRECT:[[Main Page]]
8901 <link rel="mw:PageProp/redirect" href="./Main_Page"/>
8905 Whitespace in #REDIRECT with optional colon
8907 # the colon and gratuitous whitespace is archaic syntax. we support
8908 # it for wt2html, but we don't care that it roundtrips back to the
8909 # modern syntax (without extra whitespace)
8910 parsoid=wt2html,html2html
8917 <link rel="mw:PageProp/redirect" href="./Main_Page"/>
8921 Piped link in #REDIRECT
8923 # content after piped link is ignored. we support this syntax,
8924 # but don't care that the piped link is lost when we roundtrip this.
8927 #REDIRECT [[Main Page|bar]]
8929 <link rel="mw:PageProp/redirect" href="./Main_Page"/>
8933 Redirect to category (T104502)
8935 parsoid=wt2html,wt2wt
8937 #REDIRECT [[Category:Foo]]
8939 <link rel="mw:PageProp/redirect" href="./Category:Foo"/>
8943 Redirect to category with URL encoding (T104502)
8947 #REDIRECT [[Category%3AFoo]]
8949 <link rel="mw:PageProp/redirect" href="./Category:Foo"/>
8953 Redirect to category page
8955 #REDIRECT [[:Category:Foo]]
8957 <link rel="mw:PageProp/redirect" href="./Category:Foo"/>
8961 Redirect to image page (1)
8963 #REDIRECT [[File:Wiki.png]]
8965 <link rel="mw:PageProp/redirect" href="./File:Wiki.png"/>
8969 Redirect to image page (2)
8971 #REDIRECT [[Image:Wiki.png]]
8973 <link rel="mw:PageProp/redirect" href="./File:Wiki.png" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./File:Wiki.png"},"sa":{"href":"Image:Wiki.png"}}'/>
8976 # html2wt disabled because wts serializes as "#REDIRECT [[:en:File:Wiki.png]]"
8977 # Next test confirms this.
8979 Redirect to language (1) (T104918)
8981 parsoid=wt2html,wt2wt,html2html
8983 #REDIRECT [[en:File:Wiki.png]]
8985 <link rel="mw:PageProp/redirect" href="//en.wikipedia.org/wiki/File:Wiki.png"/>
8989 Redirect to language (2) (T104918)
8991 #REDIRECT [[:en:File:Wiki.png]]
8993 <link rel="mw:PageProp/redirect" href="//en.wikipedia.org/wiki/File:Wiki.png"/>
8997 Redirect to interwiki (T104918)
8999 #REDIRECT [[meatball:File:Wiki.png]]
9001 <link rel="mw:PageProp/redirect" href="http://www.usemod.com/cgi-bin/mb.pl?File:Wiki.png"/>
9005 Non-English #REDIRECT
9009 #TILVÍSUN [[Main Page]]
9011 <link rel="mw:PageProp/redirect" href="./Main_Page" data-parsoid='{"src":"#TILVÍSUN ","a":{"href":"./Main_Page"},"sa":{"href":"Main Page"}}'/>
9015 Redirect syntax under text isn't considered a redirect
9018 #redirect [[Main Page]]
9021 <ol data-parsoid='{}'><li data-parsoid='{}'>redirect <a rel="mw:WikiLink" href="./Main_Page" title="Main Page" data-parsoid='{"stx":"simple","a":{"href":"./Main_Page"},"sa":{"href":"Main Page"}}'>Main Page</a></li></ol>
9024 # FIXME: Should hoist the redirect to the top of the page and ensure there
9031 <p>Foo<link rel="mw:PageProp/redirect" href="./Foo"/></p>
9051 Broken br tag sanitization
9059 # TODO: Fix html2html mode (bug 51055)!
9061 Parsoid: Broken br tag recognition
9074 Incorrecly removing closing slashes from correctly formed XHTML
9076 <br style="clear:both;" />
9078 <p><br style="clear:both;" />
9083 Failing to transform badly formed HTML into correct XHTML
9085 <br style="clear: left;">
9086 <br style="clear: right;">
9087 <br style="clear: both;">
9089 <p><br style="clear: left;" />
9090 <br style="clear: right;" />
9091 <br style="clear: both;" />
9095 ## FIXME: Is Parsoid's acceptance of self-closing html-tags
9096 ## a feature or a bug? See https://phabricator.wikimedia.org/T76962
9098 Handling html with a div self-closing tag
9107 <p><div title />
9111 <p><div title=bar />
9112 <div title=bar/>
9114 <div title="bar/"></div>
9118 <div title="" data-parsoid='{"stx":"html","selfClose":true}'></div>
9119 <div title="" data-parsoid='{"stx":"html","selfClose":true}'></div>
9120 <div title="" data-parsoid='{"stx":"html","selfClose":true,"brokenHTMLTag":true}'></div>
9121 <div title="bar" data-parsoid='{"stx":"html","selfClose":true}'></div>
9122 <div title="bar" data-parsoid='{"stx":"html","selfClose":true}'></div>
9123 <div title="bar/" data-parsoid='{"stx":"html","autoInsertedEnd":true}'></div>
9127 Handling html with a br self-closing tag
9154 Horizontal ruler (should it add that extra space?)
9169 Horizontal ruler -- 4+ dashes render hr
9178 Horizontal ruler -- eats additional dashes on the same line
9187 Horizontal ruler -- does not collapse dashes on consecutive lines
9198 Horizontal ruler -- <4 dashes render as plain text
9207 Horizontal ruler -- Supports content following dashes on same line
9219 ### Block-level elements
9228 <ul><li>Common list</li>
9230 <li>item 3</li></ul>
9241 <ol><li>Numbered list</li>
9243 <li> item 3</li></ol>
9257 ***#Number on level 4
9259 **#Number on level 3
9260 **#Number on level 3
9264 #** Level 3, but ordered
9267 <ol><li> with numbers</li></ol>
9268 <ul><li> and bullets</li></ul>
9269 <ol><li> and numbers</li></ol></li>
9271 <ul><li>bullet level 2
9272 <ul><li>bullet level 3
9273 <ol><li>Number on level 4</li></ol></li></ul></li>
9275 <ol><li>Number on level 3</li>
9276 <li>Number on level 3</li></ol></li></ul>
9277 <ol><li>number level 2</li></ol></li>
9279 <ul><li><ul><li> Level 3</li></ul></li></ul></li></ul>
9280 <ol><li><ul><li><ul><li> Level 3, but ordered</li></ul></li></ul></li></ol>
9285 1. Nested mixed wikitext and html list
9288 * <ul><li>ho</li></ul>
9293 <li> <ul><li>ho</li></ul></li>
9295 <ul><li> ho</li></ul></li></ul>
9299 <li> <ul data-parsoid='{"stx":"html"}'><li data-parsoid='{"stx":"html"}'>ho</li></ul></li>
9301 <ul><li> ho</li></ul></li></ul>
9305 2. Nested mixed wikitext and html list (incompatible)
9308 : {{echo|<li>ho</li>}}
9311 <dd> <li>ho</li></dd></dl>
9315 <dd> <li about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"html","pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<li>ho</li>"}},"i":0}}]}'>ho</li></dd></dl>
9325 <ul><li>bar</li></ul></li></ul>
9335 <ul><li><ul><li>foo</li></ul></li>
9341 Nested lists 3 (first element empty)
9347 <ul><li>bar</li></ul></li></ul>
9352 Nested lists 4 (first element empty)
9357 <ul><li><ul><li></li></ul></li>
9363 Nested lists 5 (both elements empty)
9368 <ul><li><ul><li></li></ul></li>
9374 Nested lists 6 (both elements empty)
9380 <ul><li></li></ul></li></ul>
9385 Nested lists 7 (skip initial nesting levels)
9389 <ul><li><ul><li><ul><li> foo</li></ul></li></ul></li></ul>
9394 Nested lists 8 (multiple nesting transitions)
9402 <ul><li><ul><li> bar</li></ul></li>
9403 <li> baz</li></ul></li>
9409 Nested lists 9 (extension interaction)
9415 <ul><li data-parsoid='{}'><ol class="mw-references" typeof="mw:Extension/references" about="#mwt2" data-parsoid='{}' data-mw='{"name":"references","attrs":{}}'></ol></li></ul>
9419 1. Lists with start-of-line-transparent tokens before bullets: Comments
9432 2. Lists with start-of-line-transparent tokens before bullets: Template close
9437 <ul><li>foo bar</li>
9443 List items are not parsed correctly following a <pre> block (bug 785)
9449 <ul><li> <pre>foo</pre></li>
9450 <li> <pre>bar</pre></li>
9454 <ul><li> <pre data-parsoid='{"stx":"html"}'>foo</pre></li>
9455 <li> <pre data-parsoid='{"stx":"html"}'>bar</pre></li>
9460 List items from template
9471 * notSOL{{inner list}}
9474 <ul><li> item 1</li>
9475 <li> item 2</li></ul>
9476 <ul><li> item 0</li>
9478 <li> item 2</li></ul>
9479 <ul><li> item 0</li>
9482 <li> item 2</li></ul>
9487 List interrupted by empty line or heading
9495 <ul><li> foo</li></ul>
9496 <ul><li><ul><li> bar</li></ul></li></ul>
9497 <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>
9498 <ul><li> Another list item</li></ul>
9503 Multiple list tags generated by templates
9524 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
9527 <!--This line will NOT split the list-->
9529 <!--This line will NOT split the list either-->
9531 <!--foo--> <!----> <!--This line NOT split the list either-->
9542 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
9545 <!--This line will NOT split the list-->
9547 <!--This line will NOT split the list either-->
9549 <!--foo--> <!----> <!--This line NOT split the list
9562 (The PHP parser relies on Tidy for the hack)
9564 parsoid=wt2html,wt2wt
9568 * {{echo|<li>templated li-hack}}
9569 * <!--foo--> <li> unsupported li-hack with preceding comments
9572 <li><li>not a li-hack
9579 <li>templated li-hack</li>
9580 <li>unsupported li-hack with preceding comments</li>
9583 <li>not a li-hack</li>
9588 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
9615 Parsoid: Test of whitespace serialization with Templated bullets
9622 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}}]}'> Bar</li>
9626 # ------------------------------------------------------------------------
9627 # The next set of tests are about Parsoid's ability to handle badly nested
9628 # tags (parse, minimize scope of fixup, and roundtrip back)
9629 # ------------------------------------------------------------------------
9632 Unbalanced closing block tags break a list
9633 (php parser relies on Tidy to fix up)
9651 # Parsoid fails this test, but it might be tricky to support properly.
9654 Unbalanced closing non-block tags don't break a list
9655 (php parser relies on Tidy to fix up)
9662 <li><span>a</span></li>
9663 <li><span>b</span></li>
9677 Unclosed formatting tags that straddle lists are closed and reopened
9678 (php parser relies on Tidy to fix up)
9680 parsoid=wt2html,wt2wt,html2html
9690 <ol><li> <s> a</s></li>
9691 <li><s> b </s></li></ol>
9696 1. List embedded in a formatting tag
9703 <li><small>foo</small></li>
9713 ## Ugly Parsoid output here
9714 ## Not sure what the right output is.
9716 2. List embedded in a formatting tag
9723 <li><small>a</small></li>
9724 <li><small>b</small></li>
9731 <li><small>b</small></li>
9735 # Ugly Parsoid and PHP parser output here
9736 # Not sure if we want to make this a test!
9739 ## 3. Unclosed formatting tags in list elements
9745 ## <li><small>a</small></li>
9746 ## <li><small><small>b</small></small></li>
9750 ## <li><small>a</small></li>
9752 ## <li><small>b</small></li>
9756 # This is a bug in the PHP parser + tidy combination.
9757 # (The </tr> tag gets parsed as text and html-escaped by PHP,
9758 # and then fostered out of the table by tidy.)
9759 # We believe the Parsoid output to be correct.
9761 Table with missing opening <tr> tag
9763 parsoid=wt2html,wt2wt
9781 # Note that the current date is hard-coded as
9782 # 1970-01-01T00:02:03Z (a Thursday)
9783 # when running parser tests. The timezone is also fixed to GMT, so
9784 # local date will be identical to current date.
9787 Magic Word: {{CURRENTDAY}}
9796 Magic Word: {{CURRENTDAY2}}
9805 Magic Word: {{CURRENTDAYNAME}}
9814 Magic Word: {{CURRENTDOW}}
9823 Magic Word: {{CURRENTMONTH}}
9832 Magic Word: {{CURRENTMONTH1}}
9841 Magic Word: {{CURRENTMONTHABBREV}}
9843 {{CURRENTMONTHABBREV}}
9850 Magic Word: {{CURRENTMONTHNAME}}
9852 {{CURRENTMONTHNAME}}
9859 Magic Word: {{CURRENTMONTHNAMEGEN}}
9861 {{CURRENTMONTHNAMEGEN}}
9868 Magic Word: {{CURRENTTIME}}
9877 Magic Word: {{CURRENTHOUR}}
9886 Magic Word: {{CURRENTWEEK}} (@bug 4594)
9895 Magic Word: {{CURRENTYEAR}}
9904 Magic Word: {{CURRENTTIMESTAMP}}
9906 {{CURRENTTIMESTAMP}}
9913 Magic Words LOCAL (UTC)
9917 * {{LOCALMONTHNAME}}
9918 * {{LOCALMONTHNAMEGEN}}
9919 * {{LOCALMONTHABBREV}}
9928 * {{LOCALTIMESTAMP}}
9943 <li> 19700101000203</li></ul>
9948 Magic Word: {{FULLPAGENAME}}
9950 title=[[User:Ævar Arnfjörð Bjarmason]]
9954 <p>User:Ævar Arnfjörð Bjarmason
9959 Magic Word: {{FULLPAGENAMEE}}
9961 title=[[User:Ævar Arnfjörð Bjarmason]]
9965 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
9970 Magic Word: {{TALKSPACE}}
9972 title=[[User:Ævar Arnfjörð Bjarmason]]
9981 Magic Word: {{TALKSPACE}}, same namespace
9983 title=[[User talk:Ævar Arnfjörð Bjarmason]]
9992 Magic Word: {{TALKSPACE}}, main namespace
9994 title=[[Parser Test]]
10003 Magic Word: {{TALKSPACEE}}
10005 title=[[User:Ævar Arnfjörð Bjarmason]]
10014 Magic Word: {{SUBJECTSPACE}}
10016 title=[[User talk:Ævar Arnfjörð Bjarmason]]
10025 Magic Word: {{SUBJECTSPACE}}, same namespace
10027 title=[[User:Ævar Arnfjörð Bjarmason]]
10036 Magic Word: {{SUBJECTSPACE}}, main namespace
10038 title=[[Parser Test]]
10046 Magic Word: {{SUBJECTSPACEE}}
10048 title=[[User talk:Ævar Arnfjörð Bjarmason]]
10057 Magic Word: {{NAMESPACE}}
10059 title=[[User:Ævar Arnfjörð Bjarmason]]
10068 Magic Word: {{NAMESPACEE}}
10070 title=[[User:Ævar Arnfjörð Bjarmason]]
10079 Magic Word: {{NAMESPACENUMBER}}
10081 title=[[User:Ævar Arnfjörð Bjarmason]]
10083 {{NAMESPACENUMBER}}
10090 Magic Word: {{SUBPAGENAME}}
10092 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
10101 Magic Word: {{SUBPAGENAMEE}}
10103 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
10112 Magic Word: {{ROOTPAGENAME}}
10114 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
10118 <p>Ævar Arnfjörð Bjarmason
10123 Magic Word: {{ROOTPAGENAMEE}}
10125 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
10129 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
10134 Magic Word: {{BASEPAGENAME}}
10136 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
10140 <p>Ævar Arnfjörð Bjarmason
10145 Magic Word: {{BASEPAGENAMEE}}
10147 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
10151 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
10156 Magic Word: {{TALKPAGENAME}}
10158 title=[[User:Ævar Arnfjörð Bjarmason]]
10162 <p>User talk:Ævar Arnfjörð Bjarmason
10167 Magic Word: {{TALKPAGENAMEE}}
10169 title=[[User:Ævar Arnfjörð Bjarmason]]
10173 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
10178 Magic Word: {{SUBJECTPAGENAME}}
10180 title=[[User talk:Ævar Arnfjörð Bjarmason]]
10182 {{SUBJECTPAGENAME}}
10184 <p>User:Ævar Arnfjörð Bjarmason
10189 Magic Word: {{SUBJECTPAGENAMEE}}
10191 title=[[User talk:Ævar Arnfjörð Bjarmason]]
10193 {{SUBJECTPAGENAMEE}}
10195 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
10200 Magic Word: {{NUMBEROFFILES}}
10209 Magic Word: {{PAGENAME}}
10211 title=[[User:Ævar Arnfjörð Bjarmason]]
10215 <p>Ævar Arnfjörð Bjarmason
10220 Magic Word: {{PAGENAME}} with metacharacters
10222 title=[['foo & bar = baz']]
10226 <p><i>'foo & bar = baz'</i>
10229 <p><i>'foo & bar = baz'</i></p>
10233 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
10235 title=[[*RFC 1234 http://example.com/]]
10239 <p>*RFC 1234 http://example.com/
10242 <p>*RFC 1234 http://example.com/</p>
10246 Magic Word: {{PAGENAMEE}}
10248 title=[[User:Ævar Arnfjörð Bjarmason]]
10252 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
10257 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
10259 title=[[*RFC 1234 http://example.com/]]
10263 <p>*RFC_1234_http://example.com/
10266 <p>*RFC_1234_http://example.com/</p>
10270 Magic Word: {{REVISIONID}}
10279 Magic Word: {{SCRIPTPATH}}
10287 Magic Word: {{STYLEPATH}}
10296 Magic Word: {{SERVER}}
10300 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
10305 Magic Word: {{SERVERNAME}}
10314 Magic Word: {{SITENAME}}
10323 Magic Word: {{PAGELANGUAGE}}
10334 Magic Word: {{PAGELANGUAGE}} on a page with no explicitly set language
10343 Case-sensitive magic words, when cased differently, should just be template transclusions
10350 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
10351 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
10352 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
10353 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
10358 Case-insensitive magic words should still work with weird casing.
10368 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
10372 # From plwiki:PLOS_ONE
10374 Parsoid: Page property magic word with magic word contents
10376 {{DISPLAYTITLE:''{{PAGENAME}}''}}
10378 <meta property="mw:PageProp/displaytitle" content="Main Page" about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"src":"{{DISPLAYTITLE:''{{PAGENAME}}''}}"}' data-mw='{"attribs":[[{"txt":"content"},{"html":"<i data-parsoid='{\"dsr\":[15,31,2,2]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[17,29,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"PAGENAME\",\"function\":\"pagename\"},\"params\":{},\"i\":0}}]}'>Main Page</span></i>"}]]}'/>
10382 Parsoid: Template-generated DISPLAYTITLE
10384 {{{{echo|DISPLAYTITLE}}:Foo}}
10386 <meta property="mw:PageProp/displaytitle" content="Foo" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"{{echo|DISPLAYTITLE}}:Foo"},"params":{},"i":0}}]}'/>
10390 Namespace 1 {{ns:1}}
10399 Namespace 1 {{ns:01}}
10408 Namespace 0 {{ns:0}} (bug 4783)
10416 Namespace 0 {{ns:00}} (bug 4783)
10424 Namespace -1 {{ns:-1}}
10433 Namespace User {{ns:User}}
10442 Namespace User talk {{ns:User_talk}}
10451 Namespace User talk {{ns:uSeR tAlK}}
10460 Namespace File {{ns:File}}
10469 Namespace File {{ns:Image}}
10478 Namespace (lang=de) Benutzer {{ns:User}}
10489 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
10495 <p>Benutzer Diskussion
10502 {{urlencode:hi world?!}}
10503 {{urlencode:hi world?!|WIKI}}
10504 {{urlencode:hi world?!|PATH}}
10505 {{urlencode:hi world?!|QUERY}}
10515 Magic Word: prioritize type info over data-parsoid
10519 <meta property="mw:PageProp/forcetoc" data-parsoid='{"magicSrc":"__NOTOC__"}'/>
10525 Magic Word: serialize on separate line (parsoid)
10527 parsoid=wt2wt,html2wt
10533 foo<meta property="mw:PageProp/notoc"/>bar
10537 Magic Word: rt non-english wikis
10544 <meta property="mw:PageProp/noeditsection" data-parsoid='{"magicSrc":"__NOEDITSECTION__"}'/>
10548 __proto__ is treated as normal wikitext (T105997)
10560 Magic links: internal link to RFC (bug 479)
10564 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
10567 <p><a rel="mw:WikiLink" href="./RFC_123" title="RFC 123">RFC 123</a></p>
10571 Magic links: RFC (bug 479)
10575 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
10578 <p><a href="//tools.ietf.org/html/rfc822" rel="mw:ExtLink">RFC 822</a></p>
10582 Magic links: RFC (bug 65278)
10584 This is RFC 822 but thisRFC 822 is not RFC 822linked.
10586 <p>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a> but thisRFC 822 is not RFC 822linked.
10589 <p>This is <a href="//tools.ietf.org/html/rfc822" rel="mw:ExtLink">RFC 822</a> but thisRFC 822 is not RFC 822linked.</p>
10593 Magic links: RFC (w/ non-newline whitespace, bug 28950/29025)
10595 RFC      822
10599 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
10604 <p><a href="//tools.ietf.org/html/rfc822" rel="mw:ExtLink">RFC <span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#160;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#0160;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#xA0;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#Xa0;","srcContent":" "}'> </span> 822</a>
10610 Magic links: ISBN (bug 1937)
10614 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
10617 <p><a href="./Special:BookSources/0306406152" rel="mw:WikiLink">ISBN 0-306-40615-2</a></p>
10621 Magic links: ISBN (bug 65278)
10623 This is ISBN 978-0-316-09811-3 but thisISBN 978-0-316-09811-3 is not ISBN 978-0-316-09811-3linked.
10625 <p>This is <a href="/wiki/Special:BookSources/9780316098113" class="internal mw-magiclink-isbn">ISBN 978-0-316-09811-3</a> but thisISBN 978-0-316-09811-3 is not ISBN 978-0-316-09811-3linked.
10628 <p>This is <a href="./Special:BookSources/9780316098113" rel="mw:WikiLink">ISBN 978-0-316-09811-3</a> but thisISBN 978-0-316-09811-3 is not ISBN 978-0-316-09811-3linked.</p>
10632 Magic links: ISBN (w/ non-newline whitespace, bug 28950/29025)
10634 ISBN      978 0 316 09811 3
10640 <p><a href="/wiki/Special:BookSources/9780316098113" class="internal mw-magiclink-isbn">ISBN 978 0 316 09811 3</a>
10647 <p><a href="./Special:BookSources/9780316098113" rel="mw:WikiLink">ISBN <span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#160;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#0160;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#xA0;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#Xa0;","srcContent":" "}'> </span> 978<span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span>0<span typeof="mw:Entity" data-parsoid='{"src":"&#160;","srcContent":" "}'> </span>316<span typeof="mw:Entity" data-parsoid='{"src":"&#0160;","srcContent":" "}'> </span>09811<span typeof="mw:Entity" data-parsoid='{"src":"&#xA0;","srcContent":" "}'> </span>3</a>
10655 Magic links: PMID incorrectly converts space to underscore
10659 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
10662 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract" rel="mw:ExtLink">PMID 1234</a></p>
10666 Magic links: PMID (bug 65278)
10668 This is PMID 1234 but thisPMID 1234 is not PMID 1234linked.
10670 <p>This is <a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a> but thisPMID 1234 is not PMID 1234linked.
10673 <p>This is <a href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract" rel="mw:ExtLink">PMID 1234</a> but thisPMID 1234 is not PMID 1234linked.</p>
10677 Magic links: PMID (w/ non-newline whitespace, bug 28950/29025)
10679 PMID      1234
10683 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
10688 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract" rel="mw:ExtLink">PMID <span typeof="mw:Entity" data-parsoid='{"src":"&nbsp;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#160;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#0160;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#xA0;","srcContent":" "}'> </span><span typeof="mw:Entity" data-parsoid='{"src":"&#Xa0;","srcContent":" "}'> </span> 1234</a>
10693 # <nowiki> nodes shouldn't be inserted during html2wt by Parsoid,
10694 # since these are ExtLinkText, not MagicLinkText
10696 Magic links: use appropriate serialization for "almost" magic links.
10698 X[[Special:BookSources/0978739256|foo]]
10700 X[//tools.ietf.org/html/rfc1234 foo]
10702 <p>X<a href="/wiki/Special:BookSources/0978739256" title="Special:BookSources/0978739256">foo</a>
10703 </p><p>X<a rel="nofollow" class="external text" href="//tools.ietf.org/html/rfc1234">foo</a>
10706 <p>X<a rel="mw:WikiLink" href="./Special:BookSources/0978739256" title="Special:BookSources/0978739256">foo</a></p>
10707 <p>X<a rel="mw:ExtLink" href="//tools.ietf.org/html/rfc1234">foo</a></p>
10711 Magic links: All disabled (T47942)
10713 wgEnableMagicLinks={"ISBN":false, "PMID":false, "RFC":false}
10719 <p>ISBN 0-306-40615-2
10730 Nonexistent template
10732 {{thistemplatedoesnotexist}}
10734 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
10739 Template with invalid target containing tags
10741 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
10743 <p>{{a<b>b</b>|foo|a=b|a = b}}
10748 Template with invalid target containing unclosed tag
10750 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
10752 <p>{{a<b>|foo|a=b|a = b}}</b>
10757 Template with invalid target containing wikilink
10761 <p>{{<a href="/wiki/Main_Page" title="Main Page">Main Page</a>}}
10764 <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>
10768 Template with just whitespace in it, bug #68421
10772 <p about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{ }}"}},"i":0}}]}'>{{ }}</p>
10778 This is a test template
10786 <p>This is a test template
10791 Template with explicit namespace
10795 <p>This is a test template
10803 This is a test template with parameter {{{param}}}
10809 {{paramtest|param=foo}}
10811 <p>This is a test template with parameter foo
10816 Template:paramtestnum
10818 [[{{{1}}}|{{{2}}}]]
10822 Template unnamed parameter
10824 {{paramtestnum|Main Page|the main page}}
10826 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
10831 Template:templatesimple
10837 Template:templateredirect
10839 #redirect [[Template:templatesimple]]
10843 Template:templateasargtestnum
10849 Template:templateasargtest
10851 {{template{{{templ}}}}}
10855 Template:templateasargtest2
10861 Template with template name as unnamed argument
10863 {{templateasargtestnum|templatesimple}}
10870 Template with template name as argument
10872 {{templateasargtest|templ=simple}}
10879 Template with template name as argument (2)
10881 {{templateasargtest2|templ=templatesimple}}
10888 Template:templateasargtestdefault
10890 {{{{{templ|templatesimple}}}}}
10900 Template with default value
10902 {{templateasargtestdefault}}
10909 Template with default value (value set)
10911 {{templateasargtestdefault|templ=templa}}
10920 {{templateredirect}}
10925 <link rel="mw:PageProp/redirect" href="./Template:Templatesimple" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"templateredirect","href":"./Template:Templateredirect"},"params":{},"i":0}}]}'/>
10929 Template with argument in separate line
10931 {{ templateasargtest |
10939 Template with complex template as argument
10942 param ={{ templateasargtest |
10943 templ = simple }}}}
10945 <p>This is a test template with parameter (test)
10950 Template with thumb image (with link in description)
10952 {{paramtest|param=[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
10954 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>
10957 <p>This is a test template with parameter</p>
10958 <div class="thumb tright">
10959 <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>
10960 <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>
10964 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"paramtest","href":"./Template:Paramtest"},"params":{"param":{"wt":"[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]"}},"i":0}}]}'>This is a test template with parameter </p><figure class="mw-default-size" typeof="mw:Error mw:Image/Thumb" about="#mwt1" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Noimage.png" ><img resource="./File:Noimage.png" src="./Special:FilePath/Noimage.png" height="220" width="220"/></a><figcaption><a rel="mw:WikiLink" href="./No_link" title="No link">link</a> <a rel="mw:WikiLink" href="./No_link" title="No link">caption</a></figcaption></figure>
10968 Template:complextemplate
10970 {{{1}}} {{paramtest|
10971 param ={{{param}}}}}
10975 Template with complex arguments
10978 param ={{ templateasargtest |
10979 templ = simple }}|[[Template:complextemplate|link]]}}
10981 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
10986 BUG 553: link with two variables in a piped link
10989 |[[{{{1}}}|{{{2}}}]]
10994 <td>[[{{{1}}}|{{{2}}}]]
10999 <tbody><tr><td>[[<span about="#mwt5" typeof="mw:Param" data-mw='{"parts":[{"templatearg":{"target":{"wt":"1"},"params":{},"i":0}}]}'>{{{1}}}</span>|<span about="#mwt2" typeof="mw:Param" data-mw='{"parts":[{"templatearg":{"target":{"wt":"2"},"params":{},"i":0}}]}'>{{{2}}}</span>]]</td></tr>
11005 Abort table cell attribute parsing on wikilink
11008 | testing [[one|two]] | three || four
11009 | testing one two | three || four
11010 | testing="[[one|two]]" | three || four
11015 <td> testing <a href="/index.php?title=One&action=edit&redlink=1" class="new" title="One (page does not exist)">two</a> | three </td>
11021 <td> testing="<a href="/index.php?title=One&action=edit&redlink=1" class="new" title="One (page does not exist)">two</a>" | three </td>
11027 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'> testing <a rel="mw:WikiLink" href="./One" title="One" data-parsoid='{"stx":"piped","a":{"href":"./One"},"sa":{"href":"one"}}'>two</a> | three </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'> four</td>
11028 <td data-parsoid='{"a":{"testing":null,"one":null,"two":null},"sa":{"testing":"","one":"","two":""},"autoInsertedEnd":true}'> three </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'> four</td>
11029 <td> testing="<a rel="mw:WikiLink" href="./One" title="One" data-parsoid='{"stx":"piped","a":{"href":"./One"},"sa":{"href":"one"}}'>two</a>" | three </td><td data-parsoid='{"stx_v":"row","autoInsertedEnd":true}'> four</td></tr>
11034 Don't abort table cell attribute parsing if wikilink is found in template arg
11037 | Test {{#tag:ref|One two "[[three]]" four}}
11041 <tbody><tr><td> Test <ref about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"#tag:ref","function":"#tag"},"params":{"1":{"wt":"One two \"[[three]]\" four"}},"i":0}}]}'>One two "<a rel="mw:WikiLink" href="./Three" title="Three">three</a>" four</ref></td></tr>
11046 Magic variable as template parameter
11048 {{paramtest|param={{SITENAME}}}}
11050 <p>This is a test template with parameter MediaWiki
11057 [[{{{param}}}|link]]
11061 Template parameter as link source
11063 {{linktest|param=Main Page}}
11065 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
11070 Template:paramtest2
11072 including another template, {{paramtest|param={{{arg}}}}}
11076 Template passing argument to another template
11078 {{paramtest2|arg='hmm'}}
11080 <p>including another template, This is a test template with parameter 'hmm'
11091 Template as link source
11095 [[{{linktest2}}|Main Page]]
11097 [[{{linktest2}}]]Page
11099 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
11100 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
11101 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
11119 Template infinite loop
11123 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
11128 Template from main namespace
11147 BUG 529: Template with table, not included at beginning of line
11166 BUG 523: Template shouldn't eat newline (or add an extra one before table)
11186 BUG 41: Template parameters shown as broken links
11195 Template with targets containing wikilinks
11199 {{[[{{echo|foo}}]]}}
11201 {{{{echo|[[foo}}]]}}
11203 <p>{{<a href="/wiki/Foo" title="Foo">foo</a>}}
11204 </p><p>{{<a href="/wiki/Foo" title="Foo">foo</a>}}
11216 Templates: Double quotes as template target
11223 <p>foo <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"''","href":"./Template:''"},"params":{},"i":0}}]}'>bar</span> baz
11227 ## This test is about making sure Parsoid's data-mw is well formed in the
11228 ## face of multiple templates with intersecting and overlapping ranges. The
11229 ## wikitext itself is wretched.
11231 Templates with intersecting and overlapping ranges
11256 <p about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[{"k":"1"}],[{"k":"1"}],[{"k":"1"}]],"firstWikitextNode":"table"}' data-mw='{"parts":["{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"\n<p>ha</p>"}},"i":0}},"\n","{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"\n<p>ho</p>"}},"i":1}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{!}}hi"}},"i":2}},"\n|}"]}'>ha</p><table about="#mwt1" typeof="mw:ExpandedAttrs" data-mw='{"attribs":[[{"txt":"","html":""},{"html":""}]]}'>
11258 </table><p about="#mwt1">ho</p><table about="#mwt1" typeof="mw:ExpandedAttrs" data-mw='{"attribs":[[{"txt":"","html":""},{"html":""}]]}'>
11260 <tbody><tr><td>hi</td></tr>
11265 Template:MSGNW test
11267 ''None'' of '''this''' should be
11269 but rather passed unmodified
11277 # hmm, fix this or just deprecate msgnw and document its behavior?
11281 {{msgnw:MSGNW test}}
11283 <p>''None'' of '''this''' should be
11285  but rather passed unmodified
11286 {{test}}
11290 <!-- comment -->
11297 {{int:youhavenewmessages|lots of money|not!}}
11299 <p>You have lots of money (not!).
11304 int keyword - non-existing message
11315 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
11319 <includeonly> and <noinclude> being included
11330 <onlyinclude>Foo</onlyinclude>bar
11334 <onlyinclude> being included
11346 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
11350 <onlyinclude> and <includeonly> being included
11359 <includeonly> and <noinclude> on a page
11361 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
11368 Un-closed <noinclude>
11375 <onlyinclude> on a page
11377 <onlyinclude>Foo</onlyinclude>bar
11384 Un-closed <onlyinclude>
11391 Self-closed noinclude, includeonly, onlyinclude tags
11402 Unbalanced includeonly and noinclude tags
11406 |b</noinclude></noinclude>
11407 |c</noinclude></includeonly>
11408 |d</includeonly></includeonly>
11417 <td>c</includeonly>
11419 <td>d</includeonly></includeonly>
11425 Template:Includeonly section
11428 ==Includeonly section==
11434 Bug 6563: Edit link generation for section shown by <includeonly>
11436 {{includeonly section}}
11438 <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>
11439 <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>
11443 # Uses same input as the contents of [[Template:Includeonly section]]
11445 Bug 6563: Section extraction for section shown by <includeonly>
11450 ==Includeonly section==
11458 Bug 6563: Edit link generation for section suppressed by <includeonly>
11461 ==Includeonly section==
11465 <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>
11470 Bug 6563: Section extraction for section suppressed by <includeonly>
11475 ==Includeonly section==
11483 Un-closed <includeonly>
11488 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>"}'/>
11491 ## We used to, but no longer wt2wt this test since the default serializer
11492 ## will normalize the include directives to serialize on their own line.
11493 ## Selser will take care of preserving formatting in scenarios where they
11494 ## intermingled with other wikitext.
11496 Includes and comments at SOL
11498 parsoid=wt2html,html2html
11500 <!-- comment --><noinclude><!-- comment --></noinclude><!-- comment -->== hu ==
11504 </noinclude>* stuff
11507 <includeonly>can have stuff</includeonly>=== here ===
11510 <h2><span class="mw-headline" id="hu">hu</span></h2>
11513 <ul><li> stuff</li>
11514 <li> here</li></ul>
11515 <h3><span class="mw-headline" id="here">here</span></h3>
11518 <!-- comment --><meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/><!-- comment --><meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/><!-- comment --><h2> hu </h2>
11520 <meta typeof="mw:Includes/NoInclude" data-parsoid='{"src":"<noinclude>"}'/>
11522 <meta typeof="mw:Includes/NoInclude/End" data-parsoid='{"src":"</noinclude>"}'/><ul><li> stuff</li>
11523 <li> here</li></ul>
11525 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>can have stuff</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><h3> here </h3>
11529 # TODO: test with DOM fragment reuse!
11531 Parsoid: DOM fragment reuse
11533 parsoid=wt2wt,wt2html
11535 a{{echo|b<table></table>c}}d
11547 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["a",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b<table></table>c"}},"i":0}},"d"]}' data-parsoid='{"pi":[[{"k":"1"}]]}'>ab</p><table about="#mwt1" data-parsoid='{"stx":"html"}'></table><p about="#mwt1">cd</p>
11549 <p about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["a",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b\n<table></table>\nc"}},"i":0}},"d"]}' data-parsoid='{"pi":[[{"k":"1"}]]}'>ab</p><span about="#mwt2">
11550 </span><table about="#mwt2" data-parsoid='{"stx":"html"}'></table><span about="#mwt2">
11551 </span><p about="#mwt2">cd</p>
11553 <p about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n\n<table></table>\n\nb"}},"i":0}}]}' data-parsoid='{"pi":[[{"k":"1"}]]}'>a</p><span about="#mwt3">
11555 </span><table about="#mwt3" data-parsoid='{"stx":"html"}'></table><span about="#mwt3">
11557 </span><p about="#mwt3">b</p>
11561 Parsoid: Merge double tds (T52603)
11566 |{{echo|{{!}} foo}}
11570 <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>
11575 Parsoid: Merge double tds in nested transclusion content (T52603)
11581 |{{echo|{{!}} foo}}
11585 <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}}]}'>
11587 <tr><td data-mw='{"parts":["|"]}'> foo</td></tr>
11593 ### <includeonly> and <noinclude> in attributes
11596 0. includeonly around the entire attribute
11598 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
11600 <p><span id="v2">bar</span>
11605 1. includeonly in html attr key
11607 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
11609 <p><span id="foo">bar</span>
11614 2. includeonly in html attr value
11616 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
11617 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
11619 <p><span id="v1">bar</span>
11620 <span id="v1">bar</span>
11625 3. includeonly in part of an attr value
11627 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
11629 <p><span style="color:red;">bar</span>
11634 4. includeonly in table attributes
11658 ### Token Stream Patcher tests
11660 ### These tests won't always pass wt2wt and other modes because
11661 ### on serialization, the table will be output on a new line.
11662 ### For now, we are blacklisting them, and using this to test selser.
11666 1. Table tag in SOL posn. should get reparsed correctly with valid TSR
11668 parsoid=wt2html,wt2wt
11670 {{echo|}}{| width = '100%'
11674 <span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":""}},"i":0}}]}'></span><table width="100%">
11675 <tbody><tr><td>foo</td></tr>
11679 ## We used to, but no longer wt2wt this test since the default serializer
11680 ## will normalize the include directives to serialize on their own line.
11681 ## Selser will take care of preserving formatting in scenarios where they
11682 ## intermingled with other wikitext.
11684 2. Table tag in SOL posn. should get reparsed correctly with valid TSR
11688 <includeonly>a</includeonly>{| {{{b}}}
11692 <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-parsoid='{"a":{"{{{b}}}":null},"sa":{"{{{b}}}":""}}' data-mw='{"attribs":[[{"txt":"{{{b}}}","html":"<span about=\"#mwt1\" typeof=\"mw:Param\" data-parsoid='{\"pi\":[[]],\"dsr\":[31,38,null,null]}' data-mw='{\"parts\":[{\"templatearg\":{\"target\":{\"wt\":\"b\"},\"params\":{},\"i\":0}}]}'>{{{b}}}</span>"},{"html":""}]]}'>
11693 <tbody><tr><td>c</td></tr>
11698 Table wikitext syntax outside wiki-tables
11702 ! not a table heading
11705 | class="foo bar" | baz
11713 ! not a table heading
11716 | class="foo bar" | baz
11725 ### Testing parsing of templates where a template arg
11726 ### has the same name as the template itself.
11732 {{{quote|{{{1}}}}}}
11736 Templates: Template Name/Arg clash: 1. Use of positional param
11745 Templates: Template Name/Arg clash: 2. Use of named param
11747 {{quote|quote=foo}}
11754 Templates: Template Name/Arg clash: 3. Use of named param with empty input
11763 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
11767 Templates: 1. Simple use
11776 Templates: 2. Inside a block tag
11778 <div>{{echo|Foo}}</div>
11779 <blockquote>{{echo|Foo}}</blockquote>
11782 <blockquote>Foo</blockquote>
11792 Templates: P-wrapping: 1a. Templates on consecutive lines
11803 Templates: P-wrapping: 1b. Templates on consecutive lines
11817 Templates: P-wrapping: 1c. Templates on consecutive lines
11820 {{echo|bar}} <div>baz</div>
11833 Templates: P-wrapping: 1d. Template preceded by comment-only line
11842 <p about="#mwt223" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Bar"}},"i":0}}]}'>Bar</p>
11846 Templates: Inline Text: 1. Multiple template uses
11848 {{echo|Foo}}bar{{echo|baz}}
11855 Templates: Inline Text: 2. Back-to-back template uses
11857 {{echo|Foo}}{{echo|bar}}
11864 Templates: Block Tags: 1. Multiple template uses
11866 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
11868 <div>Foo</div><div>bar</div><div>baz</div>
11873 Templates: Block Tags: 2. Back-to-back template uses
11875 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
11877 <div>Foo</div><div>bar</div>
11881 # This is an edge case relating to paragraph wrapping.
11883 Templates: Correctly encapsulate templates producing </p> tag without a corresponding <p> tag
11888 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\nb</p>"}},"i":0}}]}'>a
11893 Templates: Links: 1. Simple example
11895 {{echo|[[Foo|bar]]}}
11897 <p><a href="/wiki/Foo" title="Foo">bar</a>
11902 Templates: Links: 2. Generation of link href
11904 [[{{echo|Foo}}|bar]]
11906 <p><a href="/wiki/Foo" title="Foo">bar</a>
11911 Templates: Links: 3. Generation of part of a link href
11913 [[Fo{{echo|o}}|bar]]
11915 [[Foo{{echo|bar}}]]
11917 [[Foo{{echo|bar}}baz]]
11919 [[Foo{{echo|bar}}|bar]]
11921 [[:Foo{{echo|bar}}]]
11923 [[:Foo{{echo|bar}}|bar]]
11925 <p><a href="/wiki/Foo" title="Foo">bar</a>
11926 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
11927 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
11928 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
11929 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
11930 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
11935 Templates: Links: 4. Multiple templates generating link href
11937 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
11939 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
11944 Templates: Links: 5. Generation of link text
11946 [[Foo|{{echo|bar}}]]
11948 <p><a href="/wiki/Foo" title="Foo">bar</a>
11953 Templates: Links: 5. Nested templates (only outermost template should be marked)
11955 {{echo|[[{{echo|Foo}}|bar]]}}
11957 <p><a href="/wiki/Foo" title="Foo">bar</a>
11962 Templates: HTML Tag: 1. Generation of HTML attr. key
11964 <div {{echo|style}}="color:red;">foo</div>
11966 <div style="color:red;">foo</div>
11971 Templates: HTML Tag: 2. Generation of HTML attr. value
11973 <div style={{echo|'color:red;'}}>foo</div>
11975 <div style="color:red;">foo</div>
11980 Templates: HTML Tag: 3. Generation of HTML attr key and value
11982 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
11984 <div style="color:red;">foo</div>
11989 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
11991 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
11993 <div title="This is a long title with just one piece templated">foo</div>
11998 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
12000 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
12002 <div title="This is a long title with just one piece templated">foo</div>
12007 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
12009 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
12011 <div title="This is a long title with just one piece templated">foo</div>
12015 # SSS FIXME: While it is great we added support for all this,
12016 # do we want to make this part of the spec? Maybe we want to
12017 # deprecate this kind of usage in the future?
12019 Templates: HTML Tag: 7. Generation of partial attribute key string
12021 <div st{{echo|yle}}="color:red;">foo</div>
12023 <div style="color:red;">foo</div>
12028 Templates: HTML Tag: 8. Template-generated attribute (k=v)
12030 <div {{echo|1=id="v1"}}>bar</div>
12032 <div id="v1">bar</div>
12037 Templates: HTML Tag: 9. Multiple template-generated attributes
12039 <div {{echo|1=id="v1" title="foo"}}>bar</div>
12041 <div id="v1" title="foo">bar</div>
12046 Templates: Support for templates generating attributes and content
12048 {| {{mixed_attr_content_template}}
12053 <table style="color:red;" title="T48811">
12063 <table style="color:red;" title="T48811" about="#mwt1" typeof="mw:Transclusion mw:ExpandedAttrs" data-mw='{"parts":["{| ",{"template":{"target":{"wt":"mixed_attr_content_template","href":"./Template:Mixed_attr_content_template"},"params":{},"i":0}},"\n|-\n|bar\n|}"]}'>
12072 1. Entities and nowikis inside templated attributes should be handled correctly
12074 <div {{echo|style{{=}}"background:#f9f9f9;"}}>foo</div>
12076 <div style="background:#f9f9f9;">foo</div>
12079 <div style="background:#f9f9f9;" about="#mwt3" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html"}' data-mw='{"attribs":[[{"txt":"style","html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[5,49,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"style{{=}}\\\"background:&amp;#35;f9f9f9;\\\"\"}},\"i\":0}}]}'>style</span><span typeof=\"mw:Nowiki\" about=\"#mwt1\" data-parsoid=\"{}\">=</span><span about=\"#mwt1\" data-parsoid=\"{}\">\"background:</span><span typeof=\"mw:Entity\" about=\"#mwt1\" data-parsoid='{\"src\":\"&amp;#35;\",\"srcContent\":\"#\"}'>#</span><span about=\"#mwt1\" data-parsoid=\"{}\">f9f9f9;\"</span>"},{"html":""}]]}'>foo</div>
12083 2. Entities and nowikis inside templated attributes should be handled correctly
12086 |{{table_attribs_3}}
12091 <td style="background:#f9f9f9;">Foo
12096 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td style="background:#f9f9f9;" typeof="mw:Transclusion" about="#mwt1" data-parsoid='{"autoInsertedEnd":true,"pi":[[]]}' data-mw='{"parts":["|",{"template":{"target":{"wt":"table_attribs_3","href":"./Template:Table_attribs_3"},"params":{},"i":0}}]}'>Foo</td></tr>
12101 3. Entities and nowikis inside templated attributes should be handled correctly inside templated tables
12104 |{{table_attribs_3}}
12109 <td style="background:#f9f9f9;">Foo
12113 <table about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[],[],[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"tbl-start","href":"./Template:Tbl-start"},"params":{},"i":0}},"\n|",{"template":{"target":{"wt":"table_attribs_3","href":"./Template:Table_attribs_3"},"params":{},"i":1}},"\n",{"template":{"target":{"wt":"tbl-end","href":"./Template:Tbl-end"},"params":{},"i":2}}]}'>
12114 <tbody><tr><td style="background:#f9f9f9;">Foo</td></tr>
12120 4. Entities and nowikis inside templated attributes should be handled correctly inside templated tables
12123 | {{table_attribs_6}} hi
12128 <td style="background: red;"> hi
12133 <tbody><tr><td style="background: red;" typeof="mw:Transclusion" about="#mwt1" data-parsoid='{"autoInsertedEnd":true,"pi":[[]]}' data-mw='{"parts":["| ",{"template":{"target":{"wt":"table_attribs_6","href":"./Template:Table_attribs_6"},"params":{},"i":0}}," hi"]}'> hi</td></tr>
12138 Templates: HTML Tables: 1. Generating start of a HTML table
12140 {{echo|<table><tr><td>foo</td>}}</tr></table>
12142 <table><tr><td>foo</td></tr></table>
12147 Templates: HTML Tables: 2a. Generating middle of a HTML table
12149 <table><tr>{{echo|<td>foo</td>}}</tr></table>
12151 <table><tr><td>foo</td></tr></table>
12156 Templates: HTML Tables: 2b. Generating middle of a HTML table
12158 <table>{{echo|<tr><td>foo</td></tr>}}</table>
12160 <table><tr><td>foo</td></tr></table>
12165 Templates: HTML Tables: 3. Generating end of a HTML table
12167 <table><tr>{{echo|<td>foo</td></tr></table>}}
12169 <table><tr><td>foo</td></tr></table>
12174 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
12176 {{echo|<table>}}<tr><td>foo</td></tr></table>
12178 <table><tr><td>foo</td></tr></table>
12183 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
12185 <table>{{echo|<tr>}}<td>foo</td></tr></table>
12187 <table><tr><td>foo</td></tr></table>
12192 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
12194 <table><tr>{{echo|<td>}}foo</td></tr></table>
12196 <table><tr><td>foo</td></tr></table>
12201 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
12203 <table><tr><td>foo{{echo|</td>}}</tr></table>
12205 <table><tr><td>foo</td></tr></table>
12210 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
12212 <table><tr><td>foo</td>{{echo|</tr>}}</table>
12214 <table><tr><td>foo</td></tr></table>
12219 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
12221 <table><tr><td>foo</td></tr>{{echo|</table>}}
12223 <table><tr><td>foo</td></tr></table>
12228 Templates: HTML Tables: 5. Proper fostering of categories from inside
12230 parsoid=wt2html,wt2wt
12232 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
12233 <!--Two categories (Bug 50330)-->
12234 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
12236 <link rel="mw:PageProp/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
12237 <!--Two categories (Bug 50330)-->
12238 <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>
12242 Templates: Wiki Tables: 1a. Fostering of entire template content
12250 <tr><td></td></tr></table>
12262 Templates: Wiki Tables: 1b. Fostering of entire template content
12275 <tr><td></td></tr></table>
12289 Templates: Wiki Tables: 2. Fostering of partial template content
12299 <tr><td></td></tr></table>
12312 Templates: Wiki Tables: 3. td-content via multiple templates
12315 {{echo|{{pipe}}a}}{{echo|b}}
12326 Templates: Wiki Tables: 4. Templated tags, no content
12332 <tr><td></td></tr></table>
12337 Templates: Wiki Tables: 5. Templated tags, regular td-tags
12351 Templates: Wiki Tables: 6. Templated tags, templated td-tags
12364 ## This test case is very specific to Parsoid's internals
12365 ## and is hence only tested for Parsoid's code. Parsoid uses
12366 ## a <meta> marker tag for <ref> tags and they are expanded
12367 ## much later. We are verifying that this <meta> tag usage
12368 ## doesn't prevent foster parenting.
12370 Templates: Wiki Tables: 7. Fosterable <ref>s should get fostered
12372 {{PartialTable}}<ref>foo</ref>
12377 <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-mw='{"parts":[{"template":{"target":{"wt":"PartialTable","href":"./Template:PartialTable"},"params":{},"i":0}},"<ref>foo</ref>\n|}"]}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span><table about="#mwt2">
12381 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li></ol>
12385 Templates: Wiki Tables: 8. Fosterable meta-tags should get fostered
12395 <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"\n{{{!}}\n{{!}}-"}},"i":0}},"\n<onlyinclude>\n|foo\n</onlyinclude>\n{{!}}}"]}'>
12396 </span><meta typeof="mw:Includes/OnlyInclude" about="#mwt1"/><table about="#mwt1">
12400 <meta typeof="mw:Includes/OnlyInclude/End"/></td></tr>
12405 Templates: Lists: Multi-line list-items via templates
12407 *{{echo|a {{nonexistent|
12409 *{{echo|b {{nonexistent|
12412 <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>
12413 <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>
12418 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
12420 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
12422 <p><i>ab</i>c<i>d</i>e
12427 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
12428 (PHP parser generates misnested html)
12430 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
12432 <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>
12436 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
12437 (PHP parser generates misnested html; Parsoid html2wt mode adds newlines between {{echo}}s)
12439 parsoid=wt2html,wt2wt
12441 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
12443 <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>
12444 <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>
12445 <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>
12449 Templates: Ugly nesting: 4. Divs opened/closed across templates
12451 a<div>b{{echo|c</div>d}}e
12462 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
12468 |{{echo|foo</table>}}
12472 <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|}"]}'>
12476 <td>foo</td></tr></tbody></table><span about="#mwt1">
12477 </span><span about="#mwt1">|bar</span><span about="#mwt1">
12482 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
12492 <td>1. {{echo|foo </table>}}</td>
12494 <td>2. {{echo|baz </table>}}</td>
12507 <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>"]}'>
12512 <td>1. foo </td></tr></tbody></table></td>
12514 <td>2. baz </td></tr></tbody></table><span about="#mwt2">
12515 </span><span about="#mwt2">
12516 </span><span about="#mwt2">
12517 </span><span about="#mwt2">abc</span><span about="#mwt2">
12518 </span><span about="#mwt2">
12519 </span><span about="#mwt2">
12520 </span><span about="#mwt2">
12521 </span><span about="#mwt2">
12522 </span><span about="#mwt2">
12523 </span><span about="#mwt2">xyz</span><span about="#mwt2">
12524 </span><span about="#mwt2">
12529 Templates: Ugly templates: 3. newline-only template parameter
12538 # This looks like a bug: a single newline triggers p/br for some reason.
12540 Templates: Ugly templates: 4. newline-only template parameter inconsistency
12549 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges that
12550 # have a true overlap (T1-start - T2-start - T1-end - T2-end).
12552 Templates: Ugly templates: 5. Template encapsulation test: Non-trivial overlap of template ranges is properly handled
12558 <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"}],[{"k":"1"}],[{"k":"1"}]]}'>foo
12559 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
12563 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges
12564 # that are "identical" and generate nesting cycles in the algorithm
12566 Templates: Ugly templates: 6. Template encapsulation test: Cyclical nesting of template ranges is properly handled
12568 {{echo|<table><tr><td><table>}}
12572 <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"}],[{"k":"1"}],[{"k":"1"}]]}'><tbody><tr data-parsoid='{"stx":"html"}'><td data-parsoid='{"stx":"html"}'><div data-parsoid='{"stx":"html"}'>
12573 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
12574 </table></td></tr></tbody></table>
12578 Templates: Parameters substituted at the top-level
12580 {{{foo|''who'' {{echo|me}}? '''never!'''}}}
12584 <p><i>who</i> me? <b>never!</b>
12588 <p about="#mwt2" typeof="mw:Param" data-mw='{"parts":[{"templatearg":{"target":{"wt":"foo"},"params":{"1":{"wt":"''who'' {{echo|me}}? '''never!'''"}},"i":0}}]}'><i>who</i> me? <b>never!</b></p>
12590 <p about="#mwt3" typeof="mw:Param" data-mw='{"parts":[{"templatearg":{"target":{"wt":"foo"},"params":{"1":{"wt":"bar"},"2":{"wt":"baz"}},"i":0}}]}'>bar</p>
12594 Parser Functions: 1. Simple example
12603 Parser Functions: 2. Nested use (only outermost should be marked up)
12612 ### Pre-save transform tests
12615 pre-save transform: subst:
12621 This is a test template
12625 pre-save transform: normal template
12635 pre-save transform: nonexistent template
12639 {{thistemplatedoesnotexist}}
12641 {{thistemplatedoesnotexist}}
12645 pre-save transform: subst magic variables
12654 # This is bug 89, which I fixed. -- wtm
12656 pre-save transform: subst: templates with parameters
12660 {{subst:paramtest|param="something else"}}
12662 This is a test template with parameter "something else"
12666 Template:nowikitest
12668 <nowiki>'''not wiki'''</nowiki>
12672 pre-save transform: nowiki in subst (bug 1188)
12676 {{subst:nowikitest}}
12678 <nowiki>'''not wiki'''</nowiki>
12682 Template:commenttest
12684 This template has <!-- a comment --> in it.
12688 pre-save transform: comment in subst (bug 1936)
12692 {{subst:commenttest}}
12694 This template has <!-- a comment --> in it.
12698 pre-save transform: unclosed tag
12702 <nowiki>'''not wiki'''
12704 <nowiki>'''not wiki'''
12708 pre-save transform: mixed tag case
12712 <NOwiki>'''not wiki'''</noWIKI>
12714 <NOwiki>'''not wiki'''</noWIKI>
12718 pre-save transform: unclosed comment in <nowiki>
12722 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
12724 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
12727 # Leading @ in this template definition works around a limitation
12728 # in parsoid's parserTests which otherwise strips the <span> from the
12729 # result (confusing it for a template wrapper)
12733 @<span onmouseover="alert('crap')">Oh no</span>
12737 (confirming safety of fix for subst bug 1936)
12739 {{Template:dangerous}}
12741 <p>@<span>Oh no</span>
12746 pre-save transform: comment containing gallery (bug 5024)
12750 <!-- <gallery>data</gallery> -->
12752 <!-- <gallery>data</gallery> -->
12756 pre-save transform: comment containing extension
12760 <!-- <tag>data</tag> -->
12762 <!-- <tag>data</tag> -->
12766 pre-save transform: comment containing nowiki
12770 <!-- <nowiki>data</nowiki> -->
12772 <!-- <nowiki>data</nowiki> -->
12776 pre-save transform: <noinclude> in subst (bug 3298)
12786 pre-save transform: <onlyinclude> in subst (bug 3298)
12790 {{subst:Includes2}}
12798 {{<includeonly>subst:</includeonly>Includes}}
12802 Template:SafeSubstTest
12804 {{<includeonly>safesubst:</includeonly>Includes}}
12808 bug 22297: safesubst: works during PST
12812 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
12818 bug 22297: safesubst: works during normal parse
12827 subst: does not work during normal parse
12831 <p>{{subst:Includes}}
12836 pre-save transform: context links ("pipe trick")
12840 [[Article (context)|]]
12843 [[Bar:Article (context)|]]
12844 [[:Bar:Article (context)|]]
12846 [[|Article (context)]]
12850 [[Article (context)|Article]]
12851 [[Bar:Article|Article]]
12852 [[:Bar:Article|Article]]
12853 [[Bar:Article (context)|Article]]
12854 [[:Bar:Article (context)|Article]]
12856 [[Article (context)]]
12857 [[Bar:X (Y) Z|X (Y) Z]]
12858 [[:Bar:X (Y) Z|X (Y) Z]]
12862 pre-save transform: context links ("pipe trick") with interwiki prefix
12866 [[interwiki:Article|]]
12867 [[:interwiki:Article|]]
12868 [[interwiki:Bar:Article|]]
12869 [[:interwiki:Bar:Article|]]
12871 [[interwiki:Article|Article]]
12872 [[:interwiki:Article|Article]]
12873 [[interwiki:Bar:Article|Bar:Article]]
12874 [[:interwiki:Bar:Article|Bar:Article]]
12878 pre-save transform: context links ("pipe trick") with parens in title
12880 pst title=[[Somearticle (context)]]
12884 [[Article (context)|Article]]
12888 pre-save transform: context links ("pipe trick") with comma in title
12890 pst title=[[Someplace, Somewhere]]
12893 [[Otherplace, Elsewhere|]]
12894 [[Otherplace, Elsewhere, Anywhere|]]
12896 [[Otherplace, Somewhere|Otherplace]]
12897 [[Otherplace, Elsewhere|Otherplace]]
12898 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
12902 pre-save transform: context links ("pipe trick") with parens and comma
12904 pst title=[[Someplace (IGNORED), Somewhere]]
12907 [[Otherplace (place), Elsewhere|]]
12909 [[Otherplace, Somewhere|Otherplace]]
12910 [[Otherplace (place), Elsewhere|Otherplace]]
12914 pre-save transform: context links ("pipe trick") with comma and parens
12916 pst title=[[Who, me? (context)]]
12919 [[Me, Myself, and I (1937 song)|]]
12921 [[Yes, you. (context)|Yes, you.]]
12922 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
12926 pre-save transform: context links ("pipe trick") with namespace
12928 pst title=[[Ns:Somearticle]]
12932 [[Ns:Article|Article]]
12936 pre-save transform: context links ("pipe trick") with namespace and parens
12938 pst title=[[Ns:Somearticle (context)]]
12942 [[Ns:Article (context)|Article]]
12946 pre-save transform: context links ("pipe trick") with namespace and comma
12948 pst title=[[Ns:Somearticle, Context, Whatever]]
12952 [[Ns:Article, Context, Whatever|Article]]
12956 pre-save transform: context links ("pipe trick") with namespace, comma and parens
12958 pst title=[[Ns:Somearticle, Context (context)]]
12962 [[Ns:Article (context)|Article]]
12966 pre-save transform: context links ("pipe trick") with namespace, parens and comma
12968 pst title=[[Ns:Somearticle (IGNORED), Context]]
12972 [[Ns:Article, Context|Article]]
12976 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
12980 [[Article(context)|]]
12981 [[Bar:Article(context)|]]
12982 [[:Bar:Article(context)|]]
12983 [[|Article(context)]]
12987 [[Article(context)|Article]]
12988 [[Bar:Article(context)|Article]]
12989 [[:Bar:Article(context)|Article]]
12990 [[Article(context)]]
12991 [[Bar:X(Y)Z|X(Y)Z]]
12992 [[:Bar:X(Y)Z|X(Y)Z]]
12996 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
13000 [[Article (context)|]]
13001 [[Bar:Article (context)|]]
13002 [[:Bar:Article (context)|]]
13003 [[|Article (context)]]
13007 [[Article (context)|Article]]
13008 [[Bar:Article (context)|Article]]
13009 [[:Bar:Article (context)|Article]]
13010 [[Article (context)]]
13011 [[Bar:X (Y) Z|X (Y) Z]]
13012 [[:Bar:X (Y) Z|X (Y) Z]]
13016 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
13020 [[Article(context)|]]
13021 [[Bar:Article(context)|]]
13022 [[:Bar:Article(context)|]]
13023 [[|Article(context)]]
13027 [[Article(context)|Article]]
13028 [[Bar:Article(context)|Article]]
13029 [[:Bar:Article(context)|Article]]
13030 [[Article(context)]]
13031 [[Bar:X(Y)Z|X(Y)Z]]
13032 [[:Bar:X(Y)Z|X(Y)Z]]
13036 pre-save transform: context links ("pipe trick") with commas (bug 21660)
13040 [[Article (context), context|]]
13041 [[Article (context),context|]]
13042 [[Bar:Article (context), context|]]
13043 [[Bar:Article (context),context|]]
13044 [[:Bar:Article (context), context|]]
13045 [[:Bar:Article (context),context|]]
13047 [[Article (context), context|Article]]
13048 [[Article (context),context|Article]]
13049 [[Bar:Article (context), context|Article]]
13050 [[Bar:Article (context),context|Article]]
13051 [[:Bar:Article (context), context|Article]]
13052 [[:Bar:Article (context),context|Article]]
13056 pre-save transform: trim trailing empty lines
13060 Empty lines are trimmed
13066 Empty lines are trimmed
13070 pre-save transform: Signature expansion
13075 * <noinclude>~~~</noinclude>
13076 * <includeonly>~~~</includeonly>
13077 * <onlyinclude>~~~</onlyinclude>
13079 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
13080 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
13081 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
13082 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
13087 pre-save transform: Signature expansion in nowiki tags (bug 93)
13093 <nowiki>~~~~</nowiki>
13095 <includeonly><nowiki>~~~~</nowiki></includeonly>
13097 <noinclude><nowiki>~~~~</nowiki></noinclude>
13099 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
13101 {{subst:Foo}} shall be converted to FOO
13103 As well as inside noinclude/onlyinclude
13104 <noinclude>{{subst:Foo}}</noinclude>
13105 <onlyinclude>{{subst:Foo}}</onlyinclude>
13107 But not inside includeonly
13108 <includeonly>{{subst:Foo}}</includeonly>
13112 <nowiki>~~~~</nowiki>
13114 <includeonly><nowiki>~~~~</nowiki></includeonly>
13116 <noinclude><nowiki>~~~~</nowiki></noinclude>
13118 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
13120 FOO shall be converted to FOO
13122 As well as inside noinclude/onlyinclude
13123 <noinclude>FOO</noinclude>
13124 <onlyinclude>FOO</onlyinclude>
13126 But not inside includeonly
13127 <includeonly>{{subst:Foo}}</includeonly>
13131 Parsoid: Recognize nowiki with trailing space in tags
13135 <nowiki ><div>[[foo]]</nowiki >
13143 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
13150 Parsoid: Recognize nowiki with odd capitalization
13154 <noWikI ><div>[[foo]]</Nowiki >
13156 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
13161 Parsoid: Escape nowiki with trailing space in tags
13165 <p><nowiki > foo </nowiki ></p>
13166 <p>a<nowiki />b</p>
13167 <p>c<nowiki/ >d</p>
13169 <nowiki > foo </nowiki >
13177 Parsoid: Escape weird noWikI capitalizations
13181 <p><noWikI > foo </NoWikI ></p>
13183 <noWikI > foo </NoWikI >
13187 ### Message transform tests
13190 message transform: magic variables
13200 message transform: should not transform wiki markup
13210 message transform: <noinclude> in transcluded template (bug 4926)
13220 message transform: <onlyinclude> in transcluded template (bug 4926)
13230 {{#special:}} page name, known
13234 {{#special:Recentchanges}}
13236 Special:RecentChanges
13240 {{#special:}} page name with subpage, known
13244 {{#special:Recentchanges/param}}
13246 Special:RecentChanges/param
13250 {{#special:}} page name, unknown
13254 {{#special:foobar nonexistent}}
13256 Special:Foobar nonexistent
13260 {{#speciale:}} page name, known
13264 {{#speciale:Recentchanges}}
13266 Special:RecentChanges
13270 {{#speciale:}} page name with subpage, known
13274 {{#speciale:Recentchanges/param}}
13276 Special:RecentChanges/param
13280 {{#speciale:}} page name, unknown
13284 {{#speciale:foobar nonexistent}}
13286 Special:Foobar_nonexistent
13292 ### For Parsoid-specific tests, see
13293 #### https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
13298 parsoid=wt2html,wt2wt,html2html
13300 [[Image:foobar.jpg]]
13302 <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>
13305 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13309 Simple image (using File: namespace, now canonical)
13311 [[File:Foobar.jpg]]
13313 <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>
13316 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13320 Right-aligned image
13322 [[File:Foobar.jpg|right]]
13324 <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>
13327 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure>
13333 [[File:Foobar.jpg|right|Caption text]]
13335 <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>
13338 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption text</figcaption></figure>
13342 Image with caption, bug 53312 #1
13344 [[File:Foobar.jpg|right|Caption page stuff]]
13346 <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>
13349 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption page stuff</figcaption></figure>
13353 Image with caption, bug 53312 #2
13355 [[File:Foobar.jpg|right|Caption page=]]
13357 <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>
13360 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption page=</figcaption></figure>
13364 Image with caption, bug 53312 #3
13366 [[File:Foobar.jpg|right|Caption page=stuff]]
13368 <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>
13371 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption page=stuff</figcaption></figure>
13375 Allow empty links in image captions (Bug 60753)
13379 [[File:Foobar.jpg|thumb|Caption [[Link1]]
13384 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Caption <a href="/index.php?title=Link1&action=edit&redlink=1" class="new" title="Link1 (page does not exist)">Link1</a> [[]] <a href="/index.php?title=Link2&action=edit&redlink=1" class="new" title="Link2 (page does not exist)">Link2</a></div></div></div>
13387 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"caption","ak":"Caption [[Link1]]\n[[]]\n[[Link2]]\n"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>Caption <a rel="mw:WikiLink" href="./Link1" title="Link1" data-parsoid='{"stx":"simple","a":{"href":"./Link1"},"sa":{"href":"Link1"}}'>Link1</a>
13389 <a rel="mw:WikiLink" href="./Link2" title="Link2" data-parsoid='{"stx":"simple","a":{"href":"./Link2"},"sa":{"href":"Link2"}}'>Link2</a>
13390 </figcaption></figure>
13394 Titles in unlinked images (T23454)
13396 [[File:Foobar.jpg|link=|stuff]]
13398 <p><img alt="stuff" src="http://example.com/images/3/3a/Foobar.jpg" title="stuff" width="1941" height="220" />
13403 Link with empty target
13412 Image with link trail
13414 Linktrails should not work for images: [[File:Foobar.jpg]]s
13416 <p>Linktrails should not work for images: <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>s
13419 <p>Linktrails should not work for images: <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span>s</p>
13423 Image with empty attribute
13425 parsoid=wt2html,wt2wt,html2html
13427 [[File:Foobar.jpg|right||Caption text]]
13429 <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>
13432 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption text</figcaption></figure>
13436 1. Block image with individual attributes from templates
13438 [[File:Foobar.jpg|thumb|{{echo|137px}}|This is a caption]]
13440 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This is a caption</div></div></div>
13443 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" about="#mwt2" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"{{echo|137px}}"},{"ck":"caption","ak":"This is a caption"}]}' data-mw='{"attribs":[["thumbnail",{"html":"thumb"}],["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[24,38,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"137px\"}},\"i\":0}}]}'>137px</span>"}]]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="16" width="137" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"16","width":"137"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>This is a caption</figcaption></figure>
13447 2. Block Image with individual attributes from templates
13449 [[File:Foobar.jpg|{{echo|thumb}}|{{echo|137px}}|This is a caption]]
13451 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This is a caption</div></div></div>
13454 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" about="#mwt3" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"{{echo|thumb}}"},{"ck":"width","ak":"{{echo|137px}}"},{"ck":"caption","ak":"This is a caption"}]}' data-mw='{"attribs":[["thumbnail",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[18,32,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"thumb\"}},\"i\":0}}]}'>thumb</span>"}],["width",{"html":"<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[33,47,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"137px\"}},\"i\":0}}]}'>137px</span>"}]]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="16" width="137" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"16","width":"137"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>This is a caption</figcaption></figure>
13458 3. Inline image with individual attributes from templates
13460 [[File:Foobar.jpg|{{echo|50px}}]]
13462 <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>
13465 <p><span typeof="mw:Image mw:ExpandedAttrs" about="#mwt2" data-parsoid='{"optList":[{"ck":"width","ak":"{{echo|50px}}"}]}' data-mw='{"attribs":[["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[18,31,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"50px\"}},\"i\":0}}]}'>50px</span>"}]]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
13468 ## Parsoid does not provide editing support for images where templates produce multiple image attributes.
13469 ## To signal this, we add a 'mw:Placeholder' type to such images. This could change in the future.
13471 Image with multiple attributes from the same template
13473 [[File:Foobar.jpg|{{image_attribs}}]]
13475 <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>
13478 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption text</figcaption></figure>
13482 Image with link tails
13486 123[[File:Foobar.jpg]]456
13487 123[[File:Foobar.jpg|right]]456
13488 123[[File:Foobar.jpg|thumb]]456
13490 <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
13492 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
13493 123<div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div></div></div></div>456
13496 <p>123<a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>456</p>
13498 <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>
13500 <div class="thumb tright">
13501 <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>
13502 <div class="thumbcaption">
13503 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
13509 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span>456</p>
13510 <p>123</p><figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure><p>456</p>
13511 <p>123</p><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a></figure><p>456</p>
13515 Image with multiple captions -- only last one is accepted
13517 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
13519 <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>
13522 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Caption3 - accepted</figcaption></figure>
13526 Image with multiple widths -- use last
13528 [[File:Foobar.jpg|200px|300px|caption]]
13530 <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>
13533 <p><span typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="34" width="300"/></a></span></p>
13537 Image with multiple alignments -- use first (bug 48664)
13541 [[File:Foobar.jpg|thumb|left|right|center|caption]]
13543 [[File:Foobar.jpg|middle|text-top|caption]]
13545 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
13546 <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>
13549 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
13550 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13554 Image with width attribute at different positions
13556 [[File:Foobar.jpg|200px|right|Caption]]
13557 [[File:Foobar.jpg|right|200px|Caption]]
13558 [[File:Foobar.jpg|right|Caption|200px]]
13560 <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>
13561 <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>
13562 <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>
13565 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="23" width="200"/></a><figcaption>Caption</figcaption></figure>
13566 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="23" width="200"/></a><figcaption>Caption</figcaption></figure>
13567 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="23" width="200"/></a><figcaption>Caption</figcaption></figure>
13570 # a sad bit of backward-compatibility
13572 Image with size specified with pxpx (bug 13500, 51628)
13574 parsoid=wt2html,wt2wt,html2html
13576 [[File:Foobar.jpg|20pxpx]]
13577 [[File:Foobar.jpg|200x20pxpx]]
13579 <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>
13580 <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>
13583 <p><span typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/20px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="2" width="20"/></a></span> <span typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/177px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="20" width="177"/></a></span></p>
13587 Image with link parameter, wiki target
13589 [[File:Foobar.jpg|link=Main Page]]
13591 <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>
13594 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13597 # parsoid bug 49293 (part 1)
13599 Image with link parameter, URL target
13601 [[File:Foobar.jpg|link=http://example.com/]]
13603 <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>
13606 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13609 # parsoid bug 49293 (part 2)
13611 Image with link parameter, protocol-less URL target
13613 [[File:Foobar.jpg|link=//example.com/]]
13615 <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>
13618 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13622 Escaping non-block captions (T107435)
13625 "modes": ["wt2wt"],
13627 ["[typeof~='mw:Image']", "attr", "data-mw", "{\"caption\": \"|\"}"]
13631 [[Image:Foobar.jpg|caption]]
13633 [[Image:Foobar.jpg|<nowiki>|</nowiki>]]
13636 # wgExternalLinkTarget not supported by Parsoid
13638 Image with link parameter, wgExternalLinkTarget
13640 [[Image:foobar.jpg|link=http://example.com/]]
13642 wgExternalLinkTarget='foobar'
13644 <p><a href="http://example.com/" target="foobar" rel="nofollow noreferrer noopener"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
13649 Image with link parameter, wgNoFollowLinks set to false
13651 [[Image:foobar.jpg|link=http://example.com/]]
13653 wgNoFollowLinks=false
13655 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
13660 Image with link parameter, wgNoFollowDomainExceptions
13662 [[Image:foobar.jpg|link=http://example.com/]]
13664 wgNoFollowDomainExceptions='example.com'
13666 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
13670 # wgExternalLinkTarget not supported by Parsoid
13672 Image with link parameter, wgExternalLinkTarget, unnamed parameter
13674 [[Image:foobar.jpg|link=http://example.com/|Title]]
13676 wgExternalLinkTarget='foobar'
13678 <p><a href="http://example.com/" title="Title" target="foobar" rel="nofollow noreferrer noopener"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
13683 Image with empty link parameter
13685 [[File:Foobar.jpg|link=]]
13687 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
13690 <p><span class="mw-default-size" typeof="mw:Image"><span><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></span></span></p>
13694 Image with link parameter (wiki target) and unnamed parameter
13696 [[File:Foobar.jpg|link=Main_Page|Title]]
13698 <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>
13701 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13705 Image with link parameter (URL target) and unnamed parameter
13707 [[File:Foobar.jpg|link=http://example.com/|Title]]
13709 <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>
13712 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
13716 Thumbnail image with link parameter
13719 parsoid=wt2html,wt2wt,html2html
13721 [[File:Foobar.jpg|thumb|link=http://example.com/|Title]]
13723 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="http://example.com/"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
13726 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>Title</figcaption></figure>
13730 Manually-specified thumbnail image
13734 [[File:Foobar.jpg|thumb=Thumb.png|Title]]
13736 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/File:Foobar.jpg"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
13739 <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" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
13743 Manually-specified thumbnail image with explicit link to wiki page
13746 parsoid=wt2html,wt2wt,html2html
13748 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|Title]]
13750 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
13753 <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" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
13757 Manually-specified thumbnail image with explicit link to url
13760 parsoid=wt2html,wt2wt,html2html
13762 [[File:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
13764 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="http://example.com"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
13767 <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" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
13771 Manually-specified thumbnail image with explicit no link
13774 parsoid=wt2html,wt2wt,html2html
13776 [[File:Foobar.jpg|thumb=Thumb.png|link=|Title]]
13778 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
13781 <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" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></span><figcaption>Title</figcaption></figure>
13785 Manually-specified thumbnail image with explicit link and alt text
13788 parsoid=wt2html,wt2wt,html2html
13790 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|alt=alttext|Title]]
13792 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="alttext" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Title</div></div></div>
13795 <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" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
13799 Image with frame and link
13801 parsoid=wt2html,wt2wt,html2html
13803 [[File:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
13805 <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>
13808 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page" title="Main Page">Main Page</a></figcaption></figure>
13812 Image with frame and link and explicit alt
13814 parsoid=wt2html,wt2wt,html2html
13816 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
13818 <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>
13821 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page" title="Main Page">Main Page</a></figcaption></figure>
13825 Image with wiki markup in implicit alt
13827 [[Image:Foobar.jpg|testing '''bold''' in alt]]
13829 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
13831 <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>
13832 </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>
13835 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"testing '''bold''' in alt"}]}' data-mw='{"caption":"testing <b data-parsoid='{\"dsr\":[27,37,3,3]}'>bold</b> in alt"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"Image:Foobar.jpg"}}'/></a></span></p>
13837 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"alt","ak":"alt=testing '''bold''' in alt"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img alt="testing bold in alt" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"alt":"testing bold in alt","resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"alt":"alt=testing '''bold''' in alt","resource":"Image:Foobar.jpg"}}'/></a></span></p>
13841 Alt image option should handle most kinds of wikitext without barfing
13843 [[Image:Foobar.jpg|thumb|This is the image caption|alt=This is a [[link]] and a {{echo|''bold template''}}.]]
13845 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="This is a link and a bold template." src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This is the image caption</div></div></div>
13848 <figure class="mw-default-size" typeof="mw:Image/Thumb mw:ExpandedAttrs" about="#mwt2" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"caption","ak":"This is the image caption"},{"ck":"alt","ak":"alt=This is a [[link]] and a {{echo|''bold template''}}."}]}' data-mw='{"attribs":[["thumbnail",{"html":"thumb"}],["alt",{"html":"alt=This is a <a rel=\"mw:WikiLink\" href=\"./Link\" title=\"Link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Link\"},\"sa\":{\"href\":\"link\"},\"dsr\":[65,73,2,2]}'>link</a> and a <i about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"dsr\":[80,106,null,null],\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"&#39;&#39;bold template&#39;&#39;\"}},\"i\":0}}]}'>bold template</i>."}]]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img alt="This is a link and a bold template." resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220" data-parsoid='{"a":{"alt":"This is a link and a bold template.","resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"alt":"alt=This is a [[link]] and a {{echo|''bold template''}}.","resource":"Image:Foobar.jpg"}}'/></a><figcaption>This is the image caption</figcaption></figure>
13851 ###################
13852 # Conflicting image format options.
13853 # First option specified should 'win'.
13854 # All three cases in each test should be identical.
13857 Image with 'frameless' first.
13859 parsoid=wt2html,wt2wt,html2html
13861 [[File:Foobar.jpg|frameless|caption]]
13863 [[File:Foobar.jpg|frameless|frame|caption]]
13865 [[File:Foobar.jpg|frameless|thumb|caption]]
13867 <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>
13868 </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>
13869 </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>
13872 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a></span></p>
13873 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a></span></p>
13874 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a></span></p>
13878 Image with 'frame' first.
13880 parsoid=wt2html,wt2wt,html2html
13882 [[File:Foobar.jpg|frame|caption]]
13883 [[File:Foobar.jpg|frame|frameless|caption]]
13884 [[File:Foobar.jpg|frame|thumb|caption]]
13886 <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>
13887 <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>
13888 <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>
13891 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
13892 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
13893 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
13897 Image with 'thumb' first.
13899 parsoid=wt2html,wt2wt,html2html
13901 [[File:Foobar.jpg|thumb|caption]]
13902 [[File:Foobar.jpg|thumb|frameless|caption]]
13903 [[File:Foobar.jpg|thumb|frame|caption]]
13905 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
13906 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
13907 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
13910 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
13911 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
13912 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
13915 ###################
13917 # See https://www.mediawiki.org/wiki/Help:Images#Size_and_frame
13918 # and https://phabricator.wikimedia.org/T64258
13919 # Foobar has actual size of 1941x220
13920 # 1. Thumbs & frameless always reduce, can't be enlarged unless it's
13921 # a scalable format.
13922 # 2. Framed images always ignore size options; always render at default size.
13923 # 3. "Unspecified format" and border are the only types which can be
13927 Image: "unspecified format" and border enlarge
13929 parsoid=wt2html,wt2wt,html2html
13931 [[File:Foobar.jpg|2000px]]
13933 [[File:Foobar.jpg|border|2000px]]
13935 <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>
13936 </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>
13939 <p><span typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/1941px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="227" width="2000"/></a></span></p>
13940 <p><span class="mw-image-border" typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/1941px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="227" width="2000"/></a></span></p>
13944 Image: "unspecified format" and border reduce
13946 parsoid=wt2html,wt2wt,html2html
13948 [[File:Foobar.jpg|1000px]]
13950 [[File:Foobar.jpg|border|1000px]]
13952 <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>
13953 </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>
13956 <p><span typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/1000px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="113" width="1000"/></a></span></p>
13957 <p><span class="mw-image-border" typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/1000px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="113" width="1000"/></a></span></p>
13961 Image: thumbs reduce
13963 parsoid=wt2html,wt2wt,html2html
13965 [[File:Foobar.jpg|thumb|50px]]
13967 <div class="thumb tright"><div class="thumbinner" style="width:52px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div></div></div></div>
13970 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50"/></a></figure>
13974 Image: bitmap thumbs can't be enlarged past original size, but vector can.
13976 parsoid=wt2html,wt2wt,html2html
13978 [[File:Foobar.jpg|thumb|2000px]]
13980 [[File:Foobar.svg|thumb|2000px]]
13982 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div></div></div></div>
13983 <div class="thumb tright"><div class="thumbinner" style="width:2002px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="Foobar.svg" src="http://example.com/images/thumb/f/ff/Foobar.svg/2000px-Foobar.svg.png" width="2000" height="1500" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/3000px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/4000px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"></a></div></div></div></div>
13986 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/1941px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure>
13987 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/thumb/f/ff/Foobar.svg/240px-Foobar.svg" data-file-width="240" data-file-height="180" data-file-type="drawing" height="1500" width="2000"/></a></figure>
13991 Image: frameless can reduce in size
13993 parsoid=wt2html,wt2wt,html2html
13995 [[File:Foobar.jpg|frameless|50px]]
13997 <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>
14000 <p><span typeof="mw:Image/Frameless"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50"/></a></span></p>
14004 Image: bitmap frameless can't be enlarged past original size, but vector can
14006 parsoid=wt2html,wt2wt,html2html
14008 [[File:Foobar.jpg|frameless|2000px]]
14010 [[File:Foobar.svg|frameless|2000px]]
14012 <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>
14013 </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>
14016 <p><span typeof="mw:Image/Frameless"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/1941px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
14017 <p><span typeof="mw:Image/Frameless"><a href="./File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/thumb/f/ff/Foobar.svg/240px-Foobar.svg" data-file-width="240" data-file-height="180" data-file-type="drawing" height="1500" width="2000"/></a></span></p>
14021 Image: framed images are always unscaled.
14023 parsoid=wt2html,wt2wt,html2html
14025 [[File:Foobar.jpg|frame]]
14027 [[File:Foobar.jpg|frame|50px]]
14029 [[File:Foobar.jpg|frame|50x50px]]
14031 [[File:Foobar.jpg|frame|2000px]]
14033 <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>
14034 <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>
14035 <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>
14036 <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>
14039 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure>
14040 <figure typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure>
14041 <figure typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure>
14042 <figure typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></figure>
14045 ###################
14048 Link to image page- image page normally doesn't exists, hence edit link
14049 Add test with existing image page
14050 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
14054 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
14059 bug 18784 Link to non-existent image page with caption should use caption as link text
14061 [[:Image:test|caption]]
14063 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
14068 Frameless image caption with a free URL
14070 [[File:Foobar.jpg|http://example.com]]
14072 <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>
14075 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"http://example.com"}]}' data-mw='{"caption":"<a rel=\"mw:ExtLink\" href=\"http://example.com\" data-parsoid='{\"stx\":\"url\",\"dsr\":[18,36,0,0]}'>http://example.com</a>"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14079 Thumbnail image caption with a free URL
14083 [[File:Foobar.jpg|thumb|http://example.com]]
14085 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
14088 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
14092 Thumbnail image caption with a free URL and explicit alt
14095 parsoid=wt2html,wt2wt,html2html
14097 [[File:Foobar.jpg|thumb|http://example.com|alt=Alteration]]
14099 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
14102 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
14106 SVG thumbnails with no language set
14109 [[File:Foobar.svg|thumb|caption]]
14111 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
14114 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="./File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/thumb/f/ff/Foobar.svg/220px-Foobar.svg" data-file-width="240" data-file-height="180" data-file-type="drawing" height="165" width="220"/></a><figcaption>caption</figcaption></figure>
14118 SVG thumbnails with language de
14120 parsoid=wt2html,wt2wt,html2html
14122 [[File:Foobar.svg|thumb|caption|lang=de]]
14124 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=File:Foobar.svg&lang=de" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/langde-180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/langde-270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/langde-360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
14127 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="./File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/thumb/f/ff/Foobar.svg/220px-Foobar.svg" lang="de" data-file-width="240" data-file-height="180" data-file-type="drawing" height="165" width="220"/></a><figcaption>caption</figcaption></figure>
14131 SVG thumbnails with invalid language code
14133 parsoid=wt2html,wt2wt,html2html
14135 [[File:Foobar.svg|thumb|caption|lang=invalid.language.code]]
14137 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"></a></div>lang=invalid.language.code</div></div></div>
14140 <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" data-file-width="240" data-file-height="180" data-file-type="drawing" height="165" width="220"/></a><figcaption>lang=invalid.language.code</figcaption></figure>
14144 BUG 1887: A ISBN with a thumbnail
14146 [[File:Foobar.jpg|thumb|ISBN 1235467890]]
14148 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div><a href="/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div>
14151 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a href="./Special:BookSources/1235467890" rel="mw:WikiLink">ISBN 1235467890</a></figcaption></figure>
14155 BUG 1887: A RFC with a thumbnail
14157 [[File:Foobar.jpg|thumb|This is RFC 12354]]
14159 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
14162 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>This is <a href="//tools.ietf.org/html/rfc12354" rel="mw:ExtLink">RFC 12354</a></figcaption></figure>
14166 BUG 1887: A mailto link with a thumbnail
14168 [[File:Foobar.jpg|thumb|Please mailto:nobody@example.com]]
14170 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>Please <a rel="nofollow" class="external free" href="mailto:nobody@example.com">mailto:nobody@example.com</a></div></div></div>
14173 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>Please <a rel="mw:ExtLink" href="mailto:nobody@example.com">mailto:nobody@example.com</a></figcaption></figure>
14176 # Pending resolution to bug 368
14178 BUG 648: Frameless image caption with a link
14180 [[File:Foobar.jpg|text with a [[link]] in it]]
14182 <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>
14185 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"text with a [[link]] in it"}]}' data-mw='{"caption":"text with a <a rel=\"mw:WikiLink\" href=\"./Link\" title=\"Link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Link\"},\"sa\":{\"href\":\"link\"},\"dsr\":[30,38,2,2]}'>link</a> in it"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14189 BUG 648: Frameless image caption with a link (suffix)
14191 [[File:Foobar.jpg|text with a [[link]]foo in it]]
14193 <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>
14196 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"text with a [[link]]foo in it"}]}' data-mw='{"caption":"text with a <a rel=\"mw:WikiLink\" href=\"./Link\" title=\"Link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Link\"},\"sa\":{\"href\":\"link\"},\"dsr\":[30,41,2,5],\"tail\":\"foo\"}'>linkfoo</a> in it"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14200 BUG 648: Frameless image caption with an interwiki link
14202 [[File:Foobar.jpg|text with a [[MeatBall:Link]] in it]]
14204 <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>
14207 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"text with a [[MeatBall:Link]] in it"}]}' data-mw='{"caption":"text with a <a rel=\"mw:ExtLink\" href=\"http://www.usemod.com/cgi-bin/mb.pl?Link\" title=\"meatball:Link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"http://www.usemod.com/cgi-bin/mb.pl?Link\"},\"sa\":{\"href\":\"MeatBall:Link\"},\"isIW\":true,\"dsr\":[30,47,2,2]}'>MeatBall:Link</a> in it"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14211 BUG 648: Frameless image caption with a piped interwiki link
14213 [[File:Foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
14215 <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>
14218 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"text with a [[MeatBall:Link|link]] in it"}]}' data-mw='{"caption":"text with a <a rel=\"mw:ExtLink\" href=\"http://www.usemod.com/cgi-bin/mb.pl?Link\" title=\"meatball:Link\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"http://www.usemod.com/cgi-bin/mb.pl?Link\"},\"sa\":{\"href\":\"MeatBall:Link\"},\"isIW\":true,\"dsr\":[30,52,16,2]}'>link</a> in it"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14222 T107474: Frameless image caption with <nowiki>
14224 [[File:Foobar.jpg|<nowiki>text with a [[MeatBall:Link|link]] in it</nowiki>]]
14226 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"<nowiki>text with a [[MeatBall:Link|link]] in it</nowiki>"}]}' data-mw='{"caption":"<span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[18,75,8,9]}'>text with a [[MeatBall:Link|link]] in it</span>"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14230 Escape HTML special chars in image alt text
14232 [[File:Foobar.jpg|& < > "]]
14234 <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>
14237 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"& < > \""}]}' data-mw='{"caption":"&amp; &lt; > \""}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14241 Escape HTML special chars in image alt text with LanguageConverter
14245 [[File:Foobar.jpg|& < > "]]
14247 <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>
14250 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"& < > \""}]}' data-mw='{"caption":"&amp; &lt; > \""}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14254 Entities in file name and attributes
14256 [[File:7%25 solution.gif|manualthumb=7%25 solution.gif|link=7%25 solution|[[7%25 solution]]]]
14258 <p><a href="/index.php?title=Special:Upload&wpDestFile=7%25_solution.gif" class="new" title="File:7% solution.gif">7% solution</a>
14261 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-parsoid='{"optList":[{"ck":"bogus","ak":"manualthumb=7%25 solution.gif"},{"ck":"link","ak":"link=7%25 solution"},{"ck":"caption","ak":"[[7%25 solution]]"}]}' data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"<a rel=\"mw:WikiLink\" href=\"./7%25_solution\" title=\"7% solution\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./7%25_solution\"},\"sa\":{\"href\":\"7%25 solution\"},\"dsr\":[74,91,2,2]}'>7% solution</a>"}'><a href="./7%25_solution" data-parsoid='{"a":{"href":"./7%25_solution"},"sa":{"href":"link=7%25 solution"}}'><img resource="./File:7%25_solution.gif" src="./Special:FilePath/7%25_solution.gif" height="220" width="220" data-parsoid='{"a":{"resource":"./File:7%25_solution.gif","height":"220","width":"220"},"sa":{"resource":"File:7%25 solution.gif"}}'/></a></span></p>
14265 BUG 499: Alt text should have Ӓ, not &1234;
14267 [[File:Foobar.jpg|♀]]
14269 <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>
14272 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"&#9792;"}]}' data-mw='{"caption":"<span typeof=\"mw:Entity\" data-parsoid='{\"src\":\"&amp;#9792;\",\"srcContent\":\"♀\",\"dsr\":[18,25,null,null]}'>♀</span>"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14276 Broken image caption with link
14278 parsoid=wt2html,wt2wt,html2html
14280 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
14282 <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.
14285 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="Main_Page" title="Main Page">this</a> is just an ordinary link.</p>
14289 Image caption containing another image
14291 [[File:Foobar.jpg|thumb|This is a caption with another [[File:Thumb.png|image]] inside it!]]
14293 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This is a caption with another <a href="/wiki/File:Thumb.png" class="image" title="image"><img alt="image" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" /></a> inside it!</div></div></div>
14296 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" 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" data-file-width="135" data-file-height="135" data-file-type="bitmap" height="135" width="135"/></a></span> inside it!</figcaption></figure>
14300 Image: caption containing a newline
14302 [[File:Foobar.jpg|This
14305 <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>
14308 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
14312 Image: caption containing leading space
14313 (The leading space should not trigger nowiki escaping in wt2wt mode)
14315 [[File:Foobar.jpg|thumb| bar]]
14317 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>bar</div></div></div>
14320 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption> bar</figcaption></figure>
14324 Image: caption containing a table
14326 parsoid=wt2html,wt2wt,html2html
14328 [[Image:Foobar.jpg|thumb|200px|This is an example image thumbnail caption with a table
14334 and some more text.]]
14336 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This is an example image thumbnail caption with a table <table> <tr> <th> Foo </th> <th> Bar </th></tr> <tr> <td> Foo1 </td> <td> Bar1 </td></tr></table> and some more text.</div></div></div>
14339 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="23" width="200"/></a><figcaption>This is an example image thumbnail caption with a table
14342 <tr><th>Foo </th><th>Bar</th></tr>
14345 <td>Bar1</td></tr></tbody></table>and some more text.</figcaption></figure>
14349 Bug 3090: External links other than http: in image captions
14351 [[File:Foobar.jpg|thumb|200x200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
14353 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>This caption has <a rel="nofollow" class="external text" href="irc://example.net">irc</a> and <a rel="nofollow" class="external text" href="https://example.com">Secure</a> ext links in it.</div></div></div>
14356 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" 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>
14362 parsoid=wt2html,wt2wt,html2html
14364 [[Image:foobar.jpg|a|class=b]]
14366 <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>
14369 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
14373 Localized image handling (1).
14375 parsoid=wt2html,wt2wt,html2html
14378 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
14380 <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>
14383 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
14387 Localized image handling (2).
14390 parsoid=wt2html,wt2wt,html2html
14393 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
14395 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/Foo" title="Foo"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/Archivo:Foobar.jpg" class="internal" title="Aumentar"></a></div>caption</div></div></div>
14398 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
14402 Localized image handling (3).
14407 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a></figure>
14409 [[File:Foobar.jpg|بندانگشتی]]
14413 "border", "frameless" and "class" attributes on an image.
14416 parsoid=wt2html,wt2wt,html2html
14418 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
14420 <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>
14423 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a></span></p>
14426 # Note that 'right' is the default alignment, despite the misspelled 'righ' below
14428 Invalid image attributes (bug 62500)
14431 parsoid=wt2html,wt2wt,html2html
14433 [[File:Foobar.jpg|thumb|float|left|caption]]
14435 [[File:Foobar.jpg|thumb|righ|caption]]
14437 [[File:Foobar.jpg|bogus1|thumb|bogus2|left|bogus3|caption]]
14439 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
14440 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
14441 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>caption</div></div></div>
14444 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
14445 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
14446 <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/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
14452 #REDIRECT [[File:Barfoo.jpg]]
14455 # FIXME: Parsoid should run this test -- but we'd need to teach the
14456 # mockAPI about the redirected Barfoo.jpg image.
14460 [[Image:Barfoo.jpg]]
14462 <p><a href="/wiki/File:Barfoo.jpg" class="mw-redirect" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
14467 Missing image with uploads disabled
14471 [[File:Foobaz.jpg]]
14473 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
14476 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Foobaz.jpg"><img resource="./File:Foobaz.jpg" src="./Special:FilePath/Foobaz.jpg" height="220" width="220"/></a></span></p>
14479 # Parsoid-specific testing for images
14480 # https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
14481 # Currently imperfect due to a flaw in the Parsoid testrunner
14483 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
14487 Parsoid-specific image handling - simple image with size and middle alignment
14489 [[File:Foobar.jpg|middle|50px]]
14491 <p><span class="mw-valign-middle" typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50"/></a></span></p>
14495 Parsoid-specific image handling - simple image with size, middle alignment,
14496 non-standard namespace alias
14498 parsoid=wt2wt,wt2html,html2html
14500 [[Image:Foobar.jpg|middle|50px]]
14502 <p><span class="mw-valign-middle" typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50"/></a></span></p>
14506 Parsoid-specific image handling - simple image with size and middle alignment
14509 [[File:Foobar.jpg|50px|middle]]
14511 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14515 Parsoid-specific image handling - simple image with size and middle alignment
14516 and non-standard namespace name
14518 parsoid=wt2html,wt2wt,html2html
14520 [[Image:Foobar.jpg|50px|middle]]
14522 <p><span class="mw-valign-middle" typeof="mw:Image"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50"/></a></span></p>
14526 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
14528 [[File:Foobar.jpg|500x10px|baseline|caption]]
14530 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="10" width="89" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"10","width":"89"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14534 Parsoid-specific image handling - simple image with border and size spec
14536 [[File:Foobar.jpg|50px|border|caption]]
14538 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14542 Parsoid-specific image handling - thumbnail with halign, valign, and caption
14544 [[File:Foobar.jpg|left|baseline|thumb|caption content]]
14546 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption content</figcaption></figure>
14550 Parsoid-specific image handling - thumbnail with halign, valign, and caption
14553 [[File:Foobar.jpg|thumb|left|baseline|caption content]]
14555 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" 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>
14559 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
14561 [[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
14563 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="6" width="50"/></a><figcaption>caption</figcaption></figure>
14567 Parsoid-specific image handling - thumbnail with specific size, halign,
14568 valign, and caption (existing content)
14570 [[File:Foobar.jpg|thumb|50x50px|right|middle|caption]]
14572 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" 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>
14576 Parsoid-specific image handling - framed image with specific size and caption
14579 parsoid=wt2html,wt2wt,html2html
14581 [[File:Foobar.jpg|frame|500x50px|caption]]
14583 <figure typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
14587 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
14590 parsoid=wt2html,wt2wt,html2html
14592 [[File:Foobar.jpg|left|baseline|frame|500x50px|caption]]
14594 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
14598 Parsoid-specific image handling - frameless image with specific size, border, and caption
14600 [[File:Foobar.jpg|frameless|442x50px|border|caption]]
14602 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="50" width="442" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"50","width":"442"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14606 Parsoid-specific image handling - simple image with a formatted caption
14608 [[File:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
14610 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>"}]}' data-mw='{"caption":"<table data-parsoid='{\"stx\":\"html\",\"dsr\":[18,81,7,8]}'><tbody data-parsoid='{\"dsr\":[25,73,0,0]}'><tr data-parsoid='{\"stx\":\"html\",\"dsr\":[25,54,4,5]}'><td data-parsoid='{\"stx\":\"html\",\"dsr\":[29,39,4,5]}'>a</td><td data-parsoid='{\"stx\":\"html\",\"dsr\":[39,49,4,5]}'>b</td></tr><tr data-parsoid='{\"stx\":\"html\",\"dsr\":[54,73,4,5]}'><td data-parsoid='{\"stx\":\"html\",\"dsr\":[58,68,4,5]}'>c</td></tr></tbody></table>"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14614 Parsoid-specific image handling - caption with a template in it
14616 [[File:Foobar.jpg|thumb|200x23px|This caption has a {{echo|transclusion}} in it.]]
14618 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" 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>
14622 Parsoid-specific image handling - caption with unbalanced tags in it
14624 parsoid=wt2html,wt2wt,html2html
14627 [[File:Foobar.jpg|thumb|200x200px|This caption has a <center>unbalanced tag in it.]]
14631 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="23" width="200"/></a><figcaption>This caption has a <center>unbalanced tag in it.</center></figcaption></figure>
14636 Parsoid-specific image handling - empty caption (1)
14638 parsoid=wt2html,wt2wt
14640 [[File:Foobar.jpg|thumb|]]
14642 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption></figcaption></figure>
14645 # empty captions don't get serialized unless we're in the "round trip" case
14647 Parsoid-specific image handling - empty caption (2)
14651 <figure class="mw-default-size" typeof="mw:Image/Thumb">
14652 <a href="./File:Foobar.jpg">
14653 <img resource="./File:Foobar.jpg"
14654 src="//example.com/images/3/3a/Foobar.jpg"
14655 data-file-width="1941" data-file-height="220" data-file-type="bitmap"
14656 height="25" width="220"/>
14658 <figcaption></figcaption>
14661 [[File:Foobar.jpg|thumb]]
14665 Parsoid-specific image handling - whitespace caption
14667 [[File:Foobar.jpg|thumb| ]]
14669 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption> </figcaption></figure>
14673 Parsoid-specific image handling - lang option
14676 [[File:Foobar.svg|lang=de|caption]]
14680 <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" data-file-width="240" data-file-height="180" data-file-type="drawing" height="180" width="240"/></a></span>
14684 ## Edge case bugs in Parsoid from T93580
14686 T93580: 1. Templated <ref> inside block images
14688 [[File:Foobar.jpg|thumb|Caption with templated ref: {{echo|<ref>foo</ref>}}]]
14692 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"caption","ak":"Caption with templated ref: {{echo|<ref>foo</ref>}}"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>Caption with templated ref: <span about="#mwt5" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<ref>foo</ref>"}},"i":0}}]}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></figcaption></figure>
14694 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo</span></li></ol>
14698 T93580: 2. <ref> inside inline images
14700 [[File:Foobar.jpg|Undisplayed caption in inline image with ref: <ref>foo</ref>]]
14704 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"Undisplayed caption in inline image with ref: <ref>foo</ref>"}]}' data-mw='{"caption":"Undisplayed caption in inline image with ref: <span about=\"#mwt2\" class=\"mw-ref\" id=\"cite_ref-1\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid='{\"dsr\":[64,78,5,6]}' data-mw='{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-1\"},\"attrs\":{}}'><a href=\"./Main_Page#cite_note-1\" style=\"counter-reset: mw-Ref 1;\" data-parsoid=\"{}\"><span class=\"mw-reflink-text\" data-parsoid=\"{}\">[1]</span></a></span><meta typeof=\"mw:Extension/ref/Marker\" about=\"#mwt2\" data-parsoid='{\"group\":\"\",\"name\":\"\",\"content\":\"foo\",\"hasRefInRef\":false,\"dsr\":[64,78,5,6]}'/>"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14706 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo</span></li></ol>
14710 T93580: 3. Templated <ref> inside inline images
14712 [[File:Foobar.jpg|Undisplayed caption in inline image with ref: {{echo|<ref>{{echo|foo}}</ref>}}]]
14716 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"caption","ak":"Undisplayed caption in inline image with ref: {{echo|<ref>{{echo|foo}}</ref>}}"}]}' data-mw='{"caption":"Undisplayed caption in inline image with ref: <span about=\"#mwt2\" class=\"mw-ref\" id=\"cite_ref-1\" rel=\"dc:references\" typeof=\"mw:Transclusion mw:Extension/ref\" data-parsoid='{\"dsr\":[64,96,null,null],\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"&lt;ref>{{echo|foo}}&lt;/ref>\"}},\"i\":0}}]}'><a href=\"./Main_Page#cite_note-1\" style=\"counter-reset: mw-Ref 1;\" data-parsoid=\"{}\"><span class=\"mw-reflink-text\" data-parsoid=\"{}\">[1]</span></a></span><meta typeof=\"mw:Transclusion mw:Extension/ref/Marker\" about=\"#mwt2\" data-parsoid='{\"group\":\"\",\"name\":\"\",\"content\":\"foo\",\"hasRefInRef\":false,\"dsr\":[64,96,null,null],\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"&lt;ref>{{echo|foo}}&lt;/ref>\"}},\"i\":0}}]}'/>"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
14718 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo</span></li></ol>
14725 Subpage test/subpage
14733 subpage title=[[Subpage test]]
14737 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
14742 Subpage noslash link
14744 subpage title=[[Subpage test]]
14748 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
14753 Subpage test/1/2/subpage
14759 Relative subpage noslash link
14761 parsoid=wt2wt,wt2html,html2html
14762 subpage title=[[Subpage test/1/2/3/4]]
14768 <p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a>
14769 </p><p><a href="/wiki/Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage test/1/2/subpage</a>
14772 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">subpage</a></p>
14773 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage" title="Subpage test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
14777 Parsoid: dot-slash prefixed wikilinks
14787 </p><p>[[././baz/]]
14792 </p><p>[[././baz/]]
14797 Render invalid page names as plain text (bug 51090)
14810 [[{{echo|./../foo}}|bar]]
14811 [[{{echo|foo/.}}|bar]]
14812 [[{{echo|foo/..}}|bar]]
14813 [[{{echo|foo~~~~bar}}]]
14814 [[{{echo|foo>bar}}]]
14815 [[{{echo|foo././bar}}]]
14816 [[{{echo|foo{bar}}]]
14817 [[{{echo|foo}bar}}]]
14818 [[{{echo|foo[bar}}]]
14819 [[{{echo|foo]bar}}]]
14820 [[{{echo|foo<bar}}]]
14822 <p>[[./../foo|bar]]
14832 </p><p>[[./../foo|bar]]
14845 <p>[[./../foo|bar]]
14856 <p>[[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"./../foo"}},"i":0}}]}'>./../foo</span>|bar]]
14857 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/."}},"i":0}}]}'>foo/.</span>|bar]]
14858 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/.."}},"i":0}}]}'>foo/..</span>|bar]]
14859 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo~~~~bar"}},"i":0}}]}'>foo~~~~bar</span>]]
14860 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo>bar"}},"i":0}}]}'>foo>bar</span>]]
14861 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo././bar"}},"i":0}}]}'>foo././bar</span>]]
14862 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo{bar"}},"i":0}}]}'>foo{bar</span>]]
14863 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo}bar"}},"i":0}}]}'>foo}bar</span>]]
14864 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo[bar"}},"i":0}}]}'>foo[bar</span>]]
14865 [[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo]bar"}},"i":0}}]}'>foo]bar</span>]]
14866 [[<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>
14874 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
14879 BUG 561: {{/Subpage}}
14881 subpage title=[[Page]]
14885 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
14893 Category:MediaWiki User's Guide
14901 [[:Category:MediaWiki User's Guide]]
14903 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
14912 [[Category:MediaWiki User's Guide]]
14914 cat=MediaWiki_User's_Guide sort=
14916 <link rel="mw:PageProp/Category" href="./Category:MediaWiki_User's_Guide" data-parsoid='{"stx":"simple","a":{"href":"./Category:MediaWiki_User's_Guide"},"sa":{"href":"Category:MediaWiki User's Guide"}}'/>
14920 PAGESINCATEGORY invalid title fatal (r33546 fix)
14922 {{PAGESINCATEGORY:<bogus>}}
14929 Category with different sort key
14933 [[Category:MediaWiki User's Guide|Foo]]
14935 cat=MediaWiki_User's_Guide sort=Foo
14937 <link rel="mw:PageProp/Category" href="./Category:MediaWiki_User's_Guide#Foo" data-parsoid='{"stx":"piped","a":{"href":"./Category:MediaWiki_User's_Guide"},"sa":{"href":"Category:MediaWiki User's Guide"}}'/>
14941 Category with identical sort key
14945 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
14947 cat=MediaWiki_User's_Guide sort=MediaWiki User's Guide
14949 <link rel="mw:PageProp/Category" href="./Category:MediaWiki_User's_Guide#MediaWiki%20User's%20Guide" data-parsoid='{"stx":"piped","a":{"href":"./Category:MediaWiki_User's_Guide"},"sa":{"href":"Category:MediaWiki User's Guide"}}'/>
14953 Category with empty sort key
14958 [[Category:MediaWiki User's Guide|]]
14960 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
14964 Category with empty sort key and parentheses
14969 [[Category:Foo (bar)|]]
14971 [[Category:Foo (bar)|Foo]]
14975 Category with link tail
14980 123[[Category:Foo]]456
14982 123[[Category:Foo]]456
14986 Category with template
14991 [[Category:{{echo|Foo}}]]
14993 [[Category:{{echo|Foo}}]]
14997 Category with template in sort key
15002 [[Category:Foo|{{echo|Bar}}]]
15004 [[Category:Foo|{{echo|Bar}}]]
15008 Category with template in sort key and title
15013 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
15015 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
15018 ## We used to, but no longer wt2wt this test since the default serializer
15019 ## will normalize all categories to serialize on their own line.
15020 ## This wikitext usage is going to be fairly uncommon in production and
15021 ## selser will take care of preserving formatting in those scenarios.
15023 Category / paragraph interactions
15027 Foo [[Category:Baz]] Bar
15029 Foo [[Category:Baz]]
15037 [[Category:Baz]] Bar
15050 {{echo|[[Category:Baz]]}}
15063 <p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
15064 <p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
15065 <p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
15066 <p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar</p>
15067 <p>Foo <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> Bar <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz"/> <link rel="mw:PageProp/Category" href="Category:Baz" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Category:Baz]]"}},"i":0}}]}'/></p>
15068 <link rel="mw:PageProp/Category" href="Category:Baz"/>
15071 ## We used to, but no longer wt2wt this test since the default serializer
15072 ## will normalize all categories to serialize on their own line.
15073 ## This wikitext usage is going to be fairly uncommon in production and
15074 ## selser will take care of preserving formatting in those scenarios.
15076 ## The whitespace on the empty line is part of the test. Please do not delete
15078 1. Categories and newlines: All preceding newlines should be suppressed (courtesy bug 87)
15084 [[Category:Foo]] and this should be part of same paragraph (not an indent-pre)
15086 {{echo|[[Category:Foo]] and so should this!}}
15088 <p>This and this should be part of same paragraph (not an indent-pre) and so should this!
15093 <link rel="mw:PageProp/Category" href="./Category:Foo"/> and this should be part of same paragraph (not an indent-pre)
15095 <link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Category:Foo]] and so should this!"}},"i":0}}]}'/><span about="#mwt1"> and so should this!</span></p>
15098 ## Parsoid will not try to wt2wt this while preserving newlines because
15099 ## it suppresses excess newlines within list items -- and we don't want to
15100 ## introduce a special case just for categories, which is, in reality somewhat
15101 ## odd behavior -- categories are unlikely to be used in list items like this
15102 ## in top-level pages and are only likely to show up in template-generated
15103 ## list items where this RT-ing is a non-issue.
15105 ## The whitespace on the empty line is part of the test. Please do not delete
15107 2. Categories and newlines: All preceding newlines should be suppressed (courtesy bug 87)
15113 [[Category:Foo]] and this should be part of the same list item
15116 {{echo|[[Category:Foo]] and this should be part of the same list item}}
15118 <ul><li>This and this should be part of the same list item</li>
15119 <li>So should this and this should be part of the same list item</li></ul>
15122 <li>This <link rel="mw:PageProp/Category" href="./Category:Foo"/> and this should be part of the same list item</li>
15123 <li>So should this <link rel="mw:PageProp/Category" href="./Category:Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Category:Foo]] and this should be part of the same list item"}},"i":0}}]}'/><span> and this should be part of the same list item</span></li>
15127 ## Newlines and categories that follow the last item of a list
15128 ## are treated differently because this (list followed by categories)
15129 ## is an extremely common pattern on wikis.
15131 3. Categories and newlines: newline suppression for last list item should RT properly
15144 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"}}'/>
15146 <link rel="mw:PageProp/Category" href="./Category:Bar" data-parsoid='{"stx":"simple","a":{"href":"./Category:Bar"},"sa":{"href":"Category:Bar"}}'/>
15147 <link rel="mw:PageProp/Category" href="./Category:Baz" data-parsoid='{"stx":"simple","a":{"href":"./Category:Baz"},"sa":{"href":"Category:Baz"}}'/>
15151 4. Categories and newlines: newline suppression for last list item should RT properly
15159 <ul><li><ul><li><ul><li> b</li></ul></li></ul></li></ul></li></ul>
15161 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"}}'/>
15164 ## only wt2html for this to make sure the algo only applies to the rightmost path
15166 5. Categories and newlines: migrateTrailingCategories dom pass should only run on the rightmost path of nested lists
15179 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"}}'/></li></ul></li>
15181 <ul><li> d</li></ul></li></ul>
15182 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"}}'/>
15185 ## We used to, but no longer wt2wt this test since the default serializer
15186 ## will normalize all categories to serialize on their own line.
15187 ## This wikitext usage is going to be fairly uncommon in production and
15188 ## selser will take care of preserving formatting in those scenarios.
15190 6. Categories and newlines: migrateTrailingCategories dom pass should not migrate categories not preceded by newlines
15194 * a [[Category:Foo]]
15196 <ul><li>a <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"}}'/></li></ul>
15199 # This test also demonstrates because of newline+category tunneling
15200 # through the list hander, template wrapping doesn't expand to the
15201 # containing list when the list item swallows the category.
15203 7. Categories and newlines: migrateTrailingCategories dom pass should leave template content alone
15208 <ul><li> <span about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n[[Category:Foo]]"}},"i":0}}]}'>a
15209 </span><link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"}}'/></li></ul>
15213 8. Categories and newlines: migrateTrailingCategories dom pass should not get tripped by intervening templates
15217 {{echo|[[Category:Foo]]
15221 <ul><li> a</li></ul>
15223 <link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"simple","a":{"href":"./Category:Foo"},"sa":{"href":"Category:Foo"},"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Category:Foo]]\n[[Category:Bar]]"}},"i":0}}]}'/><span about="#mwt1">
15224 </span><link rel="mw:PageProp/Category" href="./Category:Bar" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Category:Bar"},"sa":{"href":"Category:Bar"}}'/>
15225 <link rel="mw:PageProp/Category" href="./Category:Baz" data-parsoid='{"stx":"simple","a":{"href":"./Category:Baz"},"sa":{"href":"Category:Baz"}}'/>
15229 Category links with multiple namespaces
15231 [[Category:Project:Foo]]
15233 <link rel="mw:PageProp/Category" href="./Category:Project:Foo" />
15237 Parsoid: Serialize link to category page with colon escape
15243 [[:Category:Foo|Bar]]
15246 <a rel="mw:WikiLink" href="./Category:Foo" title="Category:Foo">Category:Foo</a>
15247 <a rel="mw:WikiLink" href="./Category:Foo" title="Category:Foo">Bar</a>
15251 # We used to, but no longer wt2wt this test since the default serializer
15252 # will normalize all categories to serialize on their own line.
15253 # This wikitext usage is going to be fairly uncommon in production and
15254 # selser will take care of preventing whitespace insertion if this
15255 # occurs in an article.
15257 # html2html disabled for the same reason (whitespace insertion between
15260 # html2wt disabled because it localizes the "Category" namespace.
15262 Link prefix/suffixes aren't applied to category links
15272 <p>x<link rel="mw:PageProp/Category" href="./Flokkur:Foo" data-parsoid=""/>y</p>
15276 Parsoid: Serialize link to file page with colon escape
15282 [[:File:Foo.png|Bar]]
15285 <a rel="mw:WikiLink" href="./File:Foo.png" title="File:Foo.png">File:Foo.png</a>
15286 <a rel="mw:WikiLink" href="./File:Foo.png" title="File:Foo.png">Bar</a>
15291 Parsoid: Serialize a genuine category link without colon escape
15296 [[Category:Foo|Bar]]
15298 <link rel="mw:PageProp/Category" href="./Category:Foo">
15299 <link rel="mw:PageProp/Category" href="./Category:Foo#Bar">
15303 Normalize hrefs properly before testing for invalid link targets (bug 70894)
15307 <link rel="mw:PageProp/Category" href="./Category:Toxine_bactérienne"/>
15309 [[Category:Toxine bactérienne]]
15313 Parsoid: Defaultsort
15315 {{DEFAULTSORT:Foo}}
15317 <meta property="mw:PageProp/categorydefaultsort" content="Foo"/>
15321 Parsoid: Defaultsort (template-generated)
15323 {{{{echo|DEFAULTSORT}}:Foo}}
15325 <meta property="mw:PageProp/categorydefaultsort" content="Foo" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"{{echo|DEFAULTSORT}}:Foo"},"params":{},"i":0}}]}'/>
15329 ### Inter-language links
15332 Interlanguage links
15340 es:Alimento fr:Nourriture zh:食品
15342 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Alimento"/>
15343 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/Nourriture"/>
15344 <link rel="mw:PageProp/Language" href="http://zh.wikipedia.org/wiki/食品"/>
15348 Duplicate interlanguage links (bug 24502)
15359 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/1"/>
15360 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/2"/>
15361 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/1"/>
15362 <link rel="mw:PageProp/Language" href="http://fr.wikipedia.org/wiki/2"/>
15369 Basic section headings
15376 ===Smaller headline===
15379 <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>
15382 <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>
15385 <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>
15391 Section headings with TOC
15394 === Subheadline 1 ===
15395 ===== Skipping a level =====
15396 ====== Skipping a level ======
15400 ===Another headline===
15402 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15404 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
15406 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
15408 <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>
15410 <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>
15417 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
15419 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
15425 <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>
15426 <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>
15427 <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>
15428 <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>
15429 <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>
15432 <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>
15437 TOC anchors don't collide
15445 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15447 <li class="toclevel-1 tocsection-1"><a href="#Headline_2"><span class="tocnumber">1</span> <span class="toctext">Headline 2</span></a></li>
15448 <li class="toclevel-1 tocsection-2"><a href="#Headline"><span class="tocnumber">2</span> <span class="toctext">Headline</span></a></li>
15449 <li class="toclevel-1 tocsection-3"><a href="#Headline_2_2"><span class="tocnumber">3</span> <span class="toctext">Headline 2</span></a></li>
15450 <li class="toclevel-1 tocsection-4"><a href="#Headline_3"><span class="tocnumber">4</span> <span class="toctext">Headline</span></a></li>
15454 <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=1" title="Edit section: Headline 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15455 <h2><span class="mw-headline" id="Headline">Headline</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">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15456 <h2><span class="mw-headline" id="Headline_2_2">Headline 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: Headline 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15457 <h2><span class="mw-headline" id="Headline_3">Headline</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: Headline">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15461 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
15463 Handling of sections up to level 6 and beyond
15466 == Level 2 Heading==
15467 === Level 3 Heading===
15468 ==== Level 4 Heading====
15469 ===== Level 5 Heading=====
15470 ====== Level 6 Heading======
15471 ======= Level 7 Heading=======
15472 ======== Level 8 Heading========
15473 ========= Level 9 Heading=========
15474 ========== Level 10 Heading==========
15476 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15478 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
15480 <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>
15482 <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>
15484 <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>
15486 <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>
15488 <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>
15489 <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>
15490 <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>
15491 <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>
15492 <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>
15506 <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>
15507 <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>
15508 <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>
15509 <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>
15510 <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>
15511 <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>
15512 <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>
15513 <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>
15514 <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>
15515 <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>
15520 TOC regression (T11764)
15524 ==== title 1.1.1 ====
15529 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15531 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
15533 <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>
15535 <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>
15538 <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>
15541 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
15543 <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>
15549 <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>
15550 <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>
15551 <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>
15552 <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>
15553 <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>
15554 <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>
15559 TOC for heading containing <span id="..."></span> (T96153)
15562 ==<span id="old-anchor"></span>New title==
15564 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15566 <li class="toclevel-1 tocsection-1"><a href="#New_title"><span class="tocnumber">1</span> <span class="toctext">New title</span></a></li>
15570 <h2><span class="mw-headline" id="New_title"><span id="old-anchor"></span>New title</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: New title">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15575 TOC with wgMaxTocLevel=3 (bug 6204)
15581 ==== title 1.1.1 ====
15586 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15588 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
15590 <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>
15591 <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>
15594 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
15596 <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>
15602 <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>
15603 <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>
15604 <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>
15605 <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>
15606 <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>
15607 <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>
15612 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
15618 ====Section 1.1.1====
15619 ====Section 1.1.1.1====
15622 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15624 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
15626 <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>
15629 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
15633 <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>
15634 <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>
15635 <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>
15636 <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>
15637 <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>
15643 Resolving duplicate section names
15648 <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>
15649 <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>
15654 Resolving duplicate section names with differing case (bug 10721)
15659 <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>
15660 <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>
15672 Template with sections, __NOTOC__
15679 <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>
15680 <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>
15681 <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>
15682 <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>
15687 __NOEDITSECTION__ keyword
15693 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
15694 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
15699 Link inside a section heading
15701 ==Section with a [[Main Page|link]] in it==
15703 <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>
15708 TOC regression (T14077)
15715 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15717 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
15719 <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>
15722 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
15726 <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>
15727 <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>
15728 <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>
15733 BUG 1219 URL next to image (good)
15735 http://example.com [[File:Foobar.jpg]]
15737 <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>
15740 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a> <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
15744 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
15747 The line above must have a trailing space!
15750 But just in case it doesn't...
15752 <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>
15753 <p>The line above must have a trailing space!
15755 <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>
15756 <p>But just in case it doesn't...
15761 Header with special characters (bug 25462)
15763 The tooltips shall not show entities to the user (ie. be double escaped)
15780 <p>The tooltips shall not show entities to the user (ie. be double escaped)
15782 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15784 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
15785 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
15786 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
15787 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
15788 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
15792 <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>
15795 <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>
15798 <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>
15801 <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>
15804 <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>
15810 Header with space, plus and underscore as entity
15812 Id should not contain + for spaces
15814 == Space between Text ==
15817 == Space-Entity between Text ==
15820 == Plus+between+Text ==
15823 == Plus-Entity+between+Text ==
15826 == Underscore_between_Text ==
15829 == Underscore-Entity_between_Text ==
15832 [[#Space between Text]]
15833 [[#Space-Entity between Text]]
15834 [[#Plus+between+Text]]
15835 [[#Plus-Entity+between+Text]]
15836 [[#Underscore_between_Text]]
15837 [[#Underscore-Entity_between_Text]]
15839 <p>Id should not contain + for spaces
15841 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15843 <li class="toclevel-1 tocsection-1"><a href="#Space_between_Text"><span class="tocnumber">1</span> <span class="toctext">Space between Text</span></a></li>
15844 <li class="toclevel-1 tocsection-2"><a href="#Space-Entity_between_Text"><span class="tocnumber">2</span> <span class="toctext">Space-Entity between Text</span></a></li>
15845 <li class="toclevel-1 tocsection-3"><a href="#Plus.2Bbetween.2BText"><span class="tocnumber">3</span> <span class="toctext">Plus+between+Text</span></a></li>
15846 <li class="toclevel-1 tocsection-4"><a href="#Plus-Entity.2Bbetween.2BText"><span class="tocnumber">4</span> <span class="toctext">Plus-Entity+between+Text</span></a></li>
15847 <li class="toclevel-1 tocsection-5"><a href="#Underscore_between_Text"><span class="tocnumber">5</span> <span class="toctext">Underscore_between_Text</span></a></li>
15848 <li class="toclevel-1 tocsection-6"><a href="#Underscore-Entity_between_Text"><span class="tocnumber">6</span> <span class="toctext">Underscore-Entity_between_Text</span></a></li>
15852 <h2><span class="mw-headline" id="Space_between_Text">Space between Text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Space between Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15855 <h2><span class="mw-headline" id="Space-Entity_between_Text">Space-Entity between Text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Space-Entity between Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15858 <h2><span class="mw-headline" id="Plus.2Bbetween.2BText">Plus+between+Text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Plus+between+Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15861 <h2><span class="mw-headline" id="Plus-Entity.2Bbetween.2BText">Plus-Entity+between+Text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Plus-Entity+between+Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15864 <h2><span class="mw-headline" id="Underscore_between_Text">Underscore_between_Text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Underscore between Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15867 <h2><span class="mw-headline" id="Underscore-Entity_between_Text">Underscore-Entity_between_Text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Underscore-Entity_between_Text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15869 </p><p><a href="#Space_between_Text">#Space between Text</a>
15870 <a href="#Space-Entity_between_Text">#Space-Entity between Text</a>
15871 <a href="#Plus.2Bbetween.2BText">#Plus+between+Text</a>
15872 <a href="#Plus-Entity.2Bbetween.2BText">#Plus-Entity+between+Text</a>
15873 <a href="#Underscore_between_Text">#Underscore_between_Text</a>
15874 <a href="#Underscore-Entity_between_Text">#Underscore-Entity_between_Text</a>
15879 Headers with excess '=' characters
15880 (Are similar tests necessary beyond the 1st level?)
15884 =''italic'' heading==
15885 ==''italic'' heading=
15887 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15889 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
15890 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
15891 <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>
15892 <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>
15896 <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>
15897 <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>
15898 <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>
15899 <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>
15904 HTML headers vs TOC (bug 23393)
15905 (__NOEDITSECTION__ for clearer output, doesn't matter here)
15917 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15919 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
15921 <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>
15922 <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>
15925 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
15927 <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>
15928 <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>
15934 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
15935 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
15936 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
15937 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
15938 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
15939 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
15944 Single-line or multiline-comments can follow headings
15946 parsoid=wt2html,wt2wt
15954 <h2><span class="mw-headline" id="foo">foo</span></h2>
15955 <h2><span class="mw-headline" id="bar">bar</span></h2>
15956 <h2><span class="mw-headline" id="baz">baz</span></h2>
15961 BUG 1219 URL next to image (broken)
15963 http://example.com[[File:Foobar.jpg]]
15965 <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>
15968 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a><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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a></span></p>
15972 Bug 1186 news: in the middle of text
15974 http://en.wikinews.org/wiki/Wikinews:Workplace
15976 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
15982 Namespaced link must have a title
15991 Namespaced link must have a title (bad fragment version)
15993 [[Project:#fragment]]
15995 <p>[[Project:#fragment]]
16001 ### HTML tags and HTML attributes
16005 div with no attributes
16007 <div>HTML rocks</div>
16009 <div>HTML rocks</div>
16014 div with double-quoted attribute
16016 <div id="rock">HTML rocks</div>
16018 <div id="rock">HTML rocks</div>
16023 div with single-quoted attribute
16025 <div id='rock'>HTML rocks</div>
16027 <div id="rock">HTML rocks</div>
16032 div with unquoted attribute
16034 <div id=rock>HTML rocks</div>
16036 <div id="rock">HTML rocks</div>
16041 div with illegal double attributes
16043 <div id="a" id="b">HTML rocks</div>
16045 <div id="b">HTML rocks</div>
16050 div with empty attribute value, space before equals
16052 parsoid=wt2html,html2html
16054 <div class =>HTML rocks</div>
16056 <div class="">HTML rocks</div>
16059 <div class="" data-parsoid='{"stx":"html"}'>HTML rocks</div>
16063 div with multiple empty attribute values
16065 parsoid=wt2html,html2html
16067 <div id= title=>HTML rocks</div>
16069 <div id="title.3D">HTML rocks</div>
16072 <div id="title.3D" data-parsoid='{"stx":"html"}'>HTML rocks</div>
16076 table with multiple empty attribute values
16078 parsoid=wt2html,html2html
16084 <table title="id=">
16090 <table title="id=">
16091 <tbody><tr><td> hi</td></tr>
16096 div with braces in attribute value
16098 <div title="{}">Foo</div>
16100 <div title="{}">Foo</div>
16103 <div title="{}">Foo</div>
16107 div with empty attribute value, no space before equals
16109 parsoid=wt2html,html2html
16111 <div class=>HTML rocks</div>
16113 <div class="">HTML rocks</div>
16116 <div class="">HTML rocks</div>
16120 HTML multiple attributes correction
16122 <p class="error" class="awesome">Awesome!</p>
16124 <p class="awesome">Awesome!</p>
16129 Table multiple attributes correction
16132 !+ class="error" class="awesome"| status
16137 <th class="awesome"> status
16145 <DIV ID="x">HTML ROCKS</DIV>
16147 <div id="x">HTML ROCKS</div>
16152 Non-ASCII pseudo-tags are rendered as text
16161 Pseudo-tag with URL 'name' renders as url link
16163 <http://example.com/>
16165 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
16170 text with amp in the middle of nowhere
16174 <p>Remember AT&T?
16179 text with character entity: eacute
16181 I always thought é was a cute letter.
16183 <p>I always thought é was a cute letter.
16186 <p>I always thought é was a cute letter.</p>
16190 text with entity-escaped character entity-like string: eacute
16192 I always thought &eacute; was a cute letter.
16194 <p>I always thought &eacute; was a cute letter.
16199 text with undefined character entity: xacute
16201 I always thought &xacute; was a cute letter.
16203 <p>I always thought &xacute; was a cute letter.
16210 <data value="5">five</data>
16211 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
16212 <mark>This highlighted text</mark>
16214 <p><data value="5">five</data>
16215 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
16216 <mark>This highlighted text</mark>
16221 HTML tag with leading space is parsed as text
16225 <p>< div>foo< /div>
16230 ### Nesting tests (see bug 41545, 50604, 51081)
16233 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
16234 # Note that html2wt is considerably more difficult if we use <b> in
16235 # the test case, instead of <big>
16237 Ensure that HTML adoption agency algorithm is properly implemented.
16239 <big>X<big>Y</big>Z</big>
16241 <p><big>X<big>Y</big>Z</big>
16245 # This was bug 41545 in the PHP parser.
16246 # Note that tidy doesn't handle this correctly.
16250 <kbd>X<kbd>Y</kbd>Z</kbd>
16252 <p><kbd>X<kbd>Y</kbd>Z</kbd>
16256 # The following cases were bug 51081 in the PHP parser.
16257 # Note that there are some other nestable tags (b, i, etc) which are
16258 # not covered; see bug 51081 for discussion.
16260 # Note that tidy doesn't handle this correctly.
16264 <em>X<em>Y</em>Z</em>
16266 <p><em>X<em>Y</em>Z</em>
16270 # Note that tidy doesn't handle this correctly.
16272 Nesting of <strong>
16274 <strong>X<strong>Y</strong>Z</strong>
16276 <p><strong>X<strong>Y</strong>Z</strong>
16285 <p><q>X<q>Y</q>Z</q></p>
16288 # Note that tidy doesn't handle this correctly.
16292 <ruby>X<ruby>Y</ruby>Z</ruby>
16294 <p><ruby>X<ruby>Y</ruby>Z</ruby>
16298 # Note that tidy doesn't handle this correctly.
16302 <bdo>X<bdo>Y</bdo>Z</bdo>
16304 <p><bdo>X<bdo>Y</bdo>Z</bdo>
16316 [[Media:Foobar.jpg]]
16318 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
16323 Media link with text
16325 [[Media:Foobar.jpg|A neat file to look at]]
16327 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
16331 # FIXME: this is still bad HTML tag nesting
16332 # FIXME: doBlockLevels won't wrap this in a paragraph because it contains a div
16334 Media link with nasty text
16336 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
16338 <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>
16341 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Safe Link</a></p>
16342 <div style="display:none">" onmouseover="alert(document.cookie)" onfoo="</div>
16346 Media link to nonexistent file (bug 1702)
16348 [[Media:No such.jpg]]
16350 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
16355 Image link to nonexistent file (bug 1850 - good)
16357 [[File:No_such.jpg]]
16359 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
16362 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:No_such.jpg"><img resource="./File:No_such.jpg" src="./Special:FilePath/No_such.jpg" height="220" width="220"/></a></span></p>
16366 :Image link to nonexistent file (bug 1850 - bad)
16368 [[:Image:No such.jpg]]
16370 <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>
16373 <p><a rel="mw:WikiLink" href="./File:No_such.jpg" title="File:No such.jpg">Image:No such.jpg</a></p>
16379 Character reference normalization in link text (bug 1938)
16381 [[Main Page|this&that]]
16383 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
16390 Test for unicode normalization
16392 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
16396 (bug 19451) Links should refer to the normalized form.
16404 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
16405 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
16406 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
16407 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
16408 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
16413 Empty attribute crash test (bug 2067)
16415 <font color="">foo</font>
16417 <p><font color="">foo</font>
16422 Empty attribute crash test single-quotes (bug 2067)
16424 <font color=''>foo</font>
16426 <p><font color="">foo</font>
16431 Attribute test: equals, then nothing
16433 parsoid=wt2html,html2html
16435 <font color=>foo</font>
16437 <p><font color="">foo</font>
16440 <p><font color="" data-parsoid='{"stx":"html"}'>foo</font></p>
16444 Attribute test: unquoted value
16446 parsoid=wt2html,html2html
16448 <font color=x>foo</font>
16450 <p><font color="x">foo</font>
16453 <p><font color="x" data-parsoid='{"stx":"html"}'>foo</font></p>
16457 Attribute test: unquoted but illegal value (hash)
16459 <font color=#x>foo</font>
16461 <p><font color="#x">foo</font>
16465 # Parsoid does not serialize to empty attribute syntax,
16466 # so wt2wt and html2wt cases are skipped
16468 Attribute test: no value (T54330)
16470 parsoid=wt2html,html2html
16472 <font color>foo</font>
16474 <p><font color="">foo</font>
16477 <p><font color="">foo</font></p>
16481 Bug 2095: link with three closing brackets
16485 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
16488 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a>]</p>
16492 Bug 2095: link with pipe and three closing brackets
16494 [[Main Page|link]]]
16496 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
16499 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">link</a>]</p>
16503 Bug 2095: link with pipe and three closing brackets, version 2
16505 [[Main Page|[http://example.com/]]]
16507 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
16510 <p><a rel="mw:WikiLink" href="./Main_Page" title="Main Page">[http://example.com/]</a></p>
16519 Template:Dangerous attribute
16521 " onmouseover="alert(document.cookie)
16525 Template:Dangerous style attribute
16527 border-size: expression(alert(document.cookie))
16533 <div style="float: right; {{{1}}}">Magic div</div>
16537 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
16539 <div title="{{test}}"></div>
16541 <div title="This is a test template"></div>
16545 # Parsoid has enough context to handle this case
16547 Bug 2304: HTML attribute safety (dangerous template; 2309)
16549 <div title="{{dangerous attribute}}"></div>
16551 <div title=""></div>
16554 <div title='" onmouseover="alert(document.cookie)' about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html","a":{"title":"\" onmouseover=\"alert(document.cookie)"},"sa":{"title":"{{dangerous attribute}}"}}' data-mw='{"attribs":[[{"txt":"title"},{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[12,35,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"dangerous attribute\",\"href\":\"./Template:Dangerous_attribute\"},\"params\":{},\"i\":0}}]}'>\" onmouseover=\"alert(document.cookie)</span>"}]]}'></div>
16558 Bug 2304: HTML attribute safety (dangerous style template; 2309)
16560 <div style="{{dangerous style attribute}}"></div>
16562 <div style="/* insecure input */"></div>
16567 Bug 2304: HTML attribute safety (safe parameter; 2309)
16569 {{div style|width: 200px}}
16571 <div style="float: right; width: 200px">Magic div</div>
16576 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
16578 {{div style|width: expression(alert(document.cookie))}}
16580 <div style="/* insecure input */">Magic div</div>
16585 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
16587 {{div style|"><script>alert(document.cookie)</script>}}
16589 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
16594 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
16596 {{div style|" ><script>alert(document.cookie)</script>}}
16598 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
16603 Bug 2304: HTML attribute safety (link)
16605 <div title="[[Main Page]]"></div>
16607 <div title="[[Main Page]]"></div>
16612 Bug 2304: HTML attribute safety (italics)
16614 <div title="''foobar''"></div>
16616 <div title="''foobar''"></div>
16621 Bug 2304: HTML attribute safety (bold)
16623 <div title="'''foobar'''"></div>
16625 <div title="'''foobar'''"></div>
16631 Bug 2304: HTML attribute safety (ISBN)
16633 <div title="ISBN 1234567890"></div>
16635 <div title="ISBN 1234567890"></div>
16640 Bug 2304: HTML attribute safety (RFC)
16642 <div title="RFC 1234"></div>
16644 <div title="RFC 1234"></div>
16649 Bug 2304: HTML attribute safety (PMID)
16651 <div title="PMID 1234567890"></div>
16653 <div title="PMID 1234567890"></div>
16658 Bug 2304: HTML attribute safety (web link)
16660 <div title="http://example.com/"></div>
16662 <div title="http://example.com/"></div>
16667 Bug 2304: HTML attribute safety (named web link)
16669 <div title="[http://example.com/ link]"></div>
16671 <div title="[http://example.com/ link]"></div>
16676 Bug 3244: HTML attribute safety (extension; safe)
16678 <div style="<nowiki>background:blue</nowiki>"></div>
16680 <div style="background:blue"></div>
16685 Bug 3244: HTML attribute safety (extension; unsafe)
16687 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
16689 <div style="/* insecure input */"></div>
16693 # More MSIE fun discovered by Tom Gilder
16696 MSIE CSS safety test: spurious slash
16698 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
16700 <div style="/* insecure input */">evil</div>
16705 MSIE CSS safety test: hex code
16707 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
16709 <div style="/* insecure input */">evil</div>
16714 MSIE CSS safety test: comment in url
16716 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
16718 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
16723 MSIE CSS safety test: comment in expression
16725 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
16727 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
16732 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
16734 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
16736 <p style="/* invalid control char */">A</p>
16741 MSIE 6 CSS safety test: Fullwidth (bug 55332)
16743 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
16744 <div style="top:EXPRESSION(alert())">B</div>
16746 <p style="/* insecure input */">A</p>
16747 <div style="/* insecure input */">B</div>
16752 MSIE 6 CSS safety test: IPA extensions (bug 55332)
16754 <div style="background-image:uʀʟ(javascript:alert())">A</div>
16755 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
16757 <div style="/* insecure input */">A</div>
16758 <p style="/* insecure input */">B</p>
16763 MSIE 6 CSS safety test: sup/sub script (bug 55332)
16765 <div style="background-image:url⁽javascript:alert())">A</div>
16766 <div style="background-image:url₍javascript:alert())">B</div>
16767 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
16769 <div style="/* insecure input */">A</div>
16770 <div style="/* insecure input */">B</div>
16771 <p style="/* insecure input */">C</p>
16775 # FIXME: Parsoid fails to sanitize this! See T58846.
16780 title="data:text/html,<img src=1 onerror=alert(1)>"
16781 style="-o-link:attr(title);-o-link-source:current">X</div>
16783 <div title="data:text/html,<img src=1 onerror=alert(1)>" style="/* insecure input */">X</div>
16788 MSIE 6 CSS safety test: Repetition markers (bug 55332)
16790 <p style="font-size: 100px; color: expres〱ion((title='XSSed'),'red')">A</p>
16791 <p style="font-size: 100px; color: expresゝion((title='XSSed'),'red')">B</p>
16792 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">C</p>
16793 <p style="font-size: 100px; color: expresヽion((title='XSSed'),'red')">D</p>
16794 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
16795 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
16796 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
16798 <p style="/* insecure input */">A</p>
16799 <p style="/* insecure input */">B</p>
16800 <p style="/* insecure input */">C</p>
16801 <p style="/* insecure input */">D</p>
16802 <p style="/* insecure input */">E</p>
16803 <p style="/* insecure input */">F</p>
16804 <p style="/* insecure input */">G</p>
16809 Table attribute legitimate extension
16812 !+ style="<nowiki>color:blue</nowiki>"| status
16817 <th style="color:blue"> status
16823 Table attribute safety
16826 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
16831 <th style="/* insecure input */"> status
16837 CSS line continuation 1
16839 <div style="background-image: u\ rl(test.jpg);"></div>
16841 <div style="/* insecure input */"></div>
16846 CSS line continuation 2
16848 <div style="background-image: u\ rl(test.jpg); "></div>
16850 <div style="/* invalid control char */"></div>
16861 Expansion of multi-line templates in attribute values (bug 6255)
16863 <div style="background: {{identity|#00FF00}}">-</div>
16865 <div style="background: #00FF00">-</div>
16871 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
16873 <div style="background:
16876 <div style="background: #00FF00">-</div>
16879 <div style="background:
16884 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
16886 <div style="background: #00FF00">-</div>
16888 <div style="background: #00FF00">-</div>
16893 Tags which are hidden from Tidy cannot pass through the Sanitizer
16895 <mw:toc><script>alert();</script></mw:toc>
16897 <p><mw:toc><script>alert();</script></mw:toc></p>
16901 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
16904 Parser hook: empty input
16915 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":{"extsrc":""}}' data-parsoid='{}' about="#mwt2"></pre>
16918 ## Don't expect parsoid to rt this form.
16920 Parser hook: empty input using terminated empty elements
16922 parsoid=wt2html,html2html
16933 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":null}' data-parsoid='{}' about="#mwt2"></pre>
16937 Parser hook: empty input using terminated empty elements (space before)
16948 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":null}' data-parsoid='{}' about="#mwt2"></pre>
16952 Parser hook: basic input
16963 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":{"extsrc":"input"}}' data-parsoid='{}' about="#mwt2"></pre>
16966 ## Don't expect parsoid to rt this form.
16968 Parser hook: case insensitive
16970 parsoid=wt2html,html2html
16981 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":{"extsrc":"input"}}' data-parsoid='{}' about="#mwt2"></pre>
16984 ## Don't expect parsoid to rt this form.
16986 Parser hook: case insensitive, redux
16988 parsoid=wt2html,html2html
16999 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":{"extsrc":"input"}}' data-parsoid='{}' about="#mwt2"></pre>
17003 Parser hook: nested tags
17005 <tag><tag></tag></tag>
17014 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{},"body":{"extsrc":"<tag>"}}' data-parsoid='{}' about="#mwt2"></pre></tag>
17018 Parser hook: basic arguments
17020 <tag width="200" height="100" depth="50" square=""></tag>
17033 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{"width":"200","height":"100","depth":"50","square":""},"body":{"extsrc":""}}' data-parsoid='{}' about="#mwt2"></pre>
17036 ## Don't expect parsoid to rt this form.
17038 Parser hook: basic arguments, variations
17040 parsoid=wt2html,html2html
17042 <tag width=200 height = "100" depth = '50' square></tag>
17055 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{"width":"200","height":"100","depth":"50","square":""},"body":{"extsrc":""}}' data-parsoid='{}' about="#mwt2"></pre>
17059 Parser hook: argument containing a forward slash (bug 5344)
17061 <tag filename="/tmp/bla"></tag>
17066 'filename' => '/tmp/bla',
17071 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{"filename":"/tmp/bla"},"body":{"extsrc":""}}' data-parsoid='{}' about="#mwt2"></pre>
17074 ## Don't expect parsoid to rt this form.
17076 Parser hook: empty input using terminated empty elements (bug 2374)
17078 parsoid=wt2html,html2html
17090 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{"foo":"bar"},"body":null}' data-parsoid='{}' about="#mwt2"></pre>text
17093 ## </tag> should be output literally since there is no matching tag that begins it
17094 ## Don't expect parsoid to rt this form.
17096 Parser hook: basic arguments using terminated empty elements (bug 2374)
17100 <tag width=200 height = "100" depth = '50' square/>
17117 <pre typeof="mw:Extension/tag" data-mw='{"name":"tag","attrs":{"width":"200","height":"100","depth":"50","square":""},"body":null}' about="#mwt2"></pre><p>other stuff
17121 ## Don't expect parsoid to rt this form.
17123 Parser hook: Don't allow unclosed extension tags
17129 this is a '''test'''
17131 <p>test <tag>123
17132 </p><p>this is a <b>test</b>
17135 <p>test <tag>123</p>
17137 <p>this is a <b>test</b></p>
17141 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
17145 Parser hook: static parser hook not inside a comment
17147 <statictag>hello, world</statictag>
17149 <statictag action="flush" />
17155 <p><span typeof="mw:Extension/statictag" data-mw='{"name":"statictag","attrs":{},"body":{"extsrc":"hello, world"}}' data-parsoid='{}' about="#mwt2"></span></p>
17156 <p typeof="mw:Extension/statictag" data-mw='{"name":"statictag","attrs":{"action":"flush"},"body":null}' data-parsoid='{}' about="#mwt4">hello, world</p>
17160 Parser hook: static parser hook inside a comment
17162 <!-- <statictag>hello, world</statictag> -->
17163 <statictag action="flush" />
17168 <!-- <statictag>hello, world</statictag> -->
17169 <p typeof="mw:Extension/statictag" data-mw='{"name":"statictag","attrs":{"action":"flush"},"body":null}' data-parsoid='{}' about="#mwt2"></p>
17172 # Nested template calls; this case was broken by Parser.php rev 1.506,
17176 Template:One-parameter
17178 (My parameter is: {{{1}}})
17182 Template:Map-one-parameter
17184 {{{{{1}}}|{{{2}}}}}
17188 Nested template calls
17190 {{Map-one-parameter|One-parameter|param}}
17192 <p>(My parameter is: param)
17201 # HTML+Tidy effectively strips out the empty tags completely
17202 # But since Parsoid doesn't it wraps the <s></s> tags in p-tags
17203 # which Tidy would have done for the PHP parser had there been content inside it.
17205 Sanitizer: Closing of open tags
17207 <s></s><table></table>
17209 <s></s><table></table>
17212 <p><s></s></p><table></table>
17216 Sanitizer: Closing of open but not closed tags
17225 Sanitizer: Closing of closed but not open tags
17235 Sanitizer: Closing of closed but not open table tags
17239 Table not started</td></tr></table>
17241 <p>Table not started</p>
17243 <p>Table not started</p>
17247 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
17249 <span id="æ: v">byte</span>[[#æ: v|backlink]]
17251 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
17254 <p><span id=".C3.A6:_v" data-parsoid='{"stx":"html","a":{"id":".C3.A6:_v"},"sa":{"id":"æ: v"}}'>byte</span><a rel="mw:WikiLink" href="./Main_Page#.C3.A6:_v" data-parsoid='{"stx":"piped","a":{"href":"./Main_Page#.C3.A6:_v"},"sa":{"href":"#æ: v"}}'>backlink</a></p>
17257 # In HTML5, the restrictions are that id must contain at least one character,
17258 # and must not contain any space characters.
17260 Sanitizer: Validating the contents of the id attribute (bug 4515)
17264 <br id="" /><br id="a space" />
17269 # In HTML5, id must be unique amongst all the ids in the element's home subtree.
17271 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
17275 <br id="foo" /><br id="foo" />
17277 Something need to be done. foo-2 ?
17281 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
17284 <meta itemprop="hello" content="world">
17285 <meta http-equiv="refresh" content="5">
17286 <meta itemprop="hello" http-equiv="refresh" content="5">
17287 <link itemprop="hello" href="{{SERVER}}">
17288 <link rel="stylesheet" href="{{SERVER}}">
17289 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
17293 <p> <meta itemprop="hello" content="world" />
17294 <meta http-equiv="refresh" content="5">
17295 <meta itemprop="hello" content="5" />
17297 <link itemprop="hello" href="http://example.org" />
17298 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
17299 <link itemprop="hello" href="http://example.org" />
17305 Language converter: output gets cut off unexpectedly (bug 5757)
17309 this bit is safe: }-
17311 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
17313 then we get cut off here: }-
17315 all additional text is vanished
17317 <p>this bit is safe: }-
17318 </p><p>but if we add a conversion instance: xxx
17319 </p><p>then we get cut off here: }-
17320 </p><p>all additional text is vanished
17325 Self closed html pairs (bug 5487)
17328 <center><font id="bug" />Centered text</center>
17329 <div><font id="bug2" />In div text</div>
17331 <center><font id="bug" />Centered text</center>
17332 <div><font id="bug2" />In div text</div>
17341 Punctuation: nbsp before exclamation
17345 <p>C'est grave !
17350 Punctuation: CSS !important (bug 11874)
17352 <div style="width:50% !important">important</div>
17354 <div style="width:50% !important">important</div>
17359 Punctuation: CSS ! important (bug 11874; with space after)
17361 <div style="width:50% ! important">important</div>
17363 <div style="width:50% ! important">important</div>
17368 HTML bullet list, closed tags (bug 5497)
17381 <ul data-parsoid='{"stx":"html"}'>
17382 <li data-parsoid='{"stx":"html"}'>One</li>
17383 <li data-parsoid='{"stx":"html"}'>Two</li>
17389 HTML bullet list, unclosed tags (bug 5497)
17401 <ul data-parsoid='{"stx":"html"}'>
17402 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>One</li>
17403 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>Two</li>
17409 HTML ordered list, closed tags (bug 5497)
17422 <ol data-parsoid='{"stx":"html"}'>
17423 <li data-parsoid='{"stx":"html"}'>One</li>
17424 <li data-parsoid='{"stx":"html"}'>Two</li>
17430 HTML ordered list, unclosed tags (bug 5497)
17443 <ol data-parsoid='{"stx":"html"}'>
17444 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>One</li>
17445 <li data-parsoid='{"stx":"html","autoInsertedEnd":true}'>Two</li>
17451 HTML nested bullet list, closed tags (bug 5497)
17474 <ul data-parsoid='{"stx":"html"}'>
17475 <li data-parsoid='{"stx":"html"}'>One</li>
17476 <li data-parsoid='{"stx":"html"}'>Two:
17477 <ul data-parsoid='{"stx":"html"}'>
17478 <li data-parsoid='{"stx":"html"}'>Sub-one</li>
17479 <li data-parsoid='{"stx":"html"}'>Sub-two</li>
17486 HTML nested bullet list, open tags (bug 5497)
17523 HTML nested ordered list, closed tags (bug 5497)
17548 HTML nested ordered list, open tags (bug 5497)
17585 HTML ordered list item with parameters oddity
17587 <ol><li id="fragment">One</li>
17590 <ol><li id="fragment">One</li>
17595 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
17597 bug 5918: autonumbering
17599 [http://first/] [http://second] [ftp://ftp]
17603 [mailto:enclosed@mail.tld With target]
17605 [mailto:enclosed@mail.tld]
17607 mailto:inline@mail.tld
17609 <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>
17610 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
17611 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
17612 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
17613 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
17616 <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>
17617 <p><a rel="mw:ExtLink" href="ftp://inlineftp">ftp://inlineftp</a></p>
17618 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld">With target</a></p>
17619 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld"></a></p>
17620 <p><a rel="mw:ExtLink" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a></p>
17625 # Security and HTML correctness
17626 # From Nick Jenkins' fuzz testing
17630 Fuzz testing: Parser13
17645 Fuzz testing: Parser14
17650 <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>
17651 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17653 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
17659 <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>
17661 <div id="toc" class="toc">
17662 <div id="toctitle">
17666 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
17673 Fuzz testing: Parser14-table
17675 parsoid=wt2html,html2html
17680 <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>
17681 <table style="__TOC__">
17686 <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>
17687 <table style="__TOC__">
17694 <table style="__TOC__"></table>
17697 # Known to produce bogus xml (extra </td>)
17699 Fuzz testing: Parser16
17726 Fuzz testing: Parser21
17729 ! irc://{{ftp://a" onmouseover="alert('hello world');"
17734 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
17744 Fuzz testing: Parser22
17746 http://===r:::https://b
17750 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
17758 # Known to produce bad XML for now
17760 Fuzz testing: Parser24
17767 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
17768 <br style="onmouseover='alert(document.cookie);' " />
17770 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
17775 <u class="|">}}}} >
17776 <br style="onmouseover='alert(document.cookie);'" />
17778 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
17786 <p data-parsoid='{"fostered":true,"autoInsertedEnd":true}'>{{{|
17787 <u class="|" about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html","a":{"{{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}}":null},"sa":{"{{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}}":""},"autoInsertedEnd":true}' data-mw='{"attribs":[[{"txt":"{{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx-->}}}}","html":"{<span about=\"#mwt1\" typeof=\"mw:Param\" data-parsoid='{\"pi\":[[]],\"dsr\":[21,79,null,null]}' data-mw='{\"parts\":[{\"templatearg\":{\"target\":{\"wt\":\"SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx-->&lt;noinclude>\"},\"params\":{},\"i\":0}}]}'>{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx-->}}}</span>}"},{"html":""}]]}'>
17788 <br style="onmouseover='alert(document.cookie);' " data-parsoid='{"stx":"html","selfClose":true}'/></u></p><p data-parsoid='{"fostered":true,"autoInsertedEnd":true}'><u class="|" about="#mwt2" typeof="mw:ExpandedAttrs" data-parsoid='{"stx":"html","a":{"{{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}}":null},"sa":{"{{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}}":""},"autoInsertedEnd":true,"autoInsertedStart":true}' data-mw='{"attribs":[[{"txt":"{{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx-->}}}}","html":"{<span about=\"#mwt1\" typeof=\"mw:Param\" data-parsoid='{\"pi\":[[]],\"dsr\":[21,79,null,null]}' data-mw='{\"parts\":[{\"templatearg\":{\"target\":{\"wt\":\"SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx-->&lt;noinclude>\"},\"params\":{},\"i\":0}}]}'>{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx-->}}}</span>}"},{"html":""}]]}'>MOVE YOUR MOUSE CURSOR OVER THIS TEXT</u></p><table data-parsoid='{"autoInsertedEnd":true}'>
17792 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'></td></tr></tbody></table>
17795 # Note: the current result listed for this is not what the original one was,
17796 # but the original bug was JavaScript injection, which is fixed in any case.
17797 # It's not clear that the original result listed was any more correct than the
17798 # current one. Original result:
17801 # <li class="||">
17802 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
17804 Fuzz testing: Parser25 (bug 6055)
17810 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
17812 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
17815 <span about="#mwt1" typeof="mw:Param" data-parsoid='{"pi":[[{"k":"1"},{"k":"2"},{"k":"3"}]]}' data-mw='{"parts":[{"templatearg":{"target":{"wt":"\n"},"params":{"1":{"wt":" \n<LI CLASS="},"2":{"wt":""},"3":{"wt":"\n >\n"}},"i":0}},"blah\" onmouseover=\"alert('hello world');\" align=\"left\"'''MOVE MOUSE CURSOR OVER HERE"]}'>
17816 </span><p about="#mwt1"><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b></p>
17820 Fuzz testing: URL adjacent extension (with space, clean)
17822 http://example.com <nowiki>junk</nowiki>
17824 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
17827 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a> <span typeof="mw:Nowiki">junk</span></p>
17831 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
17833 http://example.com<nowiki>junk</nowiki>
17835 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
17838 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a><span typeof="mw:Nowiki">junk</span></p>
17842 Fuzz testing: URL adjacent extension (no space, dirty; pre)
17844 http://example.com<pre>junk</pre>
17846 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
17849 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></p>
17854 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a></p><pre data-parsoid='{"stx":"html"}'>junk</pre>
17858 Fuzz testing: image with bogus manual thumbnail
17860 [[Image:foobar.jpg|thumbnail= ]]
17862 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
17865 <figure class="mw-default-size" typeof="mw:Error mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"manualthumb","ak":"thumbnail= "}]}' data-mw='{"errors":[{"key":"missing-thumbnail","message":"This thumbnail does not exist.","params":{"name":""}}],"thumb":""}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="./Special:FilePath/" height="220" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"220"},"sa":{"resource":"Image:foobar.jpg"}}'/></a></figure>
17869 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
17871 <pre dir=" "></pre>
17873 <pre dir=" "></pre>
17878 Parsing optional HTML elements (Bug 6171)
17883 <td> Some tabular data</td>
17884 <td> More tabular data ...
17885 <td> And yet som tabular data</td>
17891 <td> Some tabular data</td>
17892 <td> More tabular data ...
17893 </td><td> And yet som tabular data</td>
17900 Correct handling of <td>, <tr> (Bug 6171)
17905 <td> Some tabular data</td>
17906 <td> More tabular data ...</td>
17907 <td> And yet som tabular data</td>
17913 <td> Some tabular data</td>
17914 <td> More tabular data ...</td>
17915 <td> And yet som tabular data</td>
17923 Parsing crashing regression (fr:JavaScript)
17927 <p></body></x>
17932 Inline wiki vs wiki block nesting
17938 <p><b>Bold paragraph</b>
17939 </p><p>New wiki paragraph
17943 # FIXME: The current php output is documented
17944 # and desired output is the parsoid target.
17946 Inline HTML vs wiki block nesting
17952 <p><b>Bold paragraph
17953 </p><p>New wiki paragraph</b>
17956 <p><b>Bold paragraph</b>
17957 </p><p>New wiki paragraph
17961 # Original result was this:
17962 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
17964 # While that might be marginally more intuitive, maybe, the six-apostrophe
17965 # construct is clearly pathological and the result stated here (which is what
17966 # the parser actually does) is about as reasonable as anything.
17968 Mixing markup for italics and bold
17971 '''bold''''''bold''bolditalics'''''
17973 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
17981 Article for special page transclusion test
17985 Special page transclusion
17988 {{Special:Prefixindex/Xyzzyx}}
17990 <ul class="mw-prefixindex-list"><li><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></li>
17996 Special page transclusion twice (bug 5021)
17999 {{Special:Prefixindex/Xyzzyx}}
18000 {{Special:Prefixindex/Xyzzyx}}
18002 <ul class="mw-prefixindex-list"><li><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></li>
18004 <ul class="mw-prefixindex-list"><li><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></li>
18010 Transclusion of default MediaWiki message
18012 {{MediaWiki:Mainpage}}
18019 Transclusion of nonexistent MediaWiki message
18021 {{MediaWiki:Mainpagexxx}}
18023 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
18028 Transclusion of MediaWiki message with underscore
18030 {{MediaWiki:history_short}}
18037 Transclusion of MediaWiki message with space
18039 {{MediaWiki:history short}}
18046 Invalid header with following text
18056 Section extraction test (section 0)
18076 Section extraction test (section 1)
18098 Section extraction test (section 2)
18119 Section extraction test (section 3)
18139 Section extraction test (section 4)
18163 Section extraction test (section 5)
18183 Section extraction test (section 6)
18204 Section extraction test (section 7)
18224 Section extraction test (section 8)
18244 Section extraction test (section 9)
18265 Section extraction test (section 10)
18285 Section extraction test (nonexistent section 11)
18304 Section extraction test with bogus heading (section 1)
18309 ==bogus== not a legal section
18313 ==bogus== not a legal section
18317 Section extraction test with bogus heading (section 2)
18322 ==bogus== not a legal section
18329 Section extraction test with comment after heading (section 1)
18341 Section extraction test with comment after heading (section 2)
18353 Section extraction test with bogus <nowiki> heading (section 1)
18358 ==bogus== <nowiki>not a legal section</nowiki>
18362 ==bogus== <nowiki>not a legal section</nowiki>
18366 Section extraction test with bogus <nowiki> heading (section 2)
18371 ==bogus== <nowiki>not a legal section</nowiki>
18377 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
18378 # instead of respecting commented sections
18380 Section extraction prefixed by comment (section 1)
18391 Section extraction prefixed by comment (section 2)
18401 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
18402 # instead of respecting HTML-style headings
18404 Section extraction, mixed wiki and html (section 1)
18420 Section extraction, mixed wiki and html (section 2)
18436 # Formerly testing for bug 3342
18438 Section extraction, heading surrounded by <noinclude>
18442 <noinclude>==unmarked==</noinclude>
18448 # Test behavior of bug 19910
18450 Sectiion with all-equals
18455 The line above must have a trailing space
18458 But just in case it doesn't...
18462 But just in case it doesn't...
18466 Section replacement test (section 0)
18497 Section replacement test (section 1)
18526 Section replacement test (section 2)
18556 Section replacement test (section 3)
18587 Section replacement test (section 4)
18614 Section replacement test (section 5)
18645 Section replacement test (section 6)
18675 Section replacement test (section 7)
18706 Section replacement test (section 8)
18737 Section replacement test (section 9)
18766 Section replacement test (section 10)
18796 Section replacement test with initial whitespace (bug 13728)
18800 Preformatted initial line
18804 Preformatted initial line
18811 Section extraction, heading followed by pre with 20 spaces (bug 6398)
18823 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
18836 Section extraction, <pre> around bogus header (bug 10309)
18853 Section replacement, <pre> around bogus header (bug 10309)
18875 Handling of 
 in URLs
18879 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
18882 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://
18884 a</a></li></ul></li></ul>
18888 Handling of %0A in URLs
18892 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
18895 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
18899 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
18901 5 quotes, code coverage +1 line
18908 <p><b><i></i></b></p>
18911 # same html as previous, but wikitext adjusted to match parsoid html2wt
18912 # note that wt2html and html2html will put the <i> before the <b>
18914 5 quotes, code coverage +1 line w/ nowiki (1)
18916 parsoid=wt2wt,html2wt
18918 '''''<nowiki/>'''''
18923 <p><b><i></i></b></p>
18926 # same as previous, just swapping the <i> and <b>
18928 5 quotes, code coverage +1 line w/ nowiki (2)
18930 '''''<nowiki/>'''''
18935 <p><i><b></b></i></p>
18939 Special:Search page linking.
18943 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
18948 {{!}} is a magic word
18950 {{!}} is a magic word there and {{!}} is still a magic word here
18951 | is not a magic word here but {{!}} is still a magic word here
18953 <p>| is a magic word there and | is still a magic word here
18954 | is not a magic word here but | is still a magic word here
18957 <p><span about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"!","href":"./Template:!"},"params":{},"i":0}}]}'>|</span> is a magic word there and <span about="#mwt2" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"!","href":"./Template:!"},"params":{},"i":0}}]}'>|</span> is still a magic word here
18958 | is not a magic word here but <span about="#mwt3" typeof="mw:Transclusion" data-parsoid='{"pi":[[]]}' data-mw='{"parts":[{"template":{"target":{"wt":"!","href":"./Template:!"},"params":{},"i":0}}]}'>|</span> is still a magic word here</p>
18965 title=[[Parser test]]
18970 * {{FULLPAGENAMEE}}
18972 * {{BASEPAGENAMEE}}
18976 * {{ROOTPAGENAMEE}}
18978 * {{TALKPAGENAMEE}}
18979 * {{SUBJECTPAGENAME}}
18980 * {{SUBJECTPAGENAMEE}}
18983 * {{NAMESPACENUMBER}}
18987 * {{SUBJECTSPACEE}}
18988 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
18990 <ul><li> Parser test</li>
18991 <li> Parser_test</li>
18992 <li> Parser test</li>
18993 <li> Parser_test</li>
18994 <li> Parser test</li>
18995 <li> Parser_test</li>
18996 <li> Parser test</li>
18997 <li> Parser_test</li>
18998 <li> Parser test</li>
18999 <li> Parser_test</li>
19000 <li> Talk:Parser test</li>
19001 <li> Talk:Parser_test</li>
19002 <li> Parser test</li>
19003 <li> Parser_test</li>
19011 <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>
19014 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
19016 ## Parsoid thinks the "centre" here is a property, not a caption.
19021 "modes": ["wt2html"],
19022 "nativeGallery": true
19030 image4 |300px| centre
19031 image5.svg| http://///////
19036 <ul class="gallery mw-gallery-traditional">
19037 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19038 <div class="thumb" style="height: 150px;">Image1.png</div>
19039 <div class="gallerytext">
19042 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19043 <div class="thumb" style="height: 150px;">Image2.gif</div>
19044 <div class="gallerytext">
19047 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19048 <div class="thumb" style="height: 150px;">Image3</div>
19049 <div class="gallerytext">
19052 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19053 <div class="thumb" style="height: 150px;">Image4</div>
19054 <div class="gallerytext">
19059 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19060 <div class="thumb" style="height: 150px;">Image5.svg</div>
19061 <div class="gallerytext">
19062 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
19066 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19067 <div class="thumb" style="height: 150px;">* image6</div>
19068 <div class="gallerytext">
19074 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt3" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19075 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">image1.png </span></div><div class="gallerytext"></div></li>
19076 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">image2.gif</span></div><div class="gallerytext"></div></li>
19077 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">image3</span></div><div class="gallerytext"></div></li>
19078 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">image4 </span></div><div class="gallerytext"></div></li>
19079 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;"> image5.svg</span></div><div class="gallerytext"> <a rel="mw:ExtLink" href="http://///////">http://///////</a></div></li>
19080 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">* image6</span></div><div class="gallerytext"></div></li>
19085 Gallery (with options, html)
19088 "modes": ["wt2html", "html2html"],
19089 "nativeGallery": true
19092 <gallery widths="70px" heights="40px" perrow="2" caption="Foo [[Main Page]]">
19093 File:Nonexistent.jpg|caption
19094 File:Nonexistent.jpg
19095 image:foobar.jpg|some '''caption''' [[Main Page]]
19097 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
19100 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
19101 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
19102 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19103 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
19104 <div class="gallerytext">
19109 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19110 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
19111 <div class="gallerytext">
19114 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19115 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/105px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/140px-Foobar.jpg 2x" /></a></div></div>
19116 <div class="gallerytext">
19117 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
19121 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19122 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/105px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/140px-Foobar.jpg 2x" /></a></div></div>
19123 <div class="gallerytext">
19126 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19127 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/105px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/140px-Foobar.jpg 2x" /></a></div></div>
19128 <div class="gallerytext">
19136 <ul class="gallery mw-gallery-traditional" style="max-width: 226px; _width: 226px;" typeof="mw:Extension/gallery" about="#mwt3" data-mw='{"name":"gallery","attrs":{"widths":"70px","heights":"40px","perrow":"2"},"body":{}}'>
19137 <li class="gallerycaption">Foo <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></li>
19138 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext">caption</div></li>
19139 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext"></div></li>
19140 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="8" width="70"/></a></span></div><div class="gallerytext">some <b>caption</b> <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></div></li>
19141 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="8" width="70"/></a></span></div><div class="gallerytext"></div></li>
19142 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img alt="This is a foo-bar." resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="8" width="70"/></a></span></div><div class="gallerytext">blabla.</div></li>
19147 Gallery (with options, extsrc)
19150 "nativeGallery": false
19153 <gallery widths="70px" heights="40px" perrow="2" caption="Foo [[Main Page]]">
19154 File:Nonexistent.jpg|caption
19155 File:Nonexistent.jpg
19156 image:foobar.jpg|some '''caption''' [[Main Page]]
19158 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
19161 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
19162 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
19163 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19164 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
19165 <div class="gallerytext">
19170 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19171 <div class="thumb" style="height: 70px;">Nonexistent.jpg</div>
19172 <div class="gallerytext">
19175 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19176 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/105px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/140px-Foobar.jpg 2x" /></a></div></div>
19177 <div class="gallerytext">
19178 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
19182 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19183 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/105px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/140px-Foobar.jpg 2x" /></a></div></div>
19184 <div class="gallerytext">
19187 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
19188 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/105px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/140px-Foobar.jpg 2x" /></a></div></div>
19189 <div class="gallerytext">
19197 <ul class="gallery mw-gallery-traditional" style="max-width: 226px; _width: 226px;" typeof="mw:Extension/gallery" about="#mwt3" data-parsoid='{}' data-mw='{"name":"gallery","attrs":{"widths":"70px","heights":"40px","perrow":"2","caption":"Foo [[Main Page]]"},"body":{"extsrc":"\nFile:Nonexistent.jpg|caption\nFile:Nonexistent.jpg\nimage:foobar.jpg|some '''caption''' [[Main Page]]\nimage:foobar.jpg\nimage:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.\n"}}'>
19198 <li class="gallerycaption">Foo <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></li>
19199 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext">caption</div></li>
19200 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext"></div></li>
19201 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="8" width="70"/></a></span></div><div class="gallerytext">some <b>caption</b> <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></div></li>
19202 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="8" width="70"/></a></span></div><div class="gallerytext"></div></li>
19203 <li class="gallerybox" style="width: 105px;"><div class="thumb" style="width: 100px; height: 70px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img alt="This is a foo-bar." resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="8" width="70"/></a></span></div><div class="gallerytext">blabla.</div></li>
19208 Gallery with link that has fragment
19211 "modes": ["wt2html", "html2html"],
19212 "nativeGallery": true
19216 image:foobar.jpg|link=Main_Page
19217 image:foobar.jpg|link=Main_Page#section
19218 image:foobar.jpg|link=Main Page#section|caption
19221 <ul class="gallery mw-gallery-traditional">
19222 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19223 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19224 <div class="gallerytext">
19227 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19228 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19229 <div class="gallerytext">
19232 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19233 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19234 <div class="gallerytext">
19242 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19243 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19244 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./Main_Page#section"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19245 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./Main_Page#section"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext">caption</div></li>
19249 ## Whoops, Parsoid shouldn't be parsing templates in the attribute caption!
19251 Gallery with template inside caption
19254 "nativeGallery": true
19257 <gallery caption="{{echo|hi}}">
19258 File:Foobar.jpg|{{echo|ho}}
19261 <ul class="gallery mw-gallery-traditional">
19262 <li class='gallerycaption'>{{echo|hi}}</li>
19263 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19264 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19265 <div class="gallerytext">
19273 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt6" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19274 <li class="gallerycaption"><span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"hi"}},"i":0}}]}'>hi</span></li>
19275 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"><span about="#mwt5" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"ho"}},"i":0}}]}'>ho</span></div></li>
19280 Gallery with wikitext inside caption
19283 "nativeGallery": true
19287 File:Foobar.jpg|alt=galleryalt|[[File:Foobar.jpg|alt=inneralt|20x20px|desc]]
19288 File:Foobar.jpg|alt=galleryalt|{{Test|unamedParam|alt=param}}
19291 <ul class="gallery mw-gallery-traditional">
19292 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19293 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19294 <div class="gallerytext">
19295 <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>
19299 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19300 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19301 <div class="gallerytext">
19302 <p>This is a test template
19309 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt6" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19310 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"><span typeof="mw:Image" data-mw='{"caption":"desc"}'><a href="./File:Foobar.jpg"><img alt="inneralt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/20px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="2" width="20"/></a></span></div></li>
19311 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"><span about="#mwt4" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"Test","href":"./Template:Test"},"params":{"1":{"wt":"unamedParam"},"alt":{"wt":"param"}},"i":0}}]}'>This is a test template</span></div></li>
19316 Gallery (with showfilename option)
19319 "nativeGallery": true
19322 <gallery showfilename="">
19323 File:Nonexistent.jpg|caption
19324 File:Nonexistent.jpg
19325 File:Foobar.jpg|some '''caption''' [[Main Page]]
19329 <ul class="gallery mw-gallery-traditional">
19330 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19331 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
19332 <div class="gallerytext">
19333 <p><a href="/wiki/File:Nonexistent.jpg" class="galleryfilename galleryfilename-truncate" title="File:Nonexistent.jpg">Nonexistent.jpg</a>
19338 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19339 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
19340 <div class="gallerytext">
19341 <p><a href="/wiki/File:Nonexistent.jpg" class="galleryfilename galleryfilename-truncate" title="File:Nonexistent.jpg">Nonexistent.jpg</a>
19345 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19346 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19347 <div class="gallerytext">
19348 <p><a href="/wiki/File:Foobar.jpg" class="galleryfilename galleryfilename-truncate" title="File:Foobar.jpg">Foobar.jpg</a>
19349 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
19353 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19354 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19355 <div class="gallerytext">
19356 <p><a href="/wiki/File:Foobar.jpg" class="galleryfilename galleryfilename-truncate" title="File:Foobar.jpg">Foobar.jpg</a>
19363 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt3" data-mw='{"name":"gallery","attrs":{"showfilename":""},"body":{}}'>
19364 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext"><a href="./File:Nonexistent.jpg" class="galleryfilename galleryfilename-truncate" title="File:Nonexistent.jpg">File:Nonexistent.jpg</a>caption</div></li>
19365 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext"><a href="./File:Nonexistent.jpg" class="galleryfilename galleryfilename-truncate" title="File:Nonexistent.jpg">File:Nonexistent.jpg</a></div></li>
19366 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"><a href="./File:Foobar.jpg" class="galleryfilename galleryfilename-truncate" title="File:Foobar.jpg">File:Foobar.jpg</a>some <b>caption</b> <a rel="mw:WikiLink" href="./Main_Page" title="Main Page">Main Page</a></div></li>
19367 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"><a href="./File:Foobar.jpg" class="galleryfilename galleryfilename-truncate" title="File:Foobar.jpg">File:Foobar.jpg</a></div></li>
19371 ## Should Parsoid be preserving these variations?
19373 Gallery (with namespace-less filenames)
19376 "modes": ["wt2html", "html2html"],
19377 "nativeGallery": true
19381 File:Nonexistent.jpg
19387 <ul class="gallery mw-gallery-traditional">
19388 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19389 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
19390 <div class="gallerytext">
19393 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19394 <div class="thumb" style="height: 150px;">Nonexistent.jpg</div>
19395 <div class="gallerytext">
19398 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19399 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19400 <div class="gallerytext">
19403 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19404 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19405 <div class="gallerytext">
19411 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19412 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">File:Nonexistent.jpg</span></div><div class="gallerytext"></div></li>
19413 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span style="vertical-align: middle; display: inline-block;">Nonexistent.jpg</span></div><div class="gallerytext"></div></li>
19414 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19415 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19420 Gallery override link with WikiLink (T36852)
19423 "nativeGallery": true
19427 File:Foobar.jpg|alt=galleryalt|link=InterWikiLink
19430 <ul class="gallery mw-gallery-traditional">
19431 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19432 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19433 <div class="gallerytext">
19439 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-parsoid='{"dsr":[0,70,2,2]}' data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19440 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./InterWikiLink"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19445 Gallery override link with absolute external link (T36852)
19448 "nativeGallery": true
19452 File:Foobar.jpg|alt=galleryalt|link=http://www.example.org
19455 <ul class="gallery mw-gallery-traditional">
19456 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19457 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19458 <div class="gallerytext">
19464 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19465 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="http://www.example.org"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19470 Gallery override link with malicious javascript (T36852)
19473 "modes": ["wt2html", "html2html"],
19474 "nativeGallery": true
19478 File:Foobar.jpg|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
19481 <ul class="gallery mw-gallery-traditional">
19482 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19483 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19484 <div class="gallerytext">
19490 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19491 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./"_onclick="alert('malicious_javascript_code!');"><img alt="galleryalt" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext"></div></li>
19496 Gallery with invalid title as link (T45964)
19499 "modes": ["wt2html", "html2html"],
19500 "nativeGallery": true
19504 File:Foobar.jpg|link=<
19507 <ul class="gallery mw-gallery-traditional">
19508 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
19509 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
19510 <div class="gallerytext">
19516 <ul class="gallery mw-gallery-traditional" typeof="mw:Extension/gallery" about="#mwt2" data-mw='{"name":"gallery","attrs":{},"body":{}}'>
19517 <li class="gallerybox" style="width: 155px;"><div class="thumb" style="width: 150px; height: 150px;"><span style="display: inline-block; height: 100%; vertical-align: middle;"></span><span typeof="mw:Image" style="vertical-align: middle; display: inline-block;"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="14" width="120"/></a></span></div><div class="gallerytext">link=<</div></li>
19522 HTML Hex character encoding (spells the word "JavaScript")
19524 parsoid=wt2html,wt2wt,html2html
19526 JavaScript
19528 <p>JavaScript
19533 <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>
19537 HTML Hex character encoding bogus encoding (bug 26437 regression check)
19541 <p>&#xsee;&#XSEE;
19544 <p>&#xsee;&#XSEE;</p>
19548 HTML Hex character encoding mixed case
19550 parsoid=wt2html,wt2wt,html2html
19559 <p><span typeof="mw:Entity">î</span><span typeof="mw:Entity">î</span></p>
19562 # See: https://www.w3.org/TR/html5/syntax.html#character-references
19563 # Note that U+000C (form feed) is not a valid XML character, so
19564 # it is banned even though allowed in HTML5.
19566 Illegal character references (T106578)
19571 ; Control (low): 
19572 ; Control (high):  Ÿ
19573 ; Surrogate: ��
19574 ; This is an okay astral character: 💩
19583 <dt>Control (low)</dt>
19585 <dt>Control (high)</dt>
19586 <dd>&#x7F; &#x9F;</dd>
19588 <dd>&#xD83D;&#xDCA9;</dd>
19589 <dt>This is an okay astral character</dt>
19595 __FORCETOC__ override
19607 ISBN 978-0-1234-56 789
19609 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
19612 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789</p>
19614 <p><a href="./Special:BookSources/9780123456" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 978-0-1234-56</a><span typeof="mw:Entity" data-parsoid='{"src":"&#x20;","srcContent":" "}'> </span>789</p>
19618 ISBN followed by 5 spaces
19629 ISBN ISBN 1234567890
19631 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
19634 <p>ISBN <a href="./Special:BookSources/1234567890" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a></p>
19637 # Uppercase X and lowercase x as well
19648 <p><a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-X</a>
19649 <a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-x</a>
19650 <a href="/wiki/Special:BookSources/080442957X" class="internal mw-magiclink-isbn">ISBN 080442957X</a>
19651 <a href="/wiki/Special:BookSources/080442957X" class="internal mw-magiclink-isbn">ISBN 080442957x</a>
19652 <a href="/wiki/Special:BookSources/978080442957X" class="internal mw-magiclink-isbn">ISBN 978080442957X</a>
19653 <a href="/wiki/Special:BookSources/978080442957X" class="internal mw-magiclink-isbn">ISBN 978080442957x</a>
19656 <p><a href="./Special:BookSources/346204561X" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 3-462-04561-X</a>
19657 <a href="./Special:BookSources/346204561X" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 3-462-04561-x</a>
19658 <a href="./Special:BookSources/080442957X" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 080442957X</a>
19659 <a href="./Special:BookSources/080442957X" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 080442957x</a>
19660 <a href="./Special:BookSources/978080442957X" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 978080442957X</a>
19661 <a href="./Special:BookSources/978080442957X" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 978080442957x</a></p>
19665 ISBN with empty prefix (parsoid test)
19669 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
19672 <p><a href="./Special:BookSources/1234567890" rel="mw:WikiLink">ISBN 1234567890</a></p>
19676 Bug 22905: <abbr> followed by ISBN followed by </a>
19678 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
19680 <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>
19683 <p><abbr data-parsoid='{"stx":"html"}'>(fr)</abbr> <a href="./Special:BookSources/2753300917" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 2753300917</a> <a rel="mw:ExtLink" href="http://www.example.com">example.com</a></p>
19691 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
19696 Double RFC with a wiki link
19700 <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>
19709 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
19712 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987</p>
19716 Centre-aligned image
19718 [[Image:foobar.jpg|centre]]
19720 <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>
19727 [[Image:foobar.jpg|none]]
19729 <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>
19734 Width + Height sized image (using px) (height is ignored)
19736 [[Image:foobar.jpg|640x480px]]
19738 <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>
19743 Width-sized image (using px, no following whitespace)
19745 [[Image:foobar.jpg|640px]]
19747 <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>
19752 Width-sized image (using px, with following whitespace - test regression from r39467)
19754 [[Image:foobar.jpg|640px ]]
19756 <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>
19761 Width-sized image (using px, with preceding whitespace - test regression from r39467)
19763 [[Image:foobar.jpg| 640px]]
19765 <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>
19770 Image with page parameter
19774 [[File:LoremIpsum.djvu|page=2]]
19776 <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>
19779 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"page","ak":"page=2"}]}'><a href="./File:LoremIpsum.djvu" data-parsoid='{"a":{"href":"./File:LoremIpsum.djvu"},"sa":{}}'><img resource="./File:LoremIpsum.djvu" src="//example.com/images/5/5f/LoremIpsum.djvu" data-file-width="2480" data-file-height="3508" data-file-type="bitmap" height="3508" width="2480" data-parsoid='{"a":{"resource":"./File:LoremIpsum.djvu","height":"3508","width":"2480"},"sa":{"resource":"File:LoremIpsum.djvu"}}'/></a></span></p>
19783 Another italics / bold test
19791 # FIXME: The php output seems broken. It's interleaving some open/close tags.
19797 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd></dt></dl></dd></dl></dd></dl></dd></dl></dd></dl></dd></dl>
19800 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd></dd></dl></dd></dl></dt></dl></dt></dl></dt></dl></dd></dl>
19805 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
19807 Images with the "|" character in the comment
19809 [[File:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
19811 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>An <a rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&param2=%7Cx">external</a> URL</div></div></div>
19814 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>An <a rel="mw:ExtLink" href="http://test/?param1=|left|&param2=|x">external</a> URL</figcaption></figure>
19818 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
19820 <html><script>alert(1);</script></html>
19822 <p><html><script>alert(1);</script></html>
19827 HTML with raw HTML ($wgRawHtml==true)
19831 <html><script>alert(1);</script></html>
19833 <p><script>alert(1);</script>
19838 Parents of subpages, one level up
19840 subpage title=[[Subpage test/L1/L2/L3]]
19844 <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>
19850 Parents of subpages, one level up, not named
19852 subpage title=[[Subpage test/L1/L2/L3]]
19856 <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>
19863 Parents of subpages, two levels up
19865 subpage title=[[Subpage test/L1/L2/L3]]
19871 <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
19872 </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>
19877 Parents of subpages, two levels up, without trailing slash or name.
19879 subpage title=[[Subpage test/L1/L2/L3]]
19888 Parents of subpages, two levels up, with lots of extra trailing slashes.
19890 subpage title=[[Subpage test/L1/L2/L3]]
19894 <p><a href="/index.php?title=Subpage_test/L1&action=edit&redlink=1" class="new" title="Subpage test/L1 (page does not exist)">Subpage test/L1</a>
19899 Subpage test/L1/L2/L3Sibling
19905 Transclusion of a sibling page (one level up)
19907 subpage title=[[Subpage test/L1/L2/L3]]
19916 Transclusion of a child page
19918 subpage title=[[Subpage test/L1/L2]]
19926 # This is wt2html only in Parsoid because we add <nowiki>
19927 # because of {{..}} and we don't expect to fix that to
19928 # eliminate the nowikis selective for {{..}} markup.
19930 Non-transclusion because of too many up levels
19932 subpage title=[[Subpage test/L1/L2/L3]]
19935 {{../../../../More than parent}}
19937 <p>{{../../../../More than parent}}
19940 <p>{{../../../../More than parent}}</p>
19944 Definition list code coverage
19950 <dl><dt> title  </dt>
19952 <dt> title </dt>
19958 <dl><dt> title <span typeof="mw:Placeholder"> </span></dt><dd> def</dd>
19959 <dt> title<span typeof="mw:Placeholder"> </span></dt><dd> def</dd>
19960 <dt>title</dt><dd> def</dd></dl>
19964 Don't fall for the self-closing div
19966 <div>hello world</div/>
19968 <div>hello world</div>
19977 <p>[[:Template:Msg]]
19986 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
19990 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
19992 Always escape literal '>' in output, not just after '<'
20006 <p>This is a test template
20007 This is a test template
20019 Inclusion of !userCanEdit() content
20023 <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>
20029 Out-of-order TOC heading levels
20038 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
20040 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
20042 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
20043 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
20046 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
20048 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
20049 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
20055 <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>
20056 <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>
20057 <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>
20058 <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>
20059 <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>
20060 <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>
20066 ISBN with a dummy number
20076 ISBN with space-delimited number
20080 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
20086 ISBN with multiple spaces, no number
20105 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
20106 </p><p>ISBN 12345678901
20112 ISBN with trailing year (bug 8110)
20114 ISBN 1-234-56789-0 - 2006
20116 ISBN 1 234 56789 0 - 2006
20118 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
20119 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
20127 {{anchorencode:foo bar©#%n}}
20129 <p>foo_bar.C2.A9.23.25n
20134 anchorencode trims spaces
20136 {{anchorencode: __pretty__please__}}
20143 anchorencode deals with links
20145 {{anchorencode: [[hello|world]] [[hi]]}}
20152 anchorencode deals with templates
20154 {{anchorencode: {{Foo}} }}
20161 anchorencode encodes like the TOC generator: (bug 18431)
20163 === _ +:.3A%3A&&]] ===
20164 {{anchorencode: _ +:.3A%3A&&]] }}
20167 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
20168 <p>.2B:.3A.253A.26.26.5D.5D
20173 Bug 6200: blockquotes and paragraph formatting
20194 Bug 8293: Use of center tag ruins paragraph formatting
20215 Parsing of overlapping (improperly nested) inline html tags
20217 <span><s>x</span></s>
20219 <p><span><s>x</span></s></span>
20222 <p><span><s>x</s></span>
20227 ### Language variants related tests
20230 Self-link in language variants
20232 title=[[Dunav]] language=sr
20234 Both [[Dunav]] and [[Дунав]] are names for this river.
20236 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
20247 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
20249 title=[[Duna]] language=sr
20251 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
20253 <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.
20258 Link to a section of a variant of this title shouldn't be parsed as self-link
20260 title=[[Duna]] language=sr
20262 [[Dуна]] is a self-link while [[Dunа#Foo]] and [[Dуна#Foo]] are not self-links.
20264 <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.
20269 Link to pages in language variants
20273 Main Page can be written as [[Маин Паге]]
20275 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
20281 Multiple links to pages in language variants
20285 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
20287 <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>.
20293 Simple template in language variants
20299 <p>This is a test template
20305 Template with explicit namespace in language variants
20311 <p>This is a test template
20317 Basic test for template parameter in language variants
20321 {{парамтест|param=foo}}
20323 <p>This is a test template with parameter foo
20328 Simple category in language variants
20332 [[Category:МедиаWики Усер'с Гуиде]]
20334 cat=МедиаWики_Усер'с_Гуиде sort=
20336 <link rel="mw:PageProp/Category" href="./Категорија:МедиаWики_Усер'с_Гуиде" data-parsoid='{"stx":"simple","a":{"href":"./Категорија:МедиаWики_Усер'с_Гуиде"},"sa":{"href":"Category:МедиаWики Усер'с Гуиде"}}'/>
20351 ## We used to, but no longer wt2wt this test since the default serializer
20352 ## will normalize all categories to serialize on their own line.
20353 ## This wikitext usage is going to be fairly uncommon in production and
20354 ## selser will take care of preserving formatting in those scenarios.
20356 Don't convert blue categorylinks to another variant (bug 33210)
20362 [[A]][[Category:分类]]
20366 <p><a rel="mw:WikiLink" href="A" title="A">A</a></p>
20367 <link rel="mw:PageProp/Category" href="Category:分类"/>
20371 Stripping -{}- tags (language variants)
20375 Latin proverb: -{Ne nuntium necare}-
20377 <p>Latin proverb: Ne nuntium necare
20383 Prevent conversion with -{}- tags (language variants)
20385 language=sr variant=sr-ec
20387 Latinski: -{Ne nuntium necare}-
20389 <p>Латински: Ne nuntium necare
20395 Prevent conversion of text with -{}- tags (language variants)
20397 language=sr variant=sr-ec
20399 Latinski: -{Ne nuntium necare}-
20401 <p>Латински: Ne nuntium necare
20407 Prevent conversion of links with -{}- tags (language variants)
20409 language=sr variant=sr-ec
20413 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
20419 -{}- tags within headlines (within html for parserConvert())
20421 language=sr variant=sr-ec
20425 <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>
20431 Explicit definition of language variant alternatives
20433 language=zh variant=zh-tw
20435 -{zh:China;zh-tw:Taiwan}-, not China
20437 <p>Taiwan, not China
20443 Conversion around HTML tags
20445 language=sr variant=sr-ec
20447 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
20448 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
20451 <span title="ЛаCтин">ски</span>
20457 Explicit session-wise language variant mapping (A flag and - flag)
20459 language=zh variant=zh-tw
20461 Taiwan is not China.
20462 But -{A|zh:China;zh-tw:Taiwan}- is China,
20463 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
20464 and -{China}- is China.
20466 <p>Taiwan is not China.
20467 But Taiwan is Taiwan,
20468 (This should be stripped!)
20469 and China is China.
20474 Explicit session-wise language variant mapping (H flag for hide)
20476 language=zh variant=zh-tw
20478 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
20481 <p>(This should be stripped!)
20487 Adding explicit conversion rule for title (T flag)
20489 language=zh variant=zh-tw showtitle
20491 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
20494 <p>Should be stripped!
20499 Testing that changing the language variant here in the tests actually works
20501 language=zh variant=zh showtitle
20503 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
20506 <p>Should be stripped!
20511 Recursive conversion of alt and title attrs shouldn't clear converter state
20513 language=zh variant=zh-cn showtitle
20515 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
20516 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
20520 Should be stripped<span title="Exclamation">!</span>
20525 Bug 24072: more test on conversion rule for title
20527 language=zh variant=zh-tw showtitle
20529 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
20530 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
20533 <p>This should be stripped!
20534 This won't take interferes with the title rule.
20539 Partly disable title conversion if variant == main language code
20541 language=zh variant=zh title=[[ZH]] showtitle
20543 -{T|zh-cn:CN;zh-tw:TW}-
20551 Partly disable title conversion if variant == main language code, more
20553 language=zh variant=zh title=[[ZH]] showtitle
20563 Raw output of variant escape tags (R flag)
20565 language=zh variant=zh-tw
20567 Raw: -{R|zh:China;zh-tw:Taiwan}-
20569 <p>Raw: zh:China;zh-tw:Taiwan
20574 Strings evaluating false shouldn't be ignored by Language converter (T51072)
20576 language=zh variant=zh-cn
20578 -{zh-cn:0;zh-sg:1;zh-tw:2;zh-hk:3}-
20585 Conversion rules from [numeric-only string] to [something else] (T48634)
20587 language=zh variant=zh-cn
20589 -{H|0=>zh-cn:B}--{H|0=>zh-cn:C;0=>zh-cn:D}--{H|0=>zh-hans:A}-012345-{A|zh-tw:0;zh-cn:E;}-012345
20596 Bidirectional converter rule entries with an empty value should be ignored (T53551)
20598 language=zh variant=zh-cn
20600 -{H|zh-cn:foo;zh-tw:;}-foobar
20607 Unidirectional converter rule entries with an empty "from" string should be ignored (T53551)
20609 language=zh variant=zh-cn
20611 -{H|=>zh-cn:foo;}-foobar
20618 Empty converter rule entries shouldn't be inserted into the conversion table (T53551)
20620 language=zh variant=zh-cn
20629 Nested using of manual convert syntax
20631 language=zh variant=zh-hk
20633 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
20635 <p>Nested: Hello Hong Kong!
20639 # Since Parsoid is starting to emit canonical wikitext for links,
20640 # [http://example.com http://example.com] will not RT back to that
20643 Proper conversion of text in external links
20645 language=sr variant=sr-ec
20648 http://www.google.com
20649 gopher://www.google.com
20650 [http://www.google.com http://www.google.com]
20651 [gopher://www.google.com gopher://www.google.com]
20652 [https://www.google.com irc://www.google.com]
20653 [ftp://www.google.com www.google.com/ftp://dir]
20654 [//www.google.com www.google.com]
20656 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
20657 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
20658 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
20659 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
20660 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
20661 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
20662 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
20665 <p><a rel="mw:ExtLink" href="http://www.google.com">http://www.google.com</a>
20666 <a rel="mw:ExtLink" href="gopher://www.google.com">gopher://www.google.com</a>
20667 <a rel="mw:ExtLink" href="http://www.google.com">http://www.google.com</a>
20668 <a rel="mw:ExtLink" href="gopher://www.google.com">gopher://www.google.com</a>
20669 <a rel="mw:ExtLink" href="https://www.google.com">irc://www.google.com</a>
20670 <a rel="mw:ExtLink" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
20671 <a rel="mw:ExtLink" href="//www.google.com">www.гоогле.цом</a></p>
20675 Do not convert roman numbers to language variants
20677 language=sr variant=sr-ec
20681 <p>Фридрих IV је цар.
20686 Unclosed language converter markup "-{"
20697 Don't convert raw rule "-{R|=>}-" to "=>"
20708 Don't break link parsing if language converter markup is in the caption.
20710 language=sr variant=sr-ec
20712 [[Main Page|-{R|main page}-]]
20714 <p><a href="/wiki/Main_Page" title="Маин Паге">main page</a>
20718 # FIXME: This test is currently broken in the PHP parser T153761
20720 T146304: Don't break template parsing if language converter markup is in the parameter.
20722 language=sr variant=sr-ec
20732 T146305: Don't break image parsing if language converter markup is in the caption.
20736 [[File:Foobar.jpg|thumb|-{R|caption:}-]]
20738 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/%D0%94%D0%B0%D1%82%D0%BE%D1%82%D0%B5%D0%BA%D0%B0: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/%D0%94%D0%B0%D1%82%D0%BE%D1%82%D0%B5%D0%BA%D0%B0:Foobar.jpg" class="internal" title="Повећај"></a></div>caption:</div></div></div>
20741 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="./Датотека:Foobar.jpg"><img resource="./Датотека:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><span typeof="mw:LanguageVariant" data-mw='{"disabled":true,"show":true,"text":"caption:"}'></span></figcaption></figure>
20745 T146305: Don't break image parsing if nested language converter markup is in the caption.
20747 language=zh variant=zh-cn
20749 [[File:Foobar.jpg|thumb|-{zh-cn:blog (hk: -{zh-hans|WEBJOURNAL}-, tw: -{zh-hans|WEBLOG}-)}-]]
20751 <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="放大"></a></div>blog (hk: WEBJOURNAL, tw: WEBLOG)</div></div></div>
20754 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><span typeof="mw:LanguageVariant" data-mw='{"bidir":[{"l":"zh-cn","t":"blog (hk: <span typeof=\"mw:LanguageVariant\" data-parsoid='{\"fl\":[\"zh-hans\"],\"dsr\":[42,64,null,2]}' data-mw='{\"filter\":[\"zh-hans\"],\"text\":\"WEBJOURNAL\"}'></span>, tw: <span typeof=\"mw:LanguageVariant\" data-parsoid='{\"fl\":[\"zh-hans\"],\"dsr\":[70,88,null,2]}' data-mw='{\"filter\":[\"zh-hans\"],\"text\":\"WEBLOG\"}'></span>)"}],"show":true}'></span></figcaption></figure>
20758 Don't break gallery if language converter markup is inside.
20763 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=-{R|foo}-|-{R|bar}-]]|alt=-{R|bat}-
20764 File:foobar.jpg|{{Test|unamedParam|alt=-{R|param}-}}|alt=galleryalt
20767 <ul class="gallery mw-gallery-traditional">
20768 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
20769 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="bat" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
20770 <div class="gallerytext">
20771 <p><a href="/wiki/File:Foobar.jpg" class="image" title="bar"><img alt="foo" 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>
20775 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
20776 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
20777 <div class="gallerytext">
20778 <p>This is a test template
20786 # FIXME: This test is currently broken in the PHP parser (bug 52661)
20788 Don't break list handling if language converter markup is in the item.
20790 language=zh variant=zh-cn
20792 ;-{zh-cn:AAA;zh-tw:BBB}-
20794 <dl><dt><span class="error">在手动语言转换规则中检测到错误</span></dd></dl>
20802 T153140: Don't break table handling if language converter markup is in the cell.
20804 language=sr variant=sr-ec
20827 Bug 529: Uncovered bullet
20836 # Plain MediaWiki does not remove empty lists, but tidy actually does.
20837 # Templates in Wikipedia rely on this behavior, as tidy has always been
20838 # enabled there. These tests are normally run *without* tidy, so specify the
20839 # full output here.
20840 # To test realistic parsing behavior, apply a tidy-like transformation to both
20841 # the expected output and your parser's output.
20843 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
20845 ******* Foo {{bullet}}
20847 <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>
20853 Bug 529: Uncovered table already at line-start
20876 Bug 529: Uncovered bullet in parser function result
20878 * Foo {{lc:{{bullet}} }}
20886 Bug 5678: Double-parsed template argument
20888 {{lc:{{{1}}}|hello}}
20895 Bug 5678: Double-parsed template invocation
20897 {{lc:{{paramtest {{!}} param = hello }} }}
20899 <p>{{paramtest | param = hello }}
20904 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
20907 title=[[Main Page]]
20909 {{PRVNÍVELKÉ:ěščř}}
20910 {{prvnívelké:ěščř}}
20930 Morwen/13: Unclosed link followed by heading
20937 <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>
20942 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
20949 <h1><span class="mw-headline" id="heading">heading</span></h1>
20954 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
20961 <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>
20976 Paragraphs inside divs (no extra line breaks)
20988 Paragraphs inside divs (extra line break on open)
21003 Paragraphs inside divs (extra line break on close)
21018 Paragraphs inside divs (extra line break on open and close)
21035 Nesting tags, paragraphs on lines which begin with <div>
21037 <div></div><strong>A
21040 <p><strong>A</strong></p>
21041 <p><strong>B</strong></p>
21049 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
21051 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
21053 <blockquote>Line one
21055 Line two</blockquote>
21057 <blockquote>Line one
21058 Line two</blockquote>
21062 <p>Line one Line two</p>
21067 Bug 6200: paragraphs inside blockquotes (extra line break on open)
21072 Line two</blockquote>
21077 Line two</blockquote>
21082 Line two</blockquote>
21086 Bug 6200: paragraphs inside blockquotes (extra line break on close)
21088 <blockquote>Line one
21093 <blockquote>Line one
21106 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
21128 Paragraphs inside blockquotes/divs (no extra line breaks)
21130 <blockquote><div>Line one
21132 Line two</div></blockquote>
21134 <blockquote><div>Line one
21135 Line two</div></blockquote>
21140 Paragraphs inside blockquotes/divs (extra line break on open)
21145 Line two</div></blockquote>
21150 Line two</div></blockquote>
21155 Paragraphs inside blockquotes/divs (extra line break on close)
21157 <blockquote><div>Line one
21160 </div></blockquote>
21162 <blockquote><div>Line one
21165 </div></blockquote>
21170 Paragraphs inside blockquotes/divs (extra line break on open and close)
21176 </div></blockquote>
21182 </div></blockquote>
21187 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
21189 wgLinkHolderBatchSize=0
21195 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
21196 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
21197 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
21202 Free external link invading image caption
21204 [[Image:Foobar.jpg|thumb|http://x|hello]]
21206 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>hello</div></div></div>
21211 Bug 15196: localised external link numbers
21215 [http://en.wikipedia.org/]
21217 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
21220 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/"></a></p>
21224 Multibyte character in padleft
21226 {{padleft:-Hello|7|Æ}}
21233 Multibyte character in padright
21235 {{padright:Hello-|7|Æ}}
21242 formatdate parser function
21244 {{#formatdate:2009-03-24}}
21246 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
21251 formatdate parser function, with default format
21253 {{#formatdate:2009-03-24|mdy}}
21255 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
21260 Spacing of numbers in formatted dates
21262 {{#formatdate:January 15}}
21264 <p><span class="mw-formatted-date" title="01-15">January 15</span>
21269 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
21271 language=nl title=[[MediaWiki:Common.css]]
21273 {{#formatdate:2009-03-24|dmy}}
21275 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
21288 Edit comment with link
21292 I like the [[Main Page]] a lot
21294 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
21298 Edit comment with link and link text
21302 I like the [[Main Page|best pages]] a lot
21304 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
21308 Edit comment with link and link text with suffix
21312 I like the [[Main Page|best page]]s a lot
21314 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
21318 Edit comment with section link (non-local, eg in history list)
21320 comment title=[[Main Page]]
21322 /* External links */ removed bogus entries
21324 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
21328 Edit comment with section link and text before it (non-local, eg in history list)
21330 comment title=[[Main Page]]
21332 pre-comment text /* External links */ removed bogus entries
21334 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>
21338 Edit comment with section link (local, eg in diff view)
21340 comment local title=[[Main Page]]
21342 /* External links */ removed bogus entries
21344 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
21348 Edit comment with subpage link (bug 14080)
21352 title=[[Subpage test]]
21354 Poked at a [[/subpage]] here...
21356 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
21360 Edit comment with subpage link and link text (bug 14080)
21364 title=[[Subpage test]]
21366 Poked at a [[/subpage|neat little page]] here...
21368 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
21372 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
21375 title=[[Subpage test]]
21377 Poked at a [[/subpage]] here...
21379 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
21383 Edit comment with bare anchor link (local, as on diff)
21387 title=[[Main Page]]
21391 <a href="#section">#section</a>
21395 Edit comment with bare anchor link (non-local, as on history)
21398 title=[[Main Page]]
21402 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
21406 Anchor starting with underscore
21412 <p><a href="#_ref">One</a>
21415 <p><a rel="mw:WikiLink" href="./Foo#_ref" data-parsoid='{"stx":"piped","a":{"href":"./Foo#_ref"},"sa":{"href":"#_ref"}}'>One</a></p>
21419 Id starting with underscore
21421 <div id="_ref"></div>
21423 <div id="_ref"></div>
21428 Edit comment with link with more than one pipe (T99346)
21432 [[Main Page|Many|pipes]]
21434 <a href="/wiki/Main_Page" title="Main Page">Many|pipes</a>
21438 Complex edit comment with link with more than one pipe (T99346)
21442 Created page with "<noinclude>[[Category:Requests for permissions/Bot|{{subst:#titleparts:{{subst:PAGENAME}}|1|3}}]]</noinclude> === [[User:MineoBot|]] 8=== {{Request for permissions/links|Mineo..."
21444 Created page with "<noinclude><a href="/index.php?title=Category:Requests_for_permissions/Bot&action=edit&redlink=1" class="new" title="Category:Requests for permissions/Bot (page does not exist)">{{subst:#titleparts:{{subst:PAGENAME}}|1|3}}</a></noinclude> === <a href="/index.php?title=User:MineoBot&action=edit&redlink=1" class="new" title="User:MineoBot (page does not exist)">User:MineoBot</a> 8=== {{Request for permissions/links|Mineo..."
21448 Space normalisation on autocomment (bug 22784)
21451 title=[[Main Page]]
21453 /* __hello__world__ */
21455 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
21459 percent-encoding and + signs in comments (Bug 26410)
21463 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
21465 <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>
21468 # Parsoid doesn't support this yet: see bug 73581
21469 # but it *should* omit the 'src' attribute if the image is bad.
21470 # PHP side of tests was disabled in
21471 # mediawiki/core:6bd31e7d95161a6e88fa86df60871051da997c3c
21472 # because of issues in the PHP parserTests infrastructure
21473 # (but the output below is indeed what the PHP side emits)
21475 Bad images - basic functionality
21478 !! DISABLED/html/php
21480 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"bad-image","message":"This image is blacklisted in this context."}]}'><a href="./File:Bad.jpg"><img resource="./File:Bad.jpg" height="220" width="220"/></a></span></p>
21484 Bad images - bug 16039: text after bad image disappears
21489 !! DISABLED/html/php
21495 <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"bad-image","message":"This image is blacklisted in this context."}]}'><a href="./File:Bad.jpg"><img resource="./File:Bad.jpg" height="220" width="220"/></a></span>
21500 Verify that displaytitle works (bug #22501) no displaytitle
21504 wgAllowDisplayTitle=true
21505 wgRestrictDisplayTitle=false
21507 this is not the the title
21510 <p>this is not the the title
21515 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
21520 wgAllowDisplayTitle=true
21521 wgRestrictDisplayTitle=false
21523 this is not the the title
21524 {{DISPLAYTITLE:whatever}}
21527 <p>this is not the the title
21532 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
21537 wgAllowDisplayTitle=true
21538 wgRestrictDisplayTitle=true
21540 this is not the the title
21541 {{DISPLAYTITLE:whatever}}
21544 <p>this is not the the title
21549 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
21554 wgAllowDisplayTitle=true
21555 wgRestrictDisplayTitle=true
21557 this is not the the title
21558 {{DISPLAYTITLE:screen}}
21561 <p>this is not the the title
21566 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
21571 wgAllowDisplayTitle=false
21573 this is not the the title
21574 {{DISPLAYTITLE:screen}}
21577 <p>this is not the the title
21578 <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>
21583 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
21588 wgAllowDisplayTitle=false
21590 this is not the the title
21593 <p>this is not the the title
21598 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
21603 wgAllowDisplayTitle=true
21604 wgRestrictDisplayTitle=true
21606 this is not the the title
21607 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
21609 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
21610 <p>this is not the the title
21615 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
21620 wgAllowDisplayTitle=true
21621 wgRestrictDisplayTitle=true
21623 this is not the the title
21624 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
21626 <span style="color: red;">s</span>creen
21627 <p>this is not the the title
21632 Page status indicators: Empty name is invalid
21636 <indicator name=" "></indicator>
21637 <indicator></indicator>
21639 <p><span class="error"><strong>Error:</strong> Page status indicators' <code>name</code> attribute must not be empty.</span>
21640 <span class="error"><strong>Error:</strong> Page status indicators' <code>name</code> attribute must not be empty.</span>
21645 Page status indicators: Weird syntaxes that are okay
21649 <indicator name="empty" />
21650 <indicator name="name"></indicator>
21659 Page status indicators: Torture test
21663 <indicator name="01">hello world</indicator>
21664 <indicator name="02">[[Main Page]]</indicator>
21665 <indicator name="03">[[File:Foobar.jpg|25px|link=]]</indicator>
21666 <indicator name="04">[[File:Foobar.jpg|25px]]</indicator>
21667 <indicator name="05">* foo
21669 <indicator name="06"><nowiki>foo</nowiki></indicator>
21670 <indicator name="07"> Preformatted</indicator>
21671 <indicator name="08"><div>Broken tag</indicator>
21672 <indicator name="09">{| class=wikitable
21675 <indicator name="10">Two
21677 paragraphs</indicator>
21680 02=<a href="/wiki/Main_Page" title="Main Page">Main Page</a>
21681 03=<img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/25px-Foobar.jpg" width="25" height="3" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/38px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg 2x" />
21682 04=<a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/25px-Foobar.jpg" width="25" height="3" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/38px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg 2x" /></a>
21683 05=<ul><li> foo</li>
21687 07=<pre>Preformatted
21689 08=<div>Broken tag</div>
21691 09=<table class="wikitable">
21708 preload: check <noinclude> and <includeonly>
21712 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
21718 preload: check <onlyinclude>
21722 Goodbye <onlyinclude>Hello world</onlyinclude>
21728 preload: can pass tags through if we want to
21732 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
21734 <includeonly>Hello world</includeonly>
21738 preload: check that it doesn't try to do tricks
21742 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
21744 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
21748 Play a bit with r67090 and bug 3158
21750 <div style="width:50% !important"> </div>
21751 <div style="width:50% !important"> </div>
21752 <div style="width:50% !important"> </div>
21753 <div style="border : solid;"> </div>
21755 <div style="width:50% !important"> </div>
21756 <div style="width:50% !important"> </div>
21757 <div style="width:50% !important"> </div>
21758 <div style="border : solid;"> </div>
21761 <div style="width:50% !important" data-parsoid='{"stx":"html"}'><span typeof="mw:Entity" data-parsoid='{"srcContent":" "}'> </span></div>
21762 <div style="width:50% !important" data-parsoid='{"stx":"html","a":{"style":"width:50% !important"},"sa":{"style":"width:50%&nbsp;!important"}}'><span typeof="mw:Entity" data-parsoid='{"srcContent":" "}'> </span></div>
21763 <div style="width:50% !important" data-parsoid='{"stx":"html","a":{"style":"width:50% !important"},"sa":{"style":"width:50%&#160;!important"}}'><span typeof="mw:Entity" data-parsoid='{"srcContent":" "}'> </span></div>
21764 <div style="border : solid;" data-parsoid='{"stx":"html"}'><span typeof="mw:Entity" data-parsoid='{"srcContent":" "}'> </span></div>
21769 HTML5 data attributes
21771 <span data-foo="bar">Baz</span>
21772 <p data-abc-def_hij="">Quuz</p>
21774 <p><span data-foo="bar">Baz</span>
21776 <p data-abc-def_hij="">Quuz</p>
21779 <p><span data-foo="bar" data-parsoid='{"stx":"html"}'>Baz</span></p>
21780 <p data-abc-def_hij="" data-parsoid='{"stx":"html"}'>Quuz</p>
21784 Strip reserved data attributes
21786 <div data-mw="foo" data-parsoid="bar" data-mw-someext="baz" data-ok="fred" data-ooui="xyzzy" data-bad:ns="ns">d</div>
21788 <div data-ok="fred">d</div>
21791 <div data-x-data-mw="foo" data-x-data-parsoid="bar" data-x-data-mw-someext="baz" data-ok="fred" data-parsoid='{"stx":"html","a":{"data-ooui":null,"data-bad:ns":null},"sa":{"data-ooui":"xyzzy","data-bad:ns":"ns"}}'>d</div>
21795 percent-encoding and + signs in internal links (Bug 26410)
21797 [[User:+%]] [[Page+title%]]
21798 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
21799 [[%]] [[+]] [[File:%+abc%39|foo|[[bar]]]]
21800 [[%33%45]] [[%33%45+]]
21802 <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>
21803 <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>
21804 <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>
21805 <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>
21808 <p><a rel="mw:WikiLink" href="./User:+%25" title="User:+%" data-parsoid='{"stx":"simple","a":{"href":"./User:+%25"},"sa":{"href":"User:+%"}}'>User:+%</a> <a rel="mw:WikiLink" href="./Page+title%25" title="Page+title%" data-parsoid='{"stx":"simple","a":{"href":"./Page+title%25"},"sa":{"href":"Page+title%"}}'>Page+title%</a>
21809 <a rel="mw:WikiLink" href="./%25+" title="%+" data-parsoid='{"stx":"simple","a":{"href":"./%25+"},"sa":{"href":"%+"}}'>%+</a> <a rel="mw:WikiLink" href="./%25+" title="%+" data-parsoid='{"stx":"piped","a":{"href":"./%25+"},"sa":{"href":"%+"}}'>%20</a> <a rel="mw:WikiLink" href="./%25+" title="%+" data-parsoid='{"stx":"simple","a":{"href":"./%25+"},"sa":{"href":"%+ "}}'>%+ </a> <a rel="mw:WikiLink" href="./%25+r" title="%+r" data-parsoid='{"stx":"simple","a":{"href":"./%25+r"},"sa":{"href":"%+r"}}'>%+r</a>
21810 <a rel="mw:WikiLink" href="./%25" title="%" data-parsoid='{"stx":"simple","a":{"href":"./%25"},"sa":{"href":"%"}}'>%</a> <a rel="mw:WikiLink" href="./+" title="+" data-parsoid='{"stx":"simple","a":{"href":"./+"},"sa":{"href":"+"}}'>+</a> <span class="mw-default-size" typeof="mw:Error mw:Image" data-parsoid='{"optList":[{"ck":"bogus","ak":"foo"},{"ck":"caption","ak":"[[bar]]"}]}' data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"<a rel=\"mw:WikiLink\" href=\"./Bar\" title=\"Bar\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Bar\"},\"sa\":{\"href\":\"bar\"},\"dsr\":[94,101,2,2]}'>bar</a>"}'><a href="./File:%25+abc9" data-parsoid='{"a":{"href":"./File:%25+abc9"},"sa":{}}'><img resource="./File:%25+abc9" src="./Special:FilePath/%25+abc9" height="220" width="220" data-parsoid='{"a":{"resource":"./File:%25+abc9","height":"220","width":"220"},"sa":{"resource":"File:%+abc%39"}}'/></a></span>
21811 <a rel="mw:WikiLink" href="./3E" title="3E" data-parsoid='{"stx":"simple","a":{"href":"./3E"},"sa":{"href":"%33%45"}}'>3E</a> <a rel="mw:WikiLink" href="./3E+" title="3E+" data-parsoid='{"stx":"simple","a":{"href":"./3E+"},"sa":{"href":"%33%45+"}}'>3E+</a></p>
21815 Special characters in embedded file links (bug 27679)
21817 [[File:Contains & ampersand.jpg]]
21818 [[File:Does not exist.jpg|Title with & ampersand]]
21820 <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>
21821 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
21824 <p><span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}]}'><a href="./File:Contains_&_ampersand.jpg"><img resource="./File:Contains_&_ampersand.jpg" src="./Special:FilePath/Contains_&_ampersand.jpg" height="220" width="220"/></a></span>
21825 <span class="mw-default-size" typeof="mw:Error mw:Image" data-mw='{"errors":[{"key":"missing-image","message":"This image does not exist."}],"caption":"Title with &amp; ampersand"}'><a href="./File:Does_not_exist.jpg"><img resource="./File:Does_not_exist.jpg" src="./Special:FilePath/Does_not_exist.jpg" height="220" width="220"/></a></span></p>
21829 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
21831 Text's been normalized?
21833 <p>Text's been normalized?
21838 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
21840 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
21842 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
21847 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
21849 [http://www.example.org/ ideograms]
21851 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
21856 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
21858 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
21860 <p><img src="http://www.example.org/pic.png" alt="pic.png"/> <-- U+3000 (vim: ^Vu3000)
21884 Bug 31098 Template which includes system messages which includes the template
21888 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
21889 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
21894 Bug31490 Turkish: ucfirst 'blah'
21905 Bug31490 Turkish: ucfirst 'ix'
21916 Bug31490 Turkish: lcfirst 'BLAH'
21927 Bug31490 Turkish: ucfırst (with a dotless i)
21933 <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>
21938 Bug31490 ucfırst (with a dotless i) with English language
21944 <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>
21949 Bug 26375: TOC with italics
21951 title=[[Main Page]]
21954 == ''Lost'' episodes ==
21956 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
21958 <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>
21962 <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>
21967 Bug 26375: TOC with bold
21969 title=[[Main Page]]
21972 == '''should be bold''' then normal text ==
21974 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
21976 <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>
21980 <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>
21985 Bug 33845: Headings become cursive in TOC when they contain an image
21987 title=[[Main Page]]
21990 == Image [[Image:foobar.jpg]] ==
21992 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
21994 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
21998 <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>
22003 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
22005 title=[[Main Page]]
22008 == <blockquote>Quote</blockquote> ==
22010 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22012 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
22016 <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>
22020 <div id="toc" class="toc">
22021 <div id="toctitle">
22025 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
22029 <h2><span class="mw-headline" id="Quote"></span></h2>
22031 <p><span class="mw-headline" id="Quote">Quote</span></p>
22033 <p><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Quote">edit</a><span class="mw-editsection-bracket">]</span></span></p>
22037 Unclosed tags in TOC
22039 title=[[Main Page]]
22043 <small>Hanc marginis exiguitas non caperet.</small>
22046 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22048 <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>
22052 <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>
22053 <p><small>Hanc marginis exiguitas non caperet.</small>
22059 Multiple tags in TOC
22062 == <i>Foo</i> <b>Bar</b> ==
22064 == <i>Foo</i> <blockquote>Bar</blockquote> ==
22066 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22068 <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>
22069 <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>
22073 <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>
22074 <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>
22078 <div id="toc" class="toc">
22079 <div id="toctitle">
22083 <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>
22084 <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>
22088 <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>
22089 <h2><span class="mw-headline" id="Foo_Bar_2"><i>Foo</i></span></h2>
22091 <p><span class="mw-headline" id="Foo_Bar_2">Bar</span></p>
22093 <p><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></p>
22096 # Don't expect Parsoid to roundtrip this until the php parser comes closer to
22097 # html5 tag parsing.
22099 Tags with parameters in TOC
22104 == <sup class="in-h2">Hello</sup> ==
22106 == <sup class="a > b">Evilbye</sup> ==
22108 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22110 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
22111 <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>
22115 <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>
22116 <h2><span class="mw-headline" id="b.22.3EEvilbye"><sup class="a"> 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>
22119 <meta property="mw:PageProp/toc" />
22120 <h2> <sup class="in-h2" data-parsoid='{"stx":"html"}'>Hello</sup> </h2>
22122 <h2> <sup class="a " data-parsoid='{"stx":"html"}'> b">Evilbye</sup> </h2>
22126 span tags with directionality in TOC
22129 == <span dir="ltr">C++</span> ==
22131 == <span dir="rtl">זבנג!</span> ==
22133 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
22135 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
22137 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
22139 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22141 <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>
22142 <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>
22143 <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>
22144 <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>
22145 <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>
22149 <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>
22150 <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>
22151 <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>
22152 <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>
22153 <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>
22158 Bug 72884: bdi element in ToC
22161 == <bdi>test</bdi> ==
22163 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22165 <li class="toclevel-1 tocsection-1"><a href="#test"><span class="tocnumber">1</span> <span class="toctext"><bdi>test</bdi></span></a></li>
22169 <h2><span class="mw-headline" id="test"><bdi>test</bdi></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: test">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
22174 T35715: s/strike element in ToC
22177 == <s>test</s> test <strike>test</strike> ==
22179 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22181 <li class="toclevel-1 tocsection-1"><a href="#test_test_test"><span class="tocnumber">1</span> <span class="toctext"><s>test</s> test <strike>test</strike></span></a></li>
22185 <h2><span class="mw-headline" id="test_test_test"><s>test</s> test <strike>test</strike></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: test test test">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
22189 # Note that the html output does not have the <p></p>, but the
22190 # html+tidy output *does*. This is because the empty <p></p> is
22191 # removed by the sanitizer, but only when tidy is *not* enabled (!).
22193 Empty <p> tag in TOC, removed by Sanitizer (T92892)
22198 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
22200 <li class="toclevel-1 tocsection-1"><a href="#x"><span class="tocnumber">1</span> <span class="toctext">x</span></a></li>
22204 <h2><span class="mw-headline" id="x">x</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: x">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
22208 <div id="toc" class="toc">
22209 <div id="toctitle">
22213 <li class="toclevel-1 tocsection-1"><a href="#x"><span class="tocnumber">1</span> <span class="toctext">x</span></a></li>
22217 <h2><span class="mw-headline" id="x">x</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: x">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
22223 == {{int:headline_sample}} ==
22227 Bug 32057: Title needed when expanding <h> nodes.
22229 title=[[Main Page]]
22233 <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>
22238 Strip marker in urlencode
22240 {{urlencode:x<nowiki/>y}}
22241 {{urlencode:x<nowiki/>y|wiki}}
22242 {{urlencode:x<nowiki/>y|path}}
22243 {{urlencode:x<pre id="one">two</pre>y}}
22271 Strip marker in formatNum
22273 {{formatnum:1<nowiki/>2}}
22274 {{formatnum:1<nowiki/>2|R}}
22282 Check noCommafy in formatNum
22286 {{formatnum:123456.78}}
22287 {{formatnum:123456.78|NOSEP}}
22295 Wrong option for formatNum (bug 56199)
22297 {{formatnum:1,234.56|Random}}
22298 {{formatnum:1,234.56|EVERYTHING}}
22299 {{formatnum:1234.56|any argument that has the string 'NOSEP'}}
22308 Strip marker in grammar
22312 {{grammar:elative|foo<nowiki/>bar}}
22319 Strip marker in padleft
22321 {{padleft:|2|x<nowiki/>y}}
22328 Strip marker in padright
22330 {{padright:|2|x<nowiki/>y}}
22337 Strip marker in anchorencode
22339 {{anchorencode:x<nowiki/>y}}
22346 nowiki inside link inside heading (bug 18295)
22348 ==[[foo|x<nowiki>y</nowiki>z]]==
22350 <h2><span class="mw-headline" id="xyz"><a href="/wiki/Foo" title="Foo">xyz</a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: xyz">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
22355 new support for bdi element (bug 31817)
22357 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
22359 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
22364 Ignore pipe between table row attributes
22368 |- id=foo | style='color: red'
22376 <tr id="foo" style="color: red">
22383 Gallery override link with WikiLink (bug 34852)
22386 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
22389 <ul class="gallery mw-gallery-traditional">
22390 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
22391 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
22392 <div class="gallerytext">
22402 Gallery override link with absolute external link (bug 34852)
22405 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
22408 <ul class="gallery mw-gallery-traditional">
22409 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
22410 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
22411 <div class="gallerytext">
22421 Gallery override link with absolute external link with LanguageConverter
22426 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
22429 <ul class="gallery mw-gallery-traditional">
22430 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
22431 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
22432 <div class="gallerytext">
22442 Gallery override link with malicious javascript (bug 34852)
22445 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
22448 <ul class="gallery mw-gallery-traditional">
22449 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
22450 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
22451 <div class="gallerytext">
22461 Gallery with invalid title as link (bug 43964)
22464 File:foobar.jpg|link=<
22467 <ul class="gallery mw-gallery-traditional">
22468 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
22469 <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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/240px-Foobar.jpg 2x" /></a></div></div>
22470 <div class="gallerytext">
22478 Language parser function
22487 Padleft and padright as substr
22489 {{padleft:|3|abcde}}
22490 {{padright:|3|abcde}}
22498 Special parser function
22500 {{#special:RandomPage}}
22501 {{#special:BaDtItLe}}
22502 {{#special:Foobar}}
22511 Bug 34939 - Case insensitive link parsing ([HttP://])
22513 [HttP://MediaWiki.Org/]
22515 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
22518 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/"></a></p>
22522 Bug 34939 - Case insensitive link parsing ([HttP:// title])
22524 [HttP://MediaWiki.Org/ MediaWiki]
22526 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
22531 Bug 34939 - Case insensitive link parsing (HttP://)
22533 HttP://MediaWiki.Org/
22535 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
22538 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a></p>
22556 <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>
22557 <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>
22558 <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>
22559 <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>
22560 <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>
22566 ### Parsoid-specific tests
22567 ### Parsoid-PHP parser incompatibilities
22570 1. SOL-sensitive wikitext tokens as template-args
22572 parsoid=wt2html,wt2wt
22578 <span about="#mwt1" typeof="mw:Transclusion">
22579 </span><ul about="#mwt1"><li>a</li>
22581 <span about="#mwt2" typeof="mw:Transclusion">
22582 </span><ol about="#mwt2"><li>a</li>
22584 <span about="#mwt3" typeof="mw:Transclusion">
22585 </span><dl about="#mwt3"><dd>a</dd>
22589 #### -----------------------------------------------------------------
22590 #### Parsoid-specific functionality tests
22591 #### -----------------------------------------------------------------
22593 # Bug 63642/66749: Formatting elt fixup around images is cleaned up.
22594 # We know wt2wt will fail, but we expect selser to pass.
22595 # Due to the nature of our testing, wt2wt and selser tests will enter the
22596 # blacklist and we'll catch selser regressions based on changes to the
22597 # blacklist entries for selser tests.
22599 1. Bad treebuilder fixup of formatting elt is cleaned up
22601 parsoid=wt2html,wt2wt
22606 [[Image:Foobar.jpg|right|Test]]
22613 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941"/></a><figcaption>Test</figcaption></figure>
22620 2. Bad treebuilder fixup of formatting elt is cleaned up
22622 parsoid=wt2html,wt2wt
22624 '''foo[[File:Foobar.jpg|thumb|caption]]bar'''
22626 <small>[[Image:Foobar.jpg|right|300px]]</small>
22630 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><b>caption</b></figcaption></figure>
22632 <small><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/300px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="34" width="300"/></a></figure></small>
22636 3. Bad treebuilder fixup of formatting elt is cleaned up
22638 parsoid=wt2html,wt2wt
22640 <small>'''foo[[File:Foobar.jpg|thumb|caption]]bar'''</small>
22642 <p><small><b>foo</b></small></p>
22643 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><small><b>caption</b></small></figcaption></figure>
22644 <p><small><b>bar</b></small></p>
22648 4. Bad treebuilder fixup of formatting elt is cleaned up: formatting tags around captionless images are ignored
22650 parsoid=wt2html,wt2wt
22652 '''<small>[[Image:Foobar.jpg|right|300px]]</small>'''
22654 <p><b><small></small></b></p>
22655 <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/300px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="34" width="300"/></a></figure>
22659 #### ----------------------------------------------------------------
22660 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
22661 #### tags. Parsoid's output for these tags differs from that of the
22663 #### ----------------------------------------------------------------
22666 Ref: 1. ref-location should be replaced with an index span
22669 B <ref name="x">foo</ref>
22673 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
22674 B <span about="#mwt4" class="mw-ref" id="cite_ref-x_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-2"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-2"><span class="mw-reflink-text">[2]</span></a></span>
22675 C <span about="#mwt6" class="mw-ref" id="cite_ref-y_3-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"y"}}'><a href="./Main_Page#cite_note-y-3"><span class="mw-reflink-text">[3]</span></a></span></p>
22676 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
22677 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
22678 <li about="#cite_note-x-2" id="cite_note-x-2"><a href="./Main_Page#cite_ref-x_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-x-2" class="mw-reference-text">foo</span></li>
22679 <li about="#cite_note-y-3" id="cite_note-y-3"><a href="./Main_Page#cite_ref-y_3-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-y-3" class="mw-reference-text"></span></li>
22684 Ref: 2. ref-tags with identical names should all get the same index
22686 A <ref name="x">foo</ref>
22690 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-x_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-1"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span>
22691 B <span about="#mwt4" class="mw-ref" id="cite_ref-x_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22692 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
22693 <li about="#cite_note-x-1" id="cite_note-x-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-x_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-x_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-x-1" class="mw-reference-text">foo</span></li>
22698 Ref: 3. spaces in ref-names should be ignored
22700 A <ref name="x">foo</ref>
22701 B <ref name=" x " />
22705 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-x_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-1"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span>
22706 B <span about="#mwt4" class="mw-ref" id="cite_ref-x_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span>
22707 C <span about="#mwt6" class="mw-ref" id="cite_ref-x_1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22708 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
22709 <li about="#cite_note-x-1" id="cite_note-x-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-x_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-x_1-1"><span class="mw-linkback-text">2 </span></a><a href="./Main_Page#cite_ref-x_1-2"><span class="mw-linkback-text">3 </span></a></span> <span id="mw-reference-text-cite_note-x-1" class="mw-reference-text">foo</span></li>
22713 # NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
22715 Ref: 4. 'constructor' should be accepted as a valid ref-name
22717 A <ref name="constructor">foo</ref>
22720 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-constructor_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-constructor-1"},"attrs":{"name":"constructor"}}'><a href="./Main_Page#cite_note-constructor-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22721 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22722 <li about="#cite_note-constructor-1" id="cite_note-constructor-1"><a href="./Main_Page#cite_ref-constructor_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-constructor-1" class="mw-reference-text">foo</span></li>
22727 Ref: 5. body should accept generic wikitext
22730 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
22735 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22737 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
22738 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">This is a <b><a rel="mw:WikiLink" href="Bolded_link" title="Bolded link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
22744 Ref: 6. indent-pres should not be output in ref-body
22754 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22756 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22757 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo
22765 Ref: 7. No p-wrapping in ref-body
22782 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22784 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22785 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo
22800 Ref: 8. transclusion wikitext has lower precedence
22802 A <ref> foo {{echo|</ref> B C}}
22806 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B C}}</p>
22807 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22808 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo {{echo|</span></li>
22813 Ref: 9. unclosed comments should not leak out of ref-body
22815 A <ref> foo <!--</ref> B C
22818 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B C</p>
22819 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22820 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo <!----></span></li>
22825 Ref: 10. Unclosed HTML tags should not leak out of ref-body
22827 A <ref> <b> foo </ref> B C
22831 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B C</p>
22834 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22835 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text"><b data-parsoid='{"stx":"html","autoInsertedEnd":true}'> foo </b></span></li>
22840 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
22846 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B
22847 C <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></span> D</p>
22848 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
22849 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
22850 <li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
22855 Ref: 12. ref-tags act as trailing newline migration barrier
22857 <!--the newline at the end of this line moves out of the p tag-->a
22859 b<!--the newline at the end of this line stays inside the p tag--> <ref />
22865 <!--the newline at the end of this line moves out of the p tag--><p>a</p>
22868 <p>b<!--the newline at the end of this line stays inside the p tag--> <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
22869 <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></span></p>
22872 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
22873 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text"></span></li>
22874 <li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text"></span></li></ol>
22878 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
22885 <p><span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> A
22886 <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></span> B</p>
22887 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
22888 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
22889 <li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar
22894 ## Roundtripping fails because of nowiki'ing
22896 Ref: 14. A nested ref-tag should be emitted as plain text
22900 <ref>foo <ref>bar</ref> baz</ref>
22904 <p><span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span> baz</ref></p>
22906 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo <ref>bar</span></li></ol>
22910 Ref: 15. ref-tags with identical names should get identical indexes
22912 A1 <ref name="a">foo</ref> A2 <ref name="a" />
22913 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
22917 <p>A1 <span about="#mwt3" class="mw-ref" id="cite_ref-a_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a-1"},"attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></span> A2 <span about="#mwt4" class="mw-ref" id="cite_ref-a_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></span>
22918 B1 <span about="#mwt7" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></span> B2 <span about="#mwt8" class="mw-ref" id="cite_ref-b_2-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-b-2"},"attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></span></p>
22920 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-a_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-a_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-a-1" class="mw-reference-text">foo</span></li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-b_2-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-b_2-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">bar</span></li>
22924 ## We don't bother wt2wt-ing non-standard whitespace
22926 Ref: 16. Tokenizer should accept non-standard whitespace in <ref> and </ref> tags
22934 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22935 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22936 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li></ol>
22940 Ref: 17. Generate valid HTML5 id/about attributes
22942 <ref name="a b">foo</ref>
22943 <ref name=":0">ve-created name</ref>
22947 <p><span about="#mwt2" class="mw-ref" id="cite_ref-a_b_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a_b-1"},"attrs":{"name":"a b"}}'><a href="./Main_Page#cite_note-a_b-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span>
22948 <span about="#mwt4" class="mw-ref" id="cite_ref-:0_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-:0-2"},"attrs":{"name":":0"}}'><a href="./Main_Page#cite_note-:0-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></span>
22950 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a_b-1" id="cite_note-a_b-1"><a href="./Main_Page#cite_ref-a_b_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-a_b-1" class="mw-reference-text">foo</span></li><li about="#cite_note-:0-2" id="cite_note-:0-2"><a href="./Main_Page#cite_ref-:0_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-:0-2" class="mw-reference-text">ve-created name</span></li></ol>
22955 Ref: 18. T58916: Extension attributes should be parsed as plain text
22957 <ref name="{{echo|a}}">foo</ref>
22961 <p><span class="mw-ref" id="cite_ref-.7B.7Becho.7Ca.7D.7D_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-.7B.7Becho.7Ca.7D.7D-1"},"attrs":{"name":"{{echo|a}}"}}'><a href="./Main_Page#cite_note-.7B.7Becho.7Ca.7D.7D-1"><span class="mw-reflink-text">[1]</span></a></span>
22964 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
22965 <li about="#cite_note-.7B.7Becho.7Ca.7D.7D-1" id="cite_note-.7B.7Becho.7Ca.7D.7D-1"><a href="./Main_Page#cite_ref-.7B.7Becho.7Ca.7D.7D_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-.7B.7Becho.7Ca.7D.7D-1" class="mw-reference-text">foo</span></li>
22970 Ref: 19. ref-tags with identical name encodings should get identical indexes
22972 1 <ref name="a & b">foo</ref> 2 <ref name="a & b" />
22976 <p>1 <span about="#mwt3" class="mw-ref" id="cite_ref-a_.26_b_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a_.26_b-1"},"attrs":{"name":"a & b"}}'><a href="./Main_Page#cite_note-a_.26_b-1"><span class="mw-reflink-text">[1]</span></a></span> 2 <span about="#mwt4" class="mw-ref" id="cite_ref-a_.26_b_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a &amp; b"}}'><a href="./Main_Page#cite_note-a_.26_b-1"><span class="mw-reflink-text">[1]</span></a></span>
22978 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
22979 <li about="#cite_note-a_.26_b-1" id="cite_note-a_.26_b-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-a_.26_b_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-a_.26_b_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-a_.26_b-1" class="mw-reference-text">foo</span></li>
22984 Ref: 20. ref-tags with identical names but different content should keep it
22986 A <ref name="foo">Foo one</ref>
22987 B <ref name="foo">Foo two</ref>
22988 C <ref name="foo" />
22992 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-foo_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-foo-1"},"attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></span>
22993 B <span about="#mwt4" class="mw-ref" id="cite_ref-foo_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"Foo two"},"attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></span>
22994 C <span about="#mwt6" class="mw-ref" id="cite_ref-foo_1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></span></p>
22996 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-foo-1" id="cite_note-foo-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-foo_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-foo_1-1"><span class="mw-linkback-text">2 </span></a><a href="./Main_Page#cite_ref-foo_1-2"><span class="mw-linkback-text">3 </span></a></span> <span id="mw-reference-text-cite_note-foo-1" class="mw-reference-text">Foo one</span></li>
23001 References: 1. references tag without any refs should be handled properly
23005 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
23009 References: 2. references tag with group only outputs references from that group
23011 A <ref group="a">foo</ref>
23012 B <ref group="b">bar</ref>
23015 <references group="a" />
23017 <references group="b" />
23019 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"a"}}'><a href="./Main_Page#cite_note-1" data-mw-group="a"><span class="mw-reflink-text">[a 1]</span></a></span>
23020 B <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{"group":"b"}}'><a href="./Main_Page#cite_note-2" data-mw-group="b"><span class="mw-reflink-text">[b 1]</span></a></span>
23021 C <span class="mw-ref" id="cite_ref-3" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-3"},"attrs":{}}'><a href="./Main_Page#cite_note-3"><span class="mw-reflink-text">[1]</span></a></span></p>
23023 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw-group="a" data-mw='{"name":"references","attrs":{"group":"a"}}'>
23024 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" data-mw-group="a" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
23026 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'>
23027 <li about="#cite_note-3" id="cite_note-3"><a href="./Main_Page#cite_ref-3" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-3" class="mw-reference-text">baz</span></li>
23029 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt12" data-mw-group="b" data-mw='{"name":"references","attrs":{"group":"b"}}'>
23030 <li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" data-mw-group="b" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
23035 References: 3. ref list should be cleared after processing references
23045 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
23047 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
23050 <p>B <span about="#mwt6" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[1]</span></a></span></p>
23052 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
23053 <li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
23058 References: 4. only referenced group should be cleared after processing references
23060 A <ref group="a">afoo</ref>
23063 <references group="a" />
23069 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"a"}}'><a href="./Main_Page#cite_note-1" data-mw-group="a"><span class="mw-reflink-text">[a 1]</span></a></span>
23070 B <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[1]</span></a></span></p>
23072 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw-group="a" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" data-mw-group="a" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">afoo</span></li>
23075 <p>C <span about="#mwt8" class="mw-ref" id="cite_ref-3" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-3"},"attrs":{}}'><a href="./Main_Page#cite_note-3"><span class="mw-reflink-text">[2]</span></a></span></p>
23077 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bfoo</span></li><li about="#cite_note-3" id="cite_note-3"><a href="./Main_Page#cite_ref-3" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-3" class="mw-reference-text">cfoo</span></li>
23081 ## Don't expect this to rt since we're dropping content
23083 References: 5. ref tags in references should be processed while ignoring all other content
23085 parsoid=wt2html,html2html
23088 B <ref name="b">bar</ref>
23091 <ref name="a">foo</ref>
23092 This should just get lost.
23095 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-a_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></span>
23096 B <span about="#mwt4" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-b-2"},"attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></span></p>
23099 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{},"body":{"html":"\n<span about=\"#mwt8\" class=\"mw-ref\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid='{\"dsr\":[59,82,14,6]}' data-mw='{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-a-1\"},\"attrs\":{\"name\":\"a\"}}'><a href=\"./Main_Page#cite_note-a-1\" style=\"counter-reset: mw-Ref 1;\" data-parsoid=\"{}\"><span class=\"mw-reflink-text\" data-parsoid=\"{}\">[1]</span></a></span>\n"}}'><li about="#cite_note-a-1" id="cite_note-a-1"><a href="./Main_Page#cite_ref-a_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-a-1" class="mw-reference-text">foo</span></li><li about="#cite_note-b-2" id="cite_note-b-2"><a href="./Main_Page#cite_ref-b_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">bar</span></li>
23104 References: 6. <references /> from a transclusion
23106 <ref>Foo</ref> {{echo|<references />}}
23108 <p><span about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p> <ol class="mw-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"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">Foo</span></li>
23113 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
23115 A <ref>foo bar for a</ref>
23116 B <ref group="X" name="b" />
23120 <references group="X">
23121 <ref name="b">foo</ref>
23124 <p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
23125 B <span about="#mwt4" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}'><a href="./Main_Page#cite_note-b-2" data-mw-group="X"><span class="mw-reflink-text">[X 1]</span></a></span>
23128 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
23129 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo bar for a</span></li>
23132 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw-group="X" data-mw='{"name":"references","attrs":{"group":"X"},"body":{"html":"\n<span about=\"#mwt10\" class=\"mw-ref\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid='{\"dsr\":[96,119,14,6]}' data-mw='{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-b-2\"},\"attrs\":{\"name\":\"b\"}}'><a href=\"./Main_Page#cite_note-b-2\" style=\"counter-reset: mw-Ref 1;\" data-mw-group=\"X\" data-parsoid=\"{}\"><span class=\"mw-reflink-text\" data-parsoid=\"{}\">[X 1]</span></a></span>\n"}}'>
23133 <li about="#cite_note-b-2" id="cite_note-b-2"><a href="./Main_Page#cite_ref-b_2-0" data-mw-group="X" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">foo</span></li>
23138 References: 8. T88019: Remove <meta>s from templates inside <ref> that's itself inside a template
23140 X{{echo|<ref>foo {{echo|<b>bar</b>}} and {{echo|baz}} boo</ref>}}
23143 <p>X<span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<ref>foo {{echo|<b>bar</b>}} and {{echo|baz}} boo</ref>"}},"i":0}}]}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
23144 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt7" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo <b data-parsoid='{"stx":"html"}'>bar</b> and baz boo</span></li>
23148 # This test only works in wt2html now as the <references /> are always generated
23149 # unless selser is active. Once T72722 is fixed, we should add a changes test
23150 # here to ensure that unrelated changes don't add the new <references />
23151 # when selser is active.
23153 References: 9. Generate missing references list at the end
23156 B <ref group="inexistent">bar</ref>
23158 <p>A <span class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B <span class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{"group":"inexistent"}}'><a href="./Main_Page#cite_note-2" data-mw-group="inexistent"><span class="mw-reflink-text">[inexistent 1]</span></a></span></p>
23159 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'>
23160 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
23162 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw-group="inexistent" data-mw='{"name":"references","attrs":{"group":"inexistent"},"autoGenerated":true}'>
23163 <li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" data-mw-group="inexistent" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
23168 References: 10. New <references/> shouldn't be added for unrelated edits.
23171 "modes": ["selser"],
23172 "changes": [["#x", "remove"]],
23176 Unrelated text<span id="x"> that's going to disappear</span>.
23184 Entities in ref name
23186 <ref name="test & me">hi</ref>
23189 <p><span about="#mwt2" class="mw-ref" id="cite_ref-test_.26_me_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-test_.26_me-1"},"attrs":{"name":"test &amp; me"}}'><a href="./Main_Page#cite_note-test_.26_me-1"><span class="mw-reflink-text">[1]</span></a></span></p>
23190 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
23191 <li about="#cite_note-test_.26_me-1" id="cite_note-test_.26_me-1"><a href="./Main_Page#cite_ref-test_.26_me_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-test_.26_me-1" class="mw-reference-text">hi</span></li>
23195 ## The output here may look funny, but it's what the php parser will do. The
23196 ## unclosed references tag becomes escaped text, and then a new references
23197 ## tag is auto-generated. The test is wt2html only because it roundtrips with
23198 ## nowiki tags, and the auto-generated references tag is only dropped in
23201 Generate references for unclosed references tag
23209 <p>a<span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></p>
23211 <p><references></p>
23212 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li></ol>
23216 New reference serializes on its own line
23218 parsoid=wt2wt,html2wt
23223 foo<ol class="mw-references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
23226 #### ----------------------------------------------------------------
23227 #### Parsoid-only testing of Parsoid's impl of LST
23228 #### Not implemented yet, see
23229 #### https://www.mediawiki.org/wiki/Parsoid/HTML_based_LST
23230 #### ----------------------------------------------------------------
23232 ## We still need to support serializing the older format while content is stored.
23234 LST Sections: Backwards compatibility
23237 "suppressErrors": true,
23238 "modes": ["html2wt"]
23241 <section begin="2011-05-16" />
23242 <section end="2014-04-10 (MW 1.23wmf22)" />
23244 <p><meta typeof="mw:Extension/LabeledSectionTransclusion/begin" content="2011-05-16"/>
23245 <meta typeof="mw:Extension/LabeledSectionTransclusion/end" content="2014-04-10 (MW 1.23wmf22)"/></p>
23248 ## The unconventional output is the result of `usePHPPreProcessor` being
23249 ## disabled in parserTests.js. This test is mainly just to show <section> is
23250 ## recognized as an extension tag w/o a native handler.
23252 LST Sections: Newfangled approach
23254 parsoid={ "suppressErrors": true }
23256 <section begin="2011-05-16" />
23257 <section end="2014-04-10 (MW 1.23wmf22)" />
23259 <p><span typeof="mw:Extension/section" about="#mwt1" data-parsoid='{"stx":"html","selfClose":true,"src":"<section begin=\"2011-05-16\" />","tagWidths":[30,0]}'><section begin="2011-05-16" /></span>
23260 <span typeof="mw:Extension/section" about="#mwt2" data-parsoid='{"stx":"html","selfClose":true,"src":"<section end=\"2014-04-10 (MW 1.23wmf22)\" />","tagWidths":[43,0]}'><section end="2014-04-10 (MW 1.23wmf22)" /></span></p>
23263 #--------- Test stripping of empty nodes in template content ----------
23265 Empty LI and TR nodes should be stripped from template content
23270 <ul about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyLITest","href":"./Template:EmptyLITest"},"params":{},"i":0}}]}'>
23274 <table about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyTRTest","href":"./Template:EmptyTRTest"},"params":{},"i":0}}]}'>
23287 Empty LI and TR nodes should not be stripped from top-level content
23314 Empty TR nodes should not be stripped if they have any attributes set
23316 {{EmptyTRWithHTMLAttrTest}}
23318 <table about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"EmptyTRWithHTMLAttrTest","href":"./Template:EmptyTRWithHTMLAttrTest"},"params":{},"i":0}}]}'>
23319 <tr align="center"></tr>
23320 <tr><td>foo</td></tr>
23321 <tr align="center"></tr>
23322 <tr><td>bar</td></tr>
23326 #### ----------------------------------------------------------------
23327 #### The following section of tests are primarily to test
23328 #### wikitext escaping capabilities of Parsoid. Given that
23329 #### escaping can be done any number of ways, the wikitext (input)
23330 #### is always adjusted to reflect how Parsoid adds nowiki
23333 #### We are marking several tests as parsoid-only since the
23334 #### HTML in the result section is different from what the
23335 #### PHP parser generates for it.
23336 #### ----------------------------------------------------------------
23339 #### --------------- Headings ---------------
23341 #### 1. Nested inside html <h1>=foo=</h1>
23342 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
23343 #### 3. Nested inside html with wikitext split by html tags
23344 #### 4. No escape needed
23345 #### 5. Empty headings <h1></h1>
23346 #### 6. Heading chars in SOL context
23347 #### ----------------------------------------
23349 Headings: 0. Unnested
23359 <p>=foo<i>a</i>=</p>
23361 <nowiki>=foo=</nowiki>
23363 <nowiki> </nowiki>=foo=
23365 <nowiki>=foo=</nowiki>
23367 =foo''a''<nowiki>=</nowiki>
23370 # New headings and existing headings are handled differently
23372 Headings: 1. Nested inside html
23380 <h1 data-parsoid=''>=foo=</h1>
23381 <h2 data-parsoid=''>=foo=</h2>
23382 <h3 data-parsoid=''>=foo=</h3>
23383 <h4 data-parsoid=''>=foo=</h4>
23384 <h5 data-parsoid=''>=foo=</h5>
23385 <h6 data-parsoid=''>=foo=</h6>
23393 =<nowiki>=foo=</nowiki>=
23394 ==<nowiki>=foo=</nowiki>==
23395 ===<nowiki>=foo=</nowiki>===
23396 ====<nowiki>=foo=</nowiki>====
23397 =====<nowiki>=foo=</nowiki>=====
23398 ======<nowiki>=foo=</nowiki>======
23403 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
23412 <nowiki>*</nowiki>bar
23418 <nowiki>=bar=</nowiki>
23422 Headings: 3. Nested inside html with wikitext split by html tags
23426 <h1>=<b>bold</b>foo=</h1>
23428 = ='''bold'''foo= =
23432 Headings: 4a. No escaping needed (testing just h1 and h2)
23443 <h1><i>=</i>foo=</h1>
23463 Headings: 4b. No escaping needed (inside p-tags)
23478 Headings: 5. Empty headings
23482 <h1 data-parsoid='{}'></h1>
23484 <h2 data-parsoid='{}'></h2>
23486 <h3 data-parsoid='{}'></h3>
23488 <h4 data-parsoid='{}'></h4>
23490 <h5 data-parsoid='{}'></h5>
23492 <h6 data-parsoid='{}'></h6>
23502 =====<nowiki/>=====
23504 ======<nowiki/>======
23508 Headings: 6a. Heading chars in SOL context (with trailing spaces)
23518 <nowiki>=a=</nowiki>
23520 <nowiki>=a=</nowiki>
23522 <nowiki>=a=</nowiki>
23526 Headings: 6b. Heading chars in SOL context (with trailing newlines)
23539 <nowiki>=a=</nowiki>
23542 <nowiki>=a=</nowiki>
23545 <nowiki>=a=</nowiki>
23550 Headings: 6c. Heading chars in SOL context (leading newline break)
23558 <nowiki>=b=</nowiki>
23562 Headings: 6d. Heading chars in SOL context (with interspersed comments)
23566 <!--c0--><p>=a=</p>
23568 <!--c1--><p>=a=</p> <!--c2--> <!--c3-->
23570 <!--c0--><nowiki>=a=</nowiki>
23572 <!--c1--><nowiki>=a=</nowiki> <!--c2--> <!--c3-->
23576 Headings: 6d. Heading chars in SOL context (No escaping needed)
23586 Headings: 7. Insert a newline between new content and headings
23592 <h2 data-parsoid='{}'>A</h2>
23593 <p data-parsoid='{}'>a</p>
23603 #### --------------- Lists ---------------
23604 #### 0. Outside nests (*foo, etc.)
23605 #### 1. Nested inside html <ul><li>*foo</li></ul>
23606 #### 2. Inside definition lists
23607 #### 3. Only bullets at start should be escaped
23608 #### 4. No escapes needed
23609 #### 5. No unnecessary escapes
23610 #### 6. Escape bullets in SOL position
23611 #### 7. Escape bullets in a multi-line context
23612 #### ----------------------------------------
23615 Lists: 0. Outside nests
23625 <nowiki>*</nowiki>foo
23627 <nowiki>#</nowiki>foo
23629 <nowiki>;</nowiki>Foo<nowiki>:</nowiki>bar
23632 ## Making these next 3 tests Parsoid-only since they are html2wt tests
23633 ## to test wikitext escaping, and insignificant whitespace diffs
23634 ## cause PHP parser tests to barf
23636 Lists: 1. Nested inside html (No unnecessary escapes)
23645 <li data-parsoid='{}'>*foo</li>
23646 <li data-parsoid='{}'>#foo</li>
23647 <li data-parsoid='{}'>:foo</li>
23648 <li data-parsoid='{}'>;foo</li>
23656 <li data-parsoid='{}'>*foo</li>
23657 <li data-parsoid='{}'>#foo</li>
23658 <li data-parsoid='{}'>:foo</li>
23659 <li data-parsoid='{}'>;foo</li>
23666 *<nowiki>*foo</nowiki>
23667 *<nowiki>#foo</nowiki>
23668 *<nowiki>:foo</nowiki>
23669 *<nowiki>;foo</nowiki>
23675 #<nowiki>*foo</nowiki>
23676 #<nowiki>#foo</nowiki>
23677 #<nowiki>:foo</nowiki>
23678 #<nowiki>;foo</nowiki>
23682 Lists: 2. Inside definition lists
23686 <dl><dt>;foo</dt></dl>
23687 <dl><dt>:foo</dt></dl>
23690 <dl><dd>:foo</dd></dl>
23694 ; <nowiki>:foo</nowiki>
23696 ; <nowiki>:foo</nowiki>
23703 Lists: 3. Only bullets at start of text in wikitext-generated HTML should be escaped
23709 <li data-parsoid='{}'>*foo<i>it</i>*bar</li>
23713 *<nowiki>*foo</nowiki>''it''*bar
23717 Lists: 4. No escapes needed
23730 <li><a rel="mw:WikiLink" href="Foo" title="Foo">Foo</a>: bar
23734 <li><a rel="mw:WikiLink" href="Foo" title="Foo">Foo</a>*bar
23748 Lists: 5. No unnecessary escapes
23752 <ul><li> bar <span>[[foo]]</span></li></ul>
23753 <ul><li> =bar <span>[[foo]]</span></li></ul>
23754 <ul><li> [[bar <span>[[foo]]</span></li></ul>
23755 <ul><li> ]]bar <span>[[foo]]</span></li></ul>
23756 <ul><li> =bar <span>foo]]</span>=</li></ul>
23757 <ul><li> <s></s>: a</li></ul>
23758 <ul><li> <i>* foo</i></li></ul>
23761 * bar <span><nowiki>[[foo]]</nowiki></span>
23763 * =bar <span><nowiki>[[foo]]</nowiki></span>
23765 * [[bar <span><nowiki>[[foo]]</nowiki></span>
23767 * ]]bar <span><nowiki>[[foo]]</nowiki></span>
23769 * =bar <span>foo]]</span>=
23777 Lists: 6. Escape bullets in SOL position
23781 <p><!--cmt-->*foo</p>
23783 <!--cmt--><nowiki>*</nowiki>foo
23787 Lists: 7. Escape bullets in a multi-line context
23796 <nowiki>*</nowiki>b
23800 Lists: 8. Escape colons only if not present in tags
23804 <dl><dt>a:b<i>c:d</i></dt></dl>
23806 ; <nowiki>a:b</nowiki>''c:d''
23809 #### --------------- HRs ---------------
23810 #### 1. Single line
23811 #### -----------------------------------
23814 HRs: 1. Single line
23822 ----<nowiki>----</nowiki>
23827 #### --------------- Tables ---------------
23828 #### 1a. Simple example
23829 #### 1b. No escaping needed (!foo)
23830 #### 1c. No escaping needed (|foo)
23831 #### 1d. No escaping needed (|}foo)
23833 #### 2a. Nested in td (<td>foo|bar</td>)
23834 #### 2b. Nested in td (<td>foo||bar</td>)
23835 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
23837 #### 3a. Nested in th (<th>foo!bar</th>)
23838 #### 3b. Nested in th (<th>foo!!bar</th>)
23839 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
23843 #### 4c. No escaping needed
23844 #### --------------------------------------
23847 Tables: 1a. Simple example
23855 <nowiki>{|</nowiki>
23860 Tables: 1b. No escaping needed
23871 Tables: 1c. No escaping needed
23882 Tables: 1d. No escaping needed
23893 Tables: 2a. Nested in td
23898 <td>foo|bar</td></tr>
23899 <tr><td>x<div>a|b</div></td>
23903 |<nowiki>foo|bar</nowiki>
23905 |x<div><nowiki>a|b</nowiki></div>
23921 Tables: 2b. Nested in td
23927 <td>a<i>b||c</i></td>
23928 <td>a<i><div>b||c</div></i></td>
23929 </tr></tbody></table>
23932 |<nowiki>foo||bar</nowiki>
23933 |a''<nowiki>b||c</nowiki>''
23934 |a''<div><nowiki>b||c</nowiki></div>''
23943 <td>a<i><div>b||c</div></i>
23949 Tables: 2c. Nested in td -- no escaping needed
23965 Tables: 3a. Nested in th
23981 Tables: 3b. Nested in th
23986 <tr><th>foo!!bar</th>
23987 <th><i>foo|bar</i></th>
23988 <th><i>foo!!bar</i></th>
23989 <th><i><span>foo!!bar</span></i></th>
23990 </tr></tbody></table>
23993 !<nowiki>foo!!bar</nowiki>
23994 !''<nowiki>foo|bar</nowiki>''
23995 !''<nowiki>foo!!bar</nowiki>''
23996 !''<span><nowiki>foo!!bar</nowiki></span>''
24005 <th><i>foo!!bar</i>
24007 <th><i><span>foo!!bar</span></i>
24013 Tables: 3c. Nested in th
24018 <tr><th>foo||bar</th>
24019 <th><span typeof="mw:Nowiki">foo||bar</span></th>
24020 </tr></tbody></table>
24023 !<nowiki>foo||bar</nowiki>
24024 !<nowiki>foo||bar</nowiki>
24037 Tables: 4a. Escape -
24053 |<nowiki>-bar</nowiki>
24058 Tables: 4b. Escape +
24074 |<nowiki>+bar</nowiki>
24079 Tables: 4c. No escaping needed
24084 <tr><td>foo-bar</td><td>foo+bar</td></tr>
24085 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
24091 <div>a|b</div></td>
24136 Tables: 4d. No escaping needed
24141 <tbody><tr><td><a rel="mw:WikiLink" href="./Foo" title="Foo">Foo</a>-bar</td>
24142 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>+1</td>
24143 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>-2</td></tr>
24154 <td><a href="/wiki/Foo" title="Foo">Foo</a>-bar
24164 T97430: Don't emit empty nowiki pairs around marker meta tags
24168 <p>*This is a long sentence here that will make the nowiki algo split up the nowikis into multiple pairs
24169 |** Make this another long long long sentence forcing the nowiki algo to split up the nowikis.</p>
24171 <nowiki>*</nowiki>This is a long sentence here that will make the nowiki algo split up the nowikis into multiple pairs
24172 |** Make this another long long long sentence forcing the nowiki algo to split up the nowikis.
24176 Unclosed xmlish element in table line shouldn't eat end delimiters
24181 <tbody><tr><td> <foo</td>
24182 <td> bar></td></tr>
24199 #### --------------- Links ----------------
24200 #### 1. Quote marks in link text
24201 #### 2. Wikilinks: Escapes needed
24202 #### 3. Wikilinks: No escapes needed
24203 #### 4. Extlinks: Escapes needed
24204 #### 5. Extlinks: No escapes needed
24205 #### --------------------------------------
24207 Links 1. WikiLinks: No escapes needed
24211 <p><a rel="mw:WikiLink" href="Foo" title="Foo">Foo<i>boo</i></a>
24212 <a rel="mw:WikiLink" href="Foo" title="Foo">[Foobar]</a>
24213 <a rel="mw:WikiLink" href="Foo" title="Foo">x [Foobar] x</a></p>
24217 [[Foo|x [Foobar] x]]
24219 <p><a href="/wiki/Foo" title="Foo">Foo<i>boo</i></a>
24220 <a href="/wiki/Foo" title="Foo">[Foobar]</a>
24221 <a href="/wiki/Foo" title="Foo">x [Foobar] x</a>
24226 Links 2. WikiLinks: Escapes needed
24230 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
24231 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
24232 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
24233 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
24234 <a href="Foo" rel="mw:WikiLink">|Bar</a>
24235 <a href="Foo" rel="mw:WikiLink">]]bar</a>
24236 <a href="Foo" rel="mw:WikiLink">[[bar</a>
24237 <a href="Foo" rel="mw:WikiLink">x [[ y</a>
24238 <a href="Foo" rel="mw:WikiLink">x ]] y</a>
24239 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
24241 [[Foo|<nowiki>Foobar]</nowiki>]]
24242 [[Foo|x <nowiki>[http://google.com g]</nowiki> x]]
24243 [[Foo|<nowiki>[[Bar]]</nowiki>]]
24244 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
24245 [[Foo|<nowiki>|Bar</nowiki>]]
24246 [[Foo|<nowiki>]]bar</nowiki>]]
24247 [[Foo|<nowiki>[[bar</nowiki>]]
24248 [[Foo|<nowiki>x [[ y</nowiki>]]
24249 [[Foo|<nowiki>x ]] y</nowiki>]]
24250 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
24252 <p><a href="/wiki/Foo" title="Foo">Foobar]</a>
24253 <a href="/wiki/Foo" title="Foo">x [http://google.com g] x</a>
24254 <a href="/wiki/Foo" title="Foo">[[Bar]]</a>
24255 <a href="/wiki/Foo" title="Foo">x [[Bar]] x</a>
24256 <a href="/wiki/Foo" title="Foo">|Bar</a>
24257 <a href="/wiki/Foo" title="Foo">]]bar</a>
24258 <a href="/wiki/Foo" title="Foo">[[bar</a>
24259 <a href="/wiki/Foo" title="Foo">x [[ y</a>
24260 <a href="/wiki/Foo" title="Foo">x ]] y</a>
24261 <a href="/wiki/Foo" title="Foo">x ]] y [[ z</a>
24266 Links 3. WikiLinks: No escapes needed
24270 <p><a rel="mw:WikiLink" href="Foo">[Foobar</a>
24271 <a rel="mw:WikiLink" href="Foo" title="Foo">foo|bar</a></p>
24276 <p><a href="/wiki/Foo" title="Foo">[Foobar</a>
24277 <a href="/wiki/Foo" title="Foo">foo|bar</a>
24282 Links 4. ExtLinks: Escapes needed
24286 <p><a rel="mw:ExtLink" href="http://google.com">[google]</a>
24287 <a rel="mw:ExtLink" href="http://google.com">google]</a></p>
24288 <p>[http://google.com]</p>
24289 <p>[http://google.com google]</p>
24290 <p>[<a rel="mw:ExtLink" href="http://google.com">http://google.com</a>]</p>
24291 <p>[<a rel="mw:ExtLink" href="http://google.com" about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://google.com"}},"i":0}}]}'>http://google.com</a>]</p>
24293 [http://google.com <nowiki>[google]</nowiki>]
24294 [http://google.com <nowiki>google]</nowiki>]
24296 <nowiki>[http://google.com]</nowiki>
24298 <nowiki>[http://google.com google]</nowiki>
24300 [http://google.com<nowiki>]</nowiki>
24302 [{{echo|http://google.com}}<nowiki>]</nowiki>
24304 <p><a rel="nofollow" class="external text" href="http://google.com">[google]</a>
24305 <a rel="nofollow" class="external text" href="http://google.com">google]</a>
24306 </p><p>[http://google.com]
24307 </p><p>[http://google.com google]
24308 </p><p>[<a rel="nofollow" class="external free" href="http://google.com">http://google.com</a>]
24309 </p><p>[<a rel="nofollow" class="external free" href="http://google.com">http://google.com</a>]
24314 Links 5. ExtLinks: No escapes needed
24318 <p><a rel="mw:ExtLink" href="http://google.com">[google</a></p>
24319 <p>[<a ref="mw:ExtLink" href="http://google.com"></a>]</p>
24321 [http://google.com [google]
24323 [[http://google.com]]
24325 <p><a rel="nofollow" class="external text" href="http://google.com">[google</a>
24326 </p><p>[<a rel="nofollow" class="external autonumber" href="http://google.com">[1]</a>]
24331 Links 6. Add <nowiki/>s between text-nodes and url-links when required (bug 64300)
24335 <p>x<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>y
24336 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>?x
24337 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>&x
24338 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>'x
24339 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,x
24340 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.x
24341 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
24342 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>:x
24343 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>;x
24344 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>!x
24345 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>=x
24346 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>(x)
24347 <a rel="mw:ExtLink" href="http://example.com(x" data-parsoid='{"stx":"url"}'>http://example.com(x</a>)
24350 x<nowiki/>http://example.com<nowiki/>y
24351 http://example.com<nowiki/>?x
24352 http://example.com<nowiki/>&x
24353 http://example.com<nowiki/>'x
24354 http://example.com<nowiki/>,x
24355 http://example.com<nowiki/>.x
24356 http://example.com<nowiki/>;x
24357 http://example.com<nowiki/>:x
24358 http://example.com<nowiki/>;x
24359 http://example.com<nowiki/>!x
24360 http://example.com<nowiki/>=x
24361 http://example.com<nowiki/>(x)
24362 http://example.com(x<nowiki/>)
24366 Links 7a. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
24371 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>
24373 "<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>"
24374 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>)
24375 (<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>) foo
24376 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>,
24377 <a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>, foo
24383 "http://example.com"
24384 (http://example.com)
24385 (http://example.com) foo
24386 http://example.com,
24387 http://example.com, foo
24390 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
24392 "<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>"
24393 (<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
24394 (<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>) foo
24395 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>,
24396 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>, foo
24401 Links 7b. Don't add spurious <nowiki/>s between text-nodes and url-links (bug 64300)
24405 <p><a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url"}'>http://example.com</a>.,;:!?\
24406 -<a rel="mw:ExtLink" href="http://example.com">http://example.com</a>:</p>
24408 http://example.com.,;:!?\
24409 -http://example.com:
24411 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>.,;:!?\
24412 -<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>:
24417 Links 8. Add <nowiki/>s between text-nodes and RFC-links when required (bug 64300)
24421 <p><a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>4
24422 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y
24423 X<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>y</p>
24427 X<nowiki/>RFC 123<nowiki/>y
24431 Links 9. Don't add spurious <nowiki/>s between text-nodes and RFC-links (bug 64300)
24435 <p><a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>?foo
24436 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>&foo
24437 -<a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>RFC 123</a>-
24444 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc123">RFC 123</a>?foo
24445 <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc123">RFC 123</a>&foo
24446 -<a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc123">RFC 123</a>-
24451 Links 10. Add <nowiki/>s between text-nodes and PMID-links when required (bug 64300)
24455 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>4
24456 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
24457 X<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>y
24461 X<nowiki/>PMID 123<nowiki/>y
24465 Links 11. Don't add spurious <nowiki/>s between text-nodes and PMID-links (bug 64300)
24469 <p><a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>?foo
24470 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>&foo
24471 -<a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink" data-parsoid='{"stx":"magiclink"}'>PMID 123</a>-
24478 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract">PMID 123</a>?foo
24479 <a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract">PMID 123</a>&foo
24480 -<a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract">PMID 123</a>-
24485 Links 12. Add <nowiki/>s between text-nodes and ISBN-links when required (bug 64300)
24489 <p><a href="./Special:BookSources/1234567890" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>1
24490 <a href="./Special:BookSources/1234567890" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>x
24491 a<a href="./Special:BookSources/1234567890" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>b
24494 ISBN 1234567890<nowiki/>1
24495 ISBN 1234567890<nowiki/>x
24496 a<nowiki/>ISBN 1234567890<nowiki/>b
24500 Links 13. Don't add spurious <nowiki/>s between text-nodes and ISBN-links (bug 64300)
24504 <p>-<a href="./Special:BookSources/1234567890" rel="mw:WikiLink" data-parsoid='{"stx":"magiclink"}'>ISBN 1234567890</a>'s
24508 <p>-<a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>'s
24513 Links 14. Protect link-like plain text. (Parsoid bug T78425)
24517 <p>this is not a link: http://example.com
24520 this is not a link: <nowiki>http://example.com</nowiki>
24524 Links 15. Link trails can't become link prefixes.
24529 <p><a rel="mw:WikiLink" href="Söfnuður" title="Söfnuður" data-parsoid='{"stx":"simple","tail":"-"}'>Söfnuður-</a><a rel="mw:WikiLink" href="00" title="00">00</a></p>
24531 [[Söfnuður]]-[[00]]
24533 <p><a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">Söfnuður-</a><a href="/wiki/00" title="00">00</a>
24537 #### --------------- Quotes ---------------
24538 #### 1. Quotes inside <b> and <i>
24539 #### 2. Link fragments separated by <i> and <b> tags
24540 #### 3. Link fragments inside <i> and <b>
24541 #### 4. No escaping needed
24542 #### --------------------------------------
24544 1a. Quotes inside <b> and <i>
24555 <b>foo'<i>bar'</i>baz</b>
24564 <i>fools'<span> errand</span></i>
24565 <i><span>fool</span>'s errand</i>
24566 '<i>foo</i> bar '<i>baz</i>
24567 a|!*#-:;+-~[]{}b'<i>x</i>
24571 ''<nowiki>''foo''</nowiki>''
24572 ''<nowiki>'''foo'''</nowiki>''
24574 '''<nowiki/>'foo''''
24575 '''<nowiki>''foo''</nowiki>'''
24576 '''<nowiki>'''foo'''</nowiki>'''
24577 '''foo'<nowiki/>''bar'<nowiki/>''baz'''
24578 '''foo'''<nowiki/>'s
24584 '''foo'''<nowiki/>'
24585 ''''foo'''<nowiki/>'
24586 ''fools'<span> errand</span>''
24587 ''<span>fool</span>'s errand''
24588 '<nowiki/>''foo'' bar '''baz''
24589 a|!*#-:;+-~[]{}b'''x''
24593 1b. Quotes inside <b> and <i> with other tags on same line
24597 '<i>a</i> foo <i><a rel="mw:WikiLink" href="Bar" title="Bar">bar</a></i>
24598 <i>a'</i> foo <i><a rel="mw:WikiLink" href="Bar" title="Bar">bar</a></i>
24599 <i>a'</i> foo <b><a rel="mw:WikiLink" href="Bar" title="Bar" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[bar]]"}},"i":0}}]}'>bar</a></b>
24600 <a rel="mw:WikiLink" href="Foo" title="Foo">foo</a> x'<i><a href="Bar" rel="mw:WikiLink" title="Bar">bar</a></i>
24601 '<i>foo</i> <span class="mw-ref" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
24602 '<i>foo</i> <div title="name">test</div>
24603 '<i>foo</i> and <br data-parsoid='{"stx":"html","noClose":true}'/> bar
24604 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
24605 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-1">↑</a></span> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">test</span></li>
24608 '''a'' foo ''[[bar]]''
24609 ''a''' foo ''[[bar]]''
24610 ''a''' foo '''{{echo|[[bar]]}}'''
24611 [[foo]] x'''[[bar]]''
24612 '''foo'' <ref>test</ref>
24613 '''foo'' <div title="name">test</div>
24614 '''foo'' and <br> bar
24619 2. Link fragments separated by <i> and <b> tags
24623 <p>[[<i>foo</i>hello]]</p>
24624 <p>[[<b>foo</b>hello]]</p>
24626 [[''foo''<nowiki>hello]]</nowiki>
24628 [['''foo'''<nowiki>hello]]</nowiki>
24631 # FIXME: Escaping one or both of [[ and ]] is also acceptable --
24632 # this is one of the shortcomings of this format
24634 3. Link fragments inside <i> and <b>
24638 <p><i>[[foo</i>]]</p>
24639 <p><b>[[foo</b>]]</p>
24641 ''[[foo''<nowiki>]]</nowiki>
24643 '''[[foo'''<nowiki>]]</nowiki>
24647 4. No escaping needed
24651 <p>'<span><i>bar</i></span>'
24652 '<span><b>bar</b></span>'
24656 '<span>''bar''</span>'
24657 '<span>'''bar'''</span>'
24661 #### ----------- Paragraphs ---------------
24662 #### 1. No unnecessary escapes
24663 #### --------------------------------------
24666 1. No unnecessary escapes
24670 <p>bar <span>[[foo]]</span>
24671 </p><p>=bar <span>[[foo]]</span>
24672 </p><p>[[bar <span>[[foo]]</span>
24673 </p><p>]]bar <span>[[foo]]</span>
24674 </p><p>=bar <span>foo]]</span>=
24677 bar <span><nowiki>[[foo]]</nowiki></span>
24679 =bar <span><nowiki>[[foo]]</nowiki></span>
24681 [[bar <span><nowiki>[[foo]]</nowiki></span>
24683 ]]bar <span><nowiki>[[foo]]</nowiki></span>
24685 =bar <span>foo]]</span><nowiki>=</nowiki>
24688 #### ----------------------- PRE --------------------------
24689 #### 1. Leading whitespace in SOL context should be escaped
24690 #### ------------------------------------------------------
24692 1. Leading whitespace in SOL context should be escaped
24715 <nowiki> </nowiki>a
24717 <nowiki> </nowiki> a
24721 <nowiki> </nowiki> a
24723 <nowiki> </nowiki>a
24726 <nowiki> </nowiki>b
24749 2. Leading whitespace in non-indent-pre contexts should not be escaped
24753 <p>foo <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
24754 <ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
24755 <li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text"><i>a</i>
24765 3. Leading whitespace in indent-pre suppressing contexts should not be escaped
24784 4. Leading whitespace in indent-pre suppressing contexts should not be escaped
24788 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
24790 [[File:Foobar.jpg|thumb|caption]]
24794 5. Nowiki escaping should account for indent-pres
24804 T95794: nowiki escaping should account for leading space at start-of-line in an indent-pre block
24817 #### --------------- Behavior Switches --------------------
24820 1. Valid behavior switches should be escaped
24827 <nowiki>__TOC__</nowiki>
24828 ''<nowiki>__TOC__</nowiki>''
24832 2. Invalid behavior switches should not be escaped
24843 # We use indent-pre as an indirect way to test for sol-transparent behavior.
24845 Behavior switches should be SOL-transparent
24849 <meta property="mw:PageProp/toc" />
24851 <!-- this one's bogus -->
24854 <pre data-parsoid='{}'><meta property="mw:PageProp/toc" data-parsoid='{"src":"__TOC__","magicSrc":"__TOC__"}'/> foo</pre>
24856 <meta property="mw:PageProp/toc" data-parsoid='{"src":"__TOC__","magicSrc":"__TOC__"}'/><pre data-parsoid='{}'>bar</pre>
24860 <!-- this one's bogus -->
24869 #### --------------- HTML tags ---------------
24872 #### 3. multi-line html tag
24873 #### 4. extension tags
24874 #### -----------------------------------------
24880 <a href="http://google.com">google</a>
24882 <a href="http://google.com">google</a>
24890 <ul><li> <div>foo</div></li>
24891 <li> <div style="color:red">foo</div></li>
24892 <li> <td></li></ul>
24895 * <nowiki><div>foo</div></nowiki>
24896 * <nowiki><div style="color:red">foo</div></nowiki>
24897 * <nowiki><td></nowiki>
24901 3. multi-line html tag
24920 <p><ref>foo</ref>
24921 </p><p><ref>bar
24922 </p><p>baz</ref>
24925 <nowiki><ref>foo</ref></nowiki>
24927 <nowiki><ref>bar</nowiki>
24929 baz<nowiki></ref></nowiki>
24932 #### --------------- Others ---------------
24938 <p><nowiki>foo</nowiki>
24941 <nowiki>foo</nowiki>
24944 ## The quote-char in the input is necessary for triggering the bug
24946 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
24955 #----------- End of wikitext escaping tests --------------
24959 Tag-like HTML structures are passed through as text
24981 </p><p>1<d e>f
24986 HTML tag with necessary entities in attributes
24988 <span title="&amp;">foo</span>
24990 <p><span title="&amp;">foo</span>
24995 HTML tag with 'unnecessary' entity encoding in attributes
24997 <span title="&">foo</span>
24999 <p><span title="&">foo</span>
25004 HTML tag with broken attribute value quoting
25006 parsoid=wt2html,html2html
25008 <span title="Hello world>Foo</span>
25010 <p><span title="Hello world">Foo</span>
25013 <p><span title="Hello world">Foo</span></p>
25017 Self-closed tag with broken attribute value quoting
25019 parsoid=wt2html,html2html
25021 <div title="Hello world />Foo
25023 <div title="Hello world"></div>
25026 <div title="Hello world " data-parsoid='{"stx":"html","selfClose":true}'></div><p>Foo</p>
25030 Table with broken attribute value quoting
25032 parsoid=wt2html,html2html
25035 | title="Hello world|Foo
25040 <td title="Hello world">Foo
25046 <td title="Hello world">Foo
25052 Table with broken attribute value quoting on consecutive lines
25054 parsoid=wt2html,html2html
25057 | title="Hello world|Foo
25058 | style="color:red|Bar
25063 <td title="Hello world">Foo
25065 <td style="color:red">Bar
25071 <td title="Hello world">Foo
25072 </td><td style="color: red">Bar
25073 </td></tr></tbody></table>
25078 Accept empty td cell attribute
25081 | align="center" | foo || |
25086 <td align="center"> foo </td>
25093 Non-empty attributes in th-cells
25096 ! Foo !! style="color: red" | Bar
25102 <th style="color: red"> Bar
25108 Accept empty attributes in th-cells
25123 Empty table rows go away
25144 ### Parsoid-centric tests for testing RTing of inter-element separators
25145 ### Edge cases not tested by existing parser tests and specific to
25146 ### Parsoid-specific serialization strategies.
25150 RT-ed inter-element separators should be valid separators
25162 <tbody><tr data-parsoid='{"startTagSrc":"|-","a":{"[[foo]]":null},"sa":{"[[foo]]":""},"autoInsertedEnd":true}'></tr>
25166 # Parsoid-only since PHP parser relies on Tidy for correct output
25168 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
25182 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'><small data-parsoid='{"stx":"html","autoInsertedEnd":true}'>foo
25183 <p>bar</p></small></td></tr>
25187 <tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'><small data-parsoid='{"stx":"html","autoInsertedEnd":true}'>foo<small data-parsoid='{"stx":"html","autoInsertedEnd":true}'></small></small></td></tr>
25191 # Note that the "style" attribute is really a template parameter here.
25192 # The = would have to be {{=}} if you wanted the literal.
25194 Empty TD followed by TD with tpl-generated attribute
25199 |{{echo|style='color:red'}}|foo
25213 Indented table with an empty td
25231 ## We have some newline diffs RT-ing this edge case
25232 ## and it is not important enough -- we seem to be emitting
25233 ## at most 2 newlines after a </tr> and this is unrelated to
25234 ## the issue from T85627 that this is testing.
25236 Indented table with blank lines in between (T85627)
25255 Indented block & table
25269 <div data-parsoid='{"stx":"html"}'>foo</div>
25271 <tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"autoInsertedEnd":true}'>foo</td></tr>
25276 Indent and comment before table row
25291 <!--hi--><tbody><tr data-parsoid='{"startTagSrc":"|-","autoInsertedEnd":true}'>
25292 <td data-parsoid='{"autoInsertedEnd":true}'> there</td></tr>
25296 # Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext
25298 Empty TR followed by a template-generated TR
25304 {{echo|<tr><td>foo</td></tr>}}
25310 <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}}]}'>
25315 ## PHP and parsoid output differ for this, and since this is primarily
25316 ## for testing Parsoid's serializer, marking this Parsoid only
25318 Empty TR followed by mixed-ws-comment line should RT correctly
25334 <!--c--> </tr><!--d-->
25340 Multi-line image caption generated by templates with/without trailing newlines
25342 [[File:Foobar.jpg|thumb|300x300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
25343 [[File:Foobar.jpg|thumb|300x300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
25345 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="34" width="300"/></a><figcaption>foo\n<span about="#mwt9" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"A"}},"i":0}}]}'>A</span>\n<span about="#mwt10" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"B"}},"i":0}}]}'>B</span>\n<span about="#mwt11" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"C"}},"i":0}}]}'>C</span></figcaption></figure>
25346 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="34" width="300"/></a><figcaption>foo\n<span about="#mwt12" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"A"}},"i":0}}]}'>A</span>\n<span about="#mwt13" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"B"}},"i":0}}]}'>B</span>\n<span about="#mwt14" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"C"}},"i":0}}]}'>C</span>\n\n</figcaption></figure>
25350 New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
25354 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>foo</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><p>new para</p>
25356 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid='{}'/><h1>new heading</h1>
25358 <includeonly>foo</includeonly>
25366 ## PHP emits broken html for this, and since this is primarily
25367 ## a Parsoid serializer test, marking this Parsoid only
25369 Improperly nested inline or quotes tags with whitespace in between
25371 <span> <s>x</span> </s>
25374 <p><span> <s>x</s></span><s> </s>
25375 <b> <i>x</i></b><i> </i>
25380 Encapsulate protected attributes from wt
25382 <div typeof="mw:placeholder stuff" data-mw="whoo" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
25384 {| typeof="mw:placeholder stuff" data-mw="whoo" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true"
25388 <div data-x-typeof="mw:placeholder stuff" data-x-data-mw="whoo" data-x-data-parsoid="weird" data-x-data-parsoid-other="no" data-x-about="time" data-x-rel="mw:true">foo</div>
25390 <table data-x-typeof="mw:placeholder stuff" data-x-data-mw="whoo" data-x-data-parsoid="weird" data-x-data-parsoid-other="no" data-x-about="time" data-x-rel="mw:true">
25391 <tbody><tr><td data-parsoid='{"autoInsertedEnd":true}'> ok</td></tr>
25395 ## Currently the p-wrapper is fragile in how it adds / removes transformations.
25396 ## Having nested or stray pre tags results in the attempt to add duplicates,
25397 ## causing an assertion fail. This test tries to prevent that situation.
25399 Ensure ParagraphWrapper can deal with stray closing pre tags
25409 1. Ensure fostered text content is wrapped in element nodes
25413 <table>hi</table><table>ho</table>
25422 2. Ensure fostered text content is wrapped in element nodes (traps regressions around fostered marker on the element getting lost)
25424 parsoid=wt2html,wt2wt
25433 <tbody><tr><td> a</td></tr>
25438 Encapsulation properly handles null DSR information from foster box
25440 parsoid=wt2html,wt2wt
25442 {{echo|<table>foo<tr><td>bar</td></tr></table>}}
25444 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table>foo<tr><td>bar</td></tr></table>"}},"i":0}}]}">foo</span><table><tbody><tr><td>bar</td></tr></tbody></table>
25448 1. Encapsulate foster-parented transclusion content
25450 parsoid=wt2wt,wt2html
25452 <table>{{echo|foo<tr><td>bar</td></tr>}}</table>
25454 <p typeof="mw:Transclusion" data-mw="{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<tr><td>bar</td></tr>"}},"i":0}},"</table>"]}">foo</p><table>
25464 2. Encapsulate foster-parented transclusion content
25466 parsoid=wt2wt,wt2html
25468 <table><div>{{echo|foo}}</div><tr><td>bar</td></tr></table>
25470 <div typeof="mw:Transclusion" data-mw="{"parts":["<table><div>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}},"</div><tr><td>bar</td></tr></table>"]}">foo</div>
25481 3. Encapsulate foster-parented transclusion content
25483 parsoid=wt2wt,wt2html
25485 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
25487 <div typeof="mw:Transclusion" data-mw="{"parts":["<table><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div><tr><td>"}},"i":0}},"bar</td></tr></table>"]}">
25500 4. Encapsulate foster-parented transclusion content
25502 parsoid=wt2wt,wt2html
25504 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
25506 <div typeof="mw:Transclusion" data-mw="{"parts":["<table><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div><tr><td>"}},"i":0}},"bar</td></tr></table>"]}">
25519 5. Encapsulate foster-parented transclusion content
25521 parsoid=wt2wt,wt2html
25523 <table><tr><td><div><p>{{echo|foo</p></div></td>foo}}</tr></table>
25525 <p typeof="mw:Transclusion" data-mw="{"parts":["<table><tr><td><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo"}},"i":0}},"</tr></table>"]}">foo</p>
25540 6. Encapsulate foster-parented transclusion content
25542 parsoid=wt2wt,wt2html
25544 <table><tr><td><div><p>{{echo|foo</p></div></td>foo</tr></table>}}<p>ok</p>
25546 <p typeof="mw:Transclusion" data-mw="{"parts":["<table><tr><td><div><p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo</tr></table>"}},"i":0}}]}">foo</p>
25562 7. Encapsulate foster-parented transclusion content
25564 parsoid=wt2wt,wt2html
25566 <table>{{echo|<p>foo</p>}}<td>bar</td></table>
25568 <p typeof="mw:Transclusion" data-mw="{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<p>foo</p>"}},"i":0}},"<td>bar</td></table>"]}">foo</p>
25578 # Note that the wt is broken on purpose: the = should be {{=}} if you
25579 # don't want it to be a template parameter key.
25581 8. Encapsulate foster-parented transclusion content
25583 parsoid=wt2wt,wt2html
25586 }}{|{{echo|style='color:red'}}
25591 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n"}},"i":0}}]}'>a</p>
25593 <p typeof="mw:Transclusion" data-mw='{"parts":["{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"style":{"wt":"'color:red'"}},"i":0}},"\n|-\n|b\n|}"]}'>{{{1}}}</p>
25604 9. Encapsulate foster-parented transclusion content
25606 parsoid=wt2wt,wt2html
25608 <table>{{echo|hi</table>hello}}
25610 <p about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"hi</table>hello"}},"i":0}}]}' data-parsoid='{"fostered":true,"autoInsertedEnd":true,"autoInsertedStart":true,"pi":[[{"k":"1"}]]}'>hi</p><table about="#mwt2" data-parsoid='{"stx":"html"}'></table><p about="#mwt2">hello</p>
25614 Table in fosterable position
25625 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"OpenTable","href":"./Template:OpenTable"},"params":{},"i":0}},"\n<div>\n"]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[]]}'></div><span about="#mwt1">
25627 <table about="#mwt1" data-parsoid='{"autoInsertedEnd":true}'></table>
25633 # Parsoid only for bug 64747
25635 Properly encapsulate empty-content transclusions in fosterable positions
25643 <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"}]]}'>
25649 Always encapsulate foster box when template range is expanded to table
25662 T115289: Unclosed table
25664 {{echo|<table>}}<!--c-->[[Category:Two]]
25666 <link rel="mw:PageProp/Category" href="./Category:Two" about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"simple","a":{"href":"./Category:Two"},"sa":{"href":"Category:Two"},"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table>"}},"i":0}},"<!--c-->[[Category:Two]]"]}'/><table about="#mwt1" data-parsoid='{"stx":"html","autoInsertedEnd":true}'><!--c--></table>
25670 T115289: Don't migrate newlines out of tables with fostered content
25672 <table><td></td>{{echo|<tr>[[Category:One]]}}<!--c-->[[Category:Two]]
25674 <link rel="mw:PageProp/Category" href="./Category:One" about="#mwt2" typeof="mw:Transclusion" data-parsoid='{"stx":"simple","a":{"href":"./Category:One"},"sa":{"href":"Category:One"},"fostered":true,"pi":[[{"k":"1"}]]}' data-mw='{"parts":["<table><td></td>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<tr>[[Category:One]]"}},"i":0}},"<!--c-->[[Category:Two]]"]}'/><link rel="mw:PageProp/Category" href="./Category:Two" about="#mwt2"/><table about="#mwt2" data-parsoid='{"stx":"html","autoInsertedEnd":true}'><tbody><tr><td></td></tr><tr><!--c--></tr></tbody></table>
25678 T73074: More fostering fun
25680 <table><td></td>{{echo|<tr>}}<!--c-->[[Category:Two]]
25682 <link rel="mw:PageProp/Category" href="./Category:Two" data-parsoid='{"stx":"simple","a":{"href":"./Category:Two"},"sa":{"href":"Category:Two"},"fostered":true}'/><table data-parsoid='{"stx":"html","autoInsertedEnd":true}'><tbody><tr data-parsoid='{"autoInsertedEnd":true,"autoInsertedStart":true}'><td data-parsoid='{"stx":"html"}'></td></tr><tr about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<tr>"}},"i":0}},"<!--c-->[[Category:Two]]"]}'><!--c--></tr></tbody></table>
25686 Support <object> element with .data attribute
25690 <object data="test.swf"></object>
25692 <object data="test.swf"></object>
25696 Don't block XML namespace declaration
25698 <span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">MediaWiki</span>
25700 <p><span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">MediaWiki</span>
25703 <p><span xmlns:dct="http://purl.org/dc/terms/" data-x-property="dct:title" data-parsoid='{"stx":"html"}'>MediaWiki</span></p>
25706 # -----------------------------------------------------------------
25707 # The following section of tests are primarily to spec requirements
25708 # around Parsoid's serialization (old, new, edited content)
25710 # All these tests are marked Parsoid html2wt and html2html only
25711 # ----------------------------------------------------------------
25714 Ignore rel attribute in a-tags during serialization to url-links
25718 <a href='http://en.wikipedia.org/wiki/Foobar'>http://en.wikipedia.org/wiki/Foobar</a>
25719 <a href='http://en.wikipedia.org/wiki/Foobar' rel='mw:ExtLink'>http://en.wikipedia.org/wiki/Foobar</a>
25720 <a href='http://en.wikipedia.org/wiki/Foobar' rel='mw:WikiLink'>http://en.wikipedia.org/wiki/Foobar</a>
25722 http://en.wikipedia.org/wiki/Foobar
25723 http://en.wikipedia.org/wiki/Foobar
25724 http://en.wikipedia.org/wiki/Foobar
25727 # 'mi' is a localinterwiki prefix as well as a language
25729 Serialize interwiki links pointing to the current wiki as plain wiki links (bug 65869)
25733 <p><a rel="mw:ExtLink" href="http://mi.wikipedia.org/wiki/Foo">Foo</a></p>
25740 New wikilinks should be serialized properly
25744 <a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid='{}'>Foo</a>
25745 <a rel="mw:WikiLink" href="./Foo" title="Foo">Foo</a>
25746 <a href="//en.wikipedia.org/wiki/Foo">//en.wikipedia.org/wiki/Foo</a>
25747 <a href="http://en.wikipedia.org/wiki/Foo">http://en.wikipedia.org/wiki/Foo</a>
25748 <a href="//en.wikipedia.org/wiki/Foo_bar">//en.wikipedia.org/wiki/Foo bar</a>
25752 [[:en:Foo|//en.wikipedia.org/wiki/Foo]]
25753 http://en.wikipedia.org/wiki/Foo
25754 [[:en:Foo_bar|//en.wikipedia.org/wiki/Foo bar]]
25758 New wiki links (href variations)
25762 <a rel="mw:WikiLink" href="./Foo_bar">Foo_bar</a>
25763 <a rel="mw:WikiLink" href="Foo_bar">Foo_bar</a>
25764 <a rel="mw:WikiLink" href="Foo bar">Foo_bar</a>
25765 <a rel="mw:WikiLink" href="./Toxine_bact%C3%A9rienne">Toxine bactérienne</a>
25770 [[Toxine bactérienne]]
25774 New wiki links (content string variations)
25778 <a rel="mw:WikiLink" href="./Foo_bar">Foo_bar</a>
25779 <a rel="mw:WikiLink" href="./Foo_bar">Foo bar</a>
25780 <a rel="mw:WikiLink" href="./Foo_bar">./Foo_bar</a>
25784 [[Foo_bar|./Foo_bar]]
25788 New category links (href variations)
25792 <link rel="mw:PageProp/Category" href="./Category:Toxine_bactérienne" />
25793 <link rel="mw:PageProp/Category" href="./Category:Toxine_bact%C3%A9rienne" />
25794 <link rel="mw:PageProp/Category" href="Category:Toxine_bact%C3%A9rienne" />
25796 [[Category:Toxine bactérienne]]
25797 [[Category:Toxine bactérienne]]
25798 [[Category:Toxine bactérienne]]
25802 New sol transparent links don't need indent-pre nowiki protection
25807 <link rel="mw:PageProp/redirect" href="./Main_Page">
25808 <!-- this is good --> <link rel="mw:PageProp/Category" href="./Category:Good" />
25809 <!-- this is great --> <link rel="mw:PageProp/Category" href="./Kategorie:Great" />
25811 #WEITERLEITUNG [[Main Page]]
25812 <!-- this is good --> [[Category:Good]]
25813 <!-- this is great --> [[Kategorie:Great]]
25817 New interlanguage links (href variations)
25821 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine bactérienne" />
25822 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine_bactérienne" />
25823 <link rel="mw:PageProp/Language" href="http://es.wikipedia.org/wiki/Toxine_bact%C3%A9rienne" />
25825 [[es:Toxine bactérienne]]
25826 [[es:Toxine_bactérienne]]
25827 [[es:Toxine_bactérienne]]
25831 Image: Modifying size of an image (1)
25834 "modes": ["wt2wt"],
25836 ["img[height]", "attr", "height", "22"],
25837 ["img[width]", "attr", "width", "200"]
25841 [[Image:Foobar.jpg|230x230px]]
25843 [[Image:Foobar.jpg|200x200px]]
25847 Image: Modifying size of an image (2)
25850 "modes": ["wt2wt"],
25852 ["img[height]", "attr", "height", "100"],
25853 ["img[width]", "attr", "width", "500"]
25857 [[Image:Foobar.jpg|230x230px]]
25859 [[Image:Foobar.jpg|500x500px]]
25862 # Change in size is ignored so long as class='mw-default-size'
25864 Image: Modifying size of an image (3)
25867 "modes": ["wt2wt"],
25869 ["figure[class]", "removeClass", "mw-default-size"],
25870 ["figure img", "attr", "height", "19"],
25871 ["figure img", "attr", "width", "170"]
25875 [[Image:Foobar.jpg|thumb]]
25877 [[Image:Foobar.jpg|thumb|170x170px]]
25881 Image: Modifying alignment of an image (bug 48665)
25884 "modes": ["wt2wt"],
25886 ["figure[class]", "removeClass", "mw-halign-right"],
25887 ["figure[class]", "addClass", "mw-halign-left"]
25891 [[Image:Foobar.jpg|thumb|caption|right]]
25893 [[Image:Foobar.jpg|thumb|caption|left]]
25897 Image: Modifying mw-default-size of an frameless image (bug 62805)
25900 "modes": ["wt2wt"],
25902 ["figure.mw-default-size", "removeClass", "mw-default-size"]
25906 [[Image:Foobar.jpg|frameless|right]]
25908 [[Image:Foobar.jpg|frameless|right|220x220px]]
25912 Image: Modifying valign of an image (bug 49221)
25915 "modes": ["wt2wt"],
25917 ["*[typeof=\"mw:Image\"]", "removeClass", "mw-valign-middle"],
25918 ["*[typeof=\"mw:Image\"]", "addClass", "mw-valign-text-top"]
25922 [[File:Foobar.jpg|20px|middle]]
25924 [[File:Foobar.jpg|20px|text-top]]
25928 Image: Modifying alt attribute of an image (bug 56400)
25931 "modes": ["wt2wt"],
25933 ["img[alt]", "attr", "alt", "some alternate edited text"]
25937 [[File:Foobar.jpg|thumb|some caption|alt=some alternate text]]
25939 [[File:Foobar.jpg|thumb|some caption|alt=some alternate edited text]]
25943 Image: Modifying caption of an image
25946 "modes": ["wt2wt"],
25948 ["figcaption", "text", "new caption"]
25952 [[Image:Foobar.jpg|thumb|original caption]]
25954 [[Image:Foobar.jpg|thumb|new caption]]
25958 Image: empty alt attribute (bug 48924)
25962 [[File:Foobar.jpg|thumb|alt=|bar]]
25964 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" 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>
25968 Image: new attributes should be serialized in wiki's language for RTL languages (bug 51852)
25974 <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" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="20" width="180"/></a></figure>
25976 [[Imagen:Foobar.jpg|derecha|miniaturadeimagen]]
25980 Image: Block level image should have \n before and after
25983 [[File:Foobar.jpg|right|thumb|150x150px]]
25987 <figure class="mw-halign-right" typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/150px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="17" width="150"/></a></figure>
25992 Image: New block level image should have \n before and after (existing content)
25995 [[File:Foobar.jpg|right|thumb|150x150px]]
25999 <figure class="mw-halign-right" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"right","ak":"right"},{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"150x150px"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/150px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="17" width="150" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"17","width":"150"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></figure>
26004 Image: upright option (parsoid)
26006 [[File:Foobar.jpg|thumb|upright|caption]]
26007 [[File:Foobar.jpg|thumb|upright=0.5|caption]]
26008 [[File:Foobar.jpg|thumb|500x500px|upright=0.5|caption]]
26010 <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/170px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="19" width="170"/></a><figcaption>caption</figcaption></figure>
26011 <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/110px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="12" width="110"/></a><figcaption>caption</figcaption></figure>
26012 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/500px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="57" width="500"/></a><figcaption>caption</figcaption></figure>
26016 Image: upright option is ignored on inline and frame images (parsoid)
26018 [[File:Foobar.jpg|500x500px|upright=0.5|caption]]
26020 <p><span typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/500px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="57" width="500"/></a></span></p>
26024 Image: from basic HTML (1)
26028 <span typeof="mw:Image">
26029 <img src="./File:Foobar.jpg" width=100 height=100 alt="Alt">
26032 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
26036 Image: from basic HTML (2)
26040 <img src="./File:Foobar.jpg" width=100 height=100 alt="Alt">
26042 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
26046 Image: from basic HTML (3)
26050 <a href="Main"><img src="./File:Foobar.jpg" width=100 height=100 alt="Alt"></a>
26052 [[File:Foobar.jpg|link=Main|alt=Alt|100x100px]]
26056 Image: from basic HTML (4)
26060 <img src="./File:Foobar.jpg">
26062 [[File:Foobar.jpg|link=]]
26066 Image: Invalid title as link
26068 [[File:Foobar.jpg|link=<]]
26070 <p><a href="/wiki/File:Foobar.jpg" class="image" title="link=<"><img alt="link=<" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
26073 <p><span class="mw-default-size" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"link","ak":"link=<"}]}' data-mw='{"caption":"link=&lt;"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"sa":{}}'><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="220" width="1941" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"220","width":"1941"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
26077 Lists: Serialize correctly even when list content is wrapped in p-tags (like VE does)
26082 <li><p>foo</p></li>
26089 Lists: Serialize correctly even when list tags has unneeded whitespace between tags
26093 <ul> <li>foo</li></ul>
26099 Don't strip leading whitespace when handling indent-pre suppressing tags
26104 <tr><td> indented row</td></tr>
26107 <b>This is very bold of you!</b>
26110 indented cell (no pre-wrapping!)
26120 '''This is very bold of you!'''
26124 indented cell (no pre-wrapping!)
26132 Nowiki-wrap leading whitespace when handling indent-pre inducing tags
26154 <nowiki> </nowiki></span>bar2
26157 <nowiki> </nowiki><span>bar</span>
26160 <nowiki> </nowiki><span>foo</span>
26165 Lists: Dont insert newlines in a serialized list item.
26169 <ul><li>a<br>b</li><li>c</li></ul>
26176 1. Headings: Force sol-transparent links and behavior switches to serialize before/after
26179 "modes": ["html2wt"],
26180 "scrubWikitext": false
26183 <h2>hello there<link href="./Category:A1" rel="mw:PageProp/Category" /></h2>
26184 <h2><link href="./Category:A2" rel="mw:PageProp/Category" />hi pal</h2>
26186 <h2><!--foo--> <link href="./Category:A3" rel="mw:PageProp/Category" /> how goes it</h2>
26187 <h2>it goes well <link href="./Category:A4" rel="mw:PageProp/Category" /> <!--bar--></h2>
26189 <h2 data-parsoid='{}'>howdy<link href="./Category:A5" rel="mw:PageProp/Category" /></h2>
26191 <h2><meta property="mw:PageProp/toc" /> ok</h2>
26193 == hello there [[Category:A1]] ==
26195 == [[Category:A2]] hi pal ==
26197 == <!--foo--> [[Category:A3]] how goes it ==
26199 == it goes well [[Category:A4]] <!--bar--> ==
26201 ==howdy [[Category:A5]]==
26207 2. Headings: Force sol-transparent links and behavior switches to serialize before/after
26210 "modes": ["html2wt"],
26211 "scrubWikitext": true
26214 <h2>hello there<link href="./Category:A1" rel="mw:PageProp/Category" /></h2>
26215 <h2><link href="./Category:A2" rel="mw:PageProp/Category" />hi pal</h2>
26217 <h2><!--foo--> <link href="./Category:A3" rel="mw:PageProp/Category" /> how goes it</h2>
26218 <h2>it goes well <link href="./Category:A4" rel="mw:PageProp/Category" /> <!--bar--></h2>
26220 <h2><meta property="mw:PageProp/toc" /> ok</h2>
26228 <!--foo--> [[Category:A3]]
26233 [[Category:A4]] <!--bar-->
26241 Headings: Don't hoist metas that come from templates
26244 "modes": ["html2wt"],
26245 "scrubWikitext": true
26248 <h2><span about="#mwt1" typeof="mw:Transclusion" data-parsoid="{}" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo [[Category:Foo]]"}},"i":0}}]}'>foo </span><link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1" data-parsoid="{}" /></h2>
26250 == {{echo|foo [[Category:Foo]]}} ==
26254 Headings: Category in ref isn't hoisted
26257 "modes": ["html2wt"],
26258 "scrubWikitext": true
26261 <h2> foo <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> </h2>
26263 <ol class="references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-1">↑</a></span> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">bar <link rel="mw:PageProp/Category" href="./Category:Baz" /> </span></li></ol>
26266 [[Category:Baz]] </ref> ==
26272 Parsoid: Serialize positional parameters with = in them as named parameter
26276 <p about="#mwt1" typeof="mw:Transclusion"
26277 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}}]}'>foo</p>
26279 <p about="#mwt1" typeof="mw:Transclusion"
26280 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}, "2":{"wt":"bar"}},"i":0}}]}'>foo</p>
26282 <!--Orig params with data-parsoid has heuristics for handling = chars-->
26283 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
26284 <p data-parsoid='{"pi":[[{"k":"1"},{"k":"2"}]]}' 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>
26288 {{echo|1=f=oo|2=bar}}
26290 <!--Orig params with data-parsoid has heuristics for handling = chars-->
26291 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
26292 {{echo|<nowiki>f=oo</nowiki>|bar}}
26296 Parsoid: Serialize positional parameters with = in extlink as named parameter
26300 <p><a rel="mw:ExtLink" href="http://stuff?is=ok" about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://stuff?is=ok"}},"i":0}}]}'>http://stuff?is=ok</a></p>
26302 {{echo|1=http://stuff?is=ok}}
26306 Parsoid: Correctly serialize block-node children when they are a combination of text and p-nodes
26310 <div>a<p>b</p></div>
26331 Substrings resembling wikitext in hrefs should not get nowiki escapes
26335 <a rel="mw:WikiLink" href="./Foo''bar''baz">Foo''bar''baz</a>
26341 Enforce single-line context in the serializer
26348 <h2> hi <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bogus","href":"./Template:Bogus"},"params":{"1":{"wt":"there\nyou"}},"i":0}}]}'>there</span><span about="#mwt1">
26349 </span><span about="#mwt1">you</span> </h2>
26351 <h2> foo <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> </h2>
26353 <ol class="references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-1">↑</a></span> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">hello
26354 there</span></li></ol>
26366 ho </dt><dd data-parsoid='{"stx":"row"}'> hi
26373 </tbody></table></dd></dl>
26377 == hi {{bogus|there
26388 * foo '''bar''' baz
26400 Serialize new placeholder space without spans
26404 <p>foo<span typeof="mw:Placeholder"> </span>: bar</p>
26406 <p>foo<span typeof="mw:DisplaySpace mw:Placeholder" data-parsoid='{"src":" ","isDisplayHack":true}'> </span>: bar</p>
26408 <span typeof="mw:Extension/ref" data-mw="{"name":"ref","body":{"html":"foo<span typeof=\"mw:Placeholder\">&nbsp;</span>: bar"}}"><sup>[1]</sup></span>ok</p>
26414 <ref>foo : bar</ref>ok
26418 #-----------------------
26419 # Tag minimization tests
26420 #-----------------------
26423 1. I/B quote minimization: wikitext-only tags should be combined
26427 <p><i>A</i><i>B</i></p>
26428 <p><b>A</b><b>B</b></p>
26429 <p><i>A</i><b><i>B</i></b></p>
26430 <p><b>A</b><i><b>B</b></i></p>
26431 <p><b>A</b><i><b>B</b><b>C</b></i><b>D</b></p>
26432 <p><i><b>A</b></i><i><b>B</b></i></p>
26433 <p><i><b>A</b></i><b><i>B</i></b></p>
26434 <p><b><i>A</i></b><i><b>B</b></i></p>
26454 2. I/B quote minimization: wikitext and html tags should not be combined
26458 <p><i>A</i><i data-parsoid='{"stx":"html"}'>B</i></p>
26459 <p><i>A</i><b><i data-parsoid='{"stx":"html"}'>B</i></b></p>
26463 ''A''<nowiki/>'''<i>B</i>'''
26467 3. I/B quote minimization: templated content stops minimization
26471 <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>
26472 <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>
26474 ''A''{{echo|''B''}}
26476 ''A''{{echo|'''''B'''''}}
26480 4. I/B quote minimization: new content should be mimimized with adjacent old content
26484 <p><i>A</i><i>B</i></p>
26485 <p><b>A</b><b>B</b></p>
26486 <p><i>A</i><b><i>B</i></b></p>
26496 5a. Merge adjacent quote nodes if they've been edited
26499 "modes": ["wt2wt", "selser"],
26501 ["p", "contents", "remove", ":contains('b')"]
26511 5b. Merge adjacent quote nodes if they've been edited
26514 "modes": ["wt2wt", "selser"],
26520 ''a''<span id="x">b</span>''c''
26526 1. Merge adjacent link nodes as long as at least one element is new
26529 "modes": ["html2wt"],
26530 "scrubWikitext": true
26533 <a rel="mw:WikiLink" href="./Football">Foot</a><a rel="mw:WikiLink" href="./Football">ball</a>
26534 <a data-parsoid="{}" rel="mw:WikiLink" href="./Football">Foot</a><a rel="mw:WikiLink" href="./Football">ball</a>
26535 <a data-parsoid="{}" rel="mw:WikiLink" href="./Football">Foot</a><a data-parsoid="{}" rel="mw:WikiLink" href="./Football">ball</a>
26539 [[Football|Foot]][[Football|ball]]
26543 2. Merge adjacent link nodes and enable additional normalizations
26546 "modes": ["html2wt"],
26547 "scrubWikitext": true
26550 <a rel="mw:WikiLink" href="./Football"><i>Foot</i></a><a rel="mw:WikiLink" href="./Football"><i>ball</i></a>
26552 [[Football|''Football'']]
26556 3. Don't merge adjacent link nodes if scrubWikitext is false
26559 "modes": ["html2wt"],
26560 "scrubWikitext": false
26563 <a rel="mw:WikiLink" href="./Football">Foot</a><a rel="mw:WikiLink" href="./Football">ball</a>
26565 [[Football|Foot]][[Football|ball]]
26568 #------------------------------
26569 # End of tag minimization tests
26570 #------------------------------
26573 Bug 54262: New entities
26577 <span typeof="mw:Entity"> </span>
26582 ## Note that there is no wikitext output for 'unknownproperty' ##
26583 ## Unknown magic words are silently dropped ##
26590 <meta property='mw:PageProp/toc' />
26591 <meta property='mw:PageProp/notoc' />
26592 <meta property='mw:PageProp/forcetoc' />
26593 <meta property='mw:PageProp/index' />
26594 <meta property='mw:PageProp/noindex' />
26595 <meta property='mw:PageProp/nogallery' />
26596 <meta property='mw:PageProp/noeditsection' />
26597 <meta property='mw:PageProp/notitleconvert' />
26598 <meta property='mw:PageProp/nocontentconvert' />
26599 <meta property='mw:PageProp/unknownproperty' />
26609 __NOCONTENTCONVERT__
26613 Consecutive <pre>s should not get merged
26615 parsoid=html2wt,html2html
26617 <pre>a</pre><pre>b</pre>
26645 Edited ISBN links not serializable as ISBN links should serialize as wikilinks
26649 <a href="./Special:BookSources/1234567890" rel="mw:ExtLink">ISBN 1234567895</a>
26651 [[Special:BookSources/1234567890|ISBN 1234567895]]
26655 Edited RFC links not serializable as RFC links should serialize as extlinks
26659 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink">New RFC</a>
26661 [//tools.ietf.org/html/rfc123 New RFC]
26665 Edited PMID links not serializable as PMID links should serialize as extlinks
26669 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink">New PMID</a>
26671 [//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract New PMID]
26675 WTS of autolinks with trailing/surrounding context
26679 <p><a href="http://cscott.net">http://cscott.net</a><b>foo</b></p>
26680 <p><a href="http://cscott.net">http://cscott.net</a><b data-parsoid='{"stx":"html"}'>foo</b></p>
26681 <p><b><a href="http://cscott.net">http://cscott.net</a></b></p>
26682 <p><b><a href="http://cscott.net">http://cscott.net</a> </b></p>
26683 <p><b><a href="http://cscott.net">http://cscott.net</a>x</b></p>
26684 <p><a href="http://cscott.net">http://cscott.net</a>x</p>
26686 http://cscott.net'''foo'''
26688 http://cscott.net<b>foo</b>
26690 '''http://cscott.net'''
26692 '''http://cscott.net '''
26694 '''http://cscott.net<nowiki/>x'''
26696 http://cscott.net<nowiki/>x
26700 WTS of autolinks with nowikis (round-trip)
26702 x<nowiki/>http://cscott.net<nowiki/>x
26704 <p>x<a rel="mw:ExtLink" href="http://cscott.net">http://cscott.net</a>x</p>
26707 # this is the "easy" test because it leaves in place all the
26708 # data-parsoid information indicating this is an autolink
26710 WTS of autolinks with escapes (editing)
26713 "modes": ["wt2wt"],
26715 [ "meta", "remove" ]
26719 x<nowiki/>http://cscott.net<nowiki/>x
26721 x<nowiki/>http://cscott.net<nowiki/>x
26725 WTS of edited autolink-like text (T103364)
26728 "modes": ["wt2wt"],
26730 [ "span[typeof]", "removeAttr", "typeof" ]
26734 Not a link: <nowiki>http://example.com</nowiki>.
26736 Not a link: <span><nowiki>http://example.com</nowiki></span>.
26740 WTS of newly-authored autolink-like text (T103364)
26744 <p>http://example.com is not a link.</p>
26746 <nowiki>http://example.com</nowiki> is not a link.
26750 WTS of autolink-like text after an autolink (T108563)
26754 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a> http://example.com is not a link.</p>
26756 http://example.com <nowiki>http://example.com</nowiki> is not a link.
26760 Magic links inside links (not autolinked)
26762 [[Foo|http://example.com]]
26765 [[Foo|ISBN 123456789x]]
26767 [http://foo.com http://example.com]
26768 [http://foo.com RFC 1234]
26769 [http://foo.com PMID 1234]
26770 [http://foo.com ISBN 123456789x]
26772 <p><a href="/wiki/Foo" title="Foo">http://example.com</a> <a href="/wiki/Foo" title="Foo">RFC 1234</a> <a href="/wiki/Foo" title="Foo">PMID 1234</a> <a href="/wiki/Foo" title="Foo">ISBN 123456789x</a></p>
26773 <p><a rel="nofollow" class="external text" href="http://foo.com">http://example.com</a> <a rel="nofollow" class="external text" href="http://foo.com">RFC 1234</a> <a rel="nofollow" class="external text" href="http://foo.com">PMID 1234</a> <a rel="nofollow" class="external text" href="http://foo.com">ISBN 123456789x</a></p>
26775 <p><a rel="mw:WikiLink" href="./Foo" title="Foo">http://example.com</a>
26776 <a rel="mw:WikiLink" href="./Foo" title="Foo">RFC 1234</a>
26777 <a rel="mw:WikiLink" href="./Foo" title="Foo">PMID 1234</a>
26778 <a rel="mw:WikiLink" href="./Foo" title="Foo">ISBN 123456789x</a></p>
26780 <p><a rel="mw:ExtLink" href="http://foo.com">http://example.com</a>
26781 <a rel="mw:ExtLink" href="http://foo.com">RFC 1234</a>
26782 <a rel="mw:ExtLink" href="http://foo.com">PMID 1234</a>
26783 <a rel="mw:ExtLink" href="http://foo.com">ISBN 123456789x</a></p>
26787 Magic links inside image captions (autolinked)
26789 [[File:Foobar.jpg|thumb|http://example.com]]
26790 [[File:Foobar.jpg|thumb|RFC 1234]]
26791 [[File:Foobar.jpg|thumb|PMID 1234]]
26792 [[File:Foobar.jpg|thumb|ISBN 123456789x]]
26794 <div class="thumb tright">
26795 <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>
26796 <div class="thumbcaption">
26797 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
26798 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div>
26801 <div class="thumb tright">
26802 <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>
26803 <div class="thumbcaption">
26804 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
26805 <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a></div>
26808 <div class="thumb tright">
26809 <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>
26810 <div class="thumbcaption">
26811 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
26812 <a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a></div>
26815 <div class="thumb tright">
26816 <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>
26817 <div class="thumbcaption">
26818 <div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"></a></div>
26819 <a href="/wiki/Special:BookSources/123456789X" class="internal mw-magiclink-isbn">ISBN 123456789x</a></div>
26823 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
26824 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a href="//tools.ietf.org/html/rfc1234" rel="mw:ExtLink">RFC 1234</a></figcaption></figure>
26825 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract" rel="mw:ExtLink">PMID 1234</a></figcaption></figure>
26826 <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/220px-Foobar.jpg" data-file-width="1941" data-file-height="220" data-file-type="bitmap" height="25" width="220"/></a><figcaption><a href="./Special:BookSources/123456789X" rel="mw:WikiLink">ISBN 123456789x</a></figcaption></figure>
26830 WTS of magic word text (T109371)
26835 <p><a href="http://foo.com" rel="mw:ExtLink">RFC 1234</a></p>
26836 <p><a href="./Foo" rel="mw:WikiLink">RFC 1234</a></p>
26838 <nowiki>RFC 1234</nowiki>
26840 [http://foo.com RFC 1234]
26846 Edited Redirect link should emit a non-piped wikitext link
26850 <link rel="mw:PageProp/redirect" href="Bar" data-parsoid='{"a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>
26856 T75121: Infer extension name from typeOf if data-mw is not present
26858 parsoid={ "modes": ["html2wt"], "suppressErrors": true }
26860 <div typeOf="mw:Extension/foo"></div>
26865 # Note that the <p> wrapping isn't present in PHP parser output
26866 # The important thing for this test is that P-wrapping doesn't
26867 # interfere with the <nowiki> protection for leading - in <td>
26868 # (which isn't necessary for <th>).
26870 T88318: p-wrapped dash in table.
26872 parsoid=html2wt,wt2wt
26875 <tr><th><p>-</p></th><th><p>- </p></th></tr>
26876 <tr><td><p>-</p></td><td><p>- </p></td></tr>
26877 <tr><td><small>-</small></td><td><br/><p>-</p></td><td><br/>-</td></tr>
26884 |<nowiki>-</nowiki>
26885 |<nowiki>- </nowiki>
26904 <td><small>-</small></td>
26916 T149209: WTS: Handle newlines in table cells properly
26924 </td><td data-parsoid='{"stx_v":"row"}'>c</td></tr>
26926 </td><td data-parsoid='{"stx_v":"row", "startTagSrc": "{{!}}{{!}}"}'>y</td></tr>
26932 </th><th data-parsoid='{"stx_v":"row"}'>c</th></tr>
26934 </th><th data-parsoid='{"stx_v":"row"}'>y</th></tr>
26956 T149209: Selser: Handle newlines in table cells properly
26959 "modes": ["selser"],
26961 [ "#h1", "html", "a\nb\n" ],
26962 [ "#h2", "html", "a\nb\n" ],
26963 [ "#c1", "html", "a\nb\n" ],
26964 [ "#c2", "html", "<p>a</p>" ],
26965 [ "#c3", "html", "<p>a</p>" ],
26966 [ "#c4", "html", "edit-me<p>a</p>" ]
26971 ! id="h1" |edit-me!!1
26973 ! id="h2" |edit-me||2
26975 | id="c1" |edit-me||3
26977 | id="c2" |edit-me||4
26979 | id="c3" |edit-me||p||q||r
26981 | id="c4" |edit-me||p||q||r
27010 HTML id attribute with Parsoid-like element ids should not be serialized to wikitext
27015 <td id='mwAc'>foo</td>
27016 <td id='serialize-this'>bar</td>
27021 | id="serialize-this" |bar
27026 Parsoid-like element ids should not be serialized to wikitext unless shadowed
27030 <div id="mwAQ" data-parsoid='{"stx":"html","a":{"id":"mwAQ"},"sa":{"id":"hello"}}'>ok</div>
27032 <div id="hello">ok</div>
27039 "modes": ["wt2wt"],
27041 [ "#xyz", "before", "<b>before</b> stuff " ],
27042 [ "#xyz", "after", " stuff <i>after</i>" ],
27043 [ "#xyz", "html", "x <b>y</b> z" ]
27047 <span id="xyz">hello</span>
27049 '''before''' stuff <span id="xyz">x '''y''' z</span> stuff ''after''
27053 Never serialize a-tag as html, regardless of what data-parsoid has to say
27055 parsoid={ "modes": ["html2wt"], "suppressErrors": true }
27057 <a rel="mw:WikiLink" href="./Foo" title="Foo" data-parsoid='{"stx":"html"}'>Foo</a>
27062 ## SSS FIXME: This is broken output nevertheless.
27063 ## What might be a reasonable non-broken output for this?
27064 ## This is an edge case unlikely to be seen in production
27065 ## that I am not wasting more time on this right now.
27067 Never serialize a-tag as html, no matter what attributes it has
27069 parsoid={ "modes": ["html2wt"], "suppressErrors": true }
27071 <a bad='true' href='http://boo.org'><img src='http://boohoo.org' /></a>
27073 [http://boo.org http://boohoo.org]
27076 # Misnested is an indication that selser can reuse the source but these have
27077 # shown to sneak through on occasion. See T101768.
27078 # The original wikitext here is: [http://test.com [[one]] two three]
27080 Strip span tags added to mark misnested links
27084 <p data-parsoid='{}'><a rel="mw:ExtLink" href="http://test.com" data-parsoid='{"targetOff":17,"contentOffsets":[17,34]}'></a><a rel="mw:WikiLink" href="./One" title="One" data-parsoid='{"stx":"simple","a":{"href":"./One"},"sa":{"href":"one"},"misnested":true}'>one</a><span data-parsoid='{"misnested":true}'> two three</span></p>
27086 [http://test.com][[one]] two three
27090 Use data-parsoid.firstWikitextNode to compute newline constraints for template content
27094 <span about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1"}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span><table about="#mwt2" typeof="mw:Transclusion mw:ExpandedAttrs" data-parsoid='{"a":{"{{echo|c\n{{!}}d\n}}":null},"sa":{"{{echo|c\n{{!}}d\n}}":""},"firstWikitextNode":"table","pi":[[{"k":"1"}]]}' data-mw='{"parts":["{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c\n{{!}}d\n"}},"i":0}},"\n|}"]}'>
27106 ## This test verifies the presence and computation of this attribute indirectly
27107 ## by making an edit and ensuring that the serialization is correct (which it would be
27108 ## only if firstWikitextNode is properly set).
27110 data-parsoid.firstWikitextNode should be computed properly in the presence of fostered content
27113 "modes": ["wt2wt"],
27115 [ "div#x", "remove" ],
27116 [ "div", "before", "<div>new</div>" ]
27120 <div id="x">foo</div>
27122 {{echo|<div>boo</div>
27130 {{echo|<div>boo</div>
27136 # --------------------------------------------
27137 # Tests spec'ing wikitext serialization norms |
27138 # --------------------------------------------
27141 1. Categories should always be serialized on their own line
27145 foo<link rel="mw:PageProp/Category" href="./Category:Foo">bar
27153 2. Categories that are part of templates should not introduce a line break
27155 foo {{echo|<span>bar</span> [[Category:baz]]}} bar
27157 <p>foo <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<span>bar</span> [[Category:baz]]"}},"i":0}}]}'>bar</span><span about="#mwt1"> </span><link rel="mw:PageProp/Category" href="./Category:Baz" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Category:Baz"},"sa":{"href":"Category:baz"}}'/> bar</p>
27160 # Careful while editing these next 2 tests. There are \u200f characters
27161 # before and after the <link> tags in the HTML and following some
27162 # of the categories in wikitext
27163 # Do not remove these characters in edits.
27165 # As part of the serialization, these bidi characters will get stripped.
27167 RTL (\u200f) and LTR (\u200e) markers around category tags should be stripped
27170 "modes": ["html2wt"],
27171 "scrubWikitext": true
27174 <p><link rel="mw:PageProp/Category" href="./קטגוריה:טקסים" />
27175 <link rel="mw:PageProp/Category" href="./קטגוריה:_שיטות_משפט" /></p>
27178 [[קטגוריה: שיטות משפט]]
27182 RTL (\u200f) and LTR (\u200e) markers should not be stripped if followed by a text node
27185 "modes": ["html2wt"],
27186 "scrubWikitext": true
27189 <p><link rel="mw:PageProp/Category" href="./קטגוריה:טקסים" />y</p>
27196 Lists: Add space after bullets
27203 <li><span> baz</span></li>
27208 * <span> baz</span>
27212 1. Headings: Add space before/after == (T53744)
27219 <h2><span> baz</span></h2>
27227 == <span> baz</span> ==
27231 2. Headings: Add space before/after == even after hoisted content
27234 "modes": ["html2wt"],
27235 "scrubWikitext": true
27238 <h2> <link href="./Category:A2" rel="mw:PageProp/Category" />ok</h2>
27246 1. Headings: suppress newly created empty headings
27249 "modes": ["html2wt"],
27250 "scrubWikitext": true
27258 2. Headings: don't suppress empty headings if scrubWikitext is false
27268 3. Headings: suppress empty headings on edits
27271 "modes": ["selser"],
27272 "scrubWikitext": true,
27278 ==<span id="x">foo</span>==
27283 Headings: Replace <br/> with a single whitespace char (when scrubWikitext = true)
27286 "modes": ["html2wt"],
27287 "scrubWikitext": true
27290 <h2>foo<br/>bar</h2>
27291 <h2>foo <span><br/>bar</span> baz</h2>
27295 == foo <span> bar</span> baz ==
27299 Headings: Replace <br/> with a single whitespace char (when scrubWikitext = false)
27302 "modes": ["html2wt"],
27303 "scrubWikitext": false
27306 <h2>foo<br/>bar</h2>
27312 1. WT Quote Tags: suppress newly created empty style tags
27315 "modes": ["html2wt"],
27316 "scrubWikitext": true
27324 2. WT Quote Tags: don't suppress empty style tags if scrubWikitext is false
27330 ''<nowiki/>'''''<nowiki/>'''
27334 3. WT Quote Tags: suppress empty style tags on edits
27337 "modes": ["selser"],
27338 "scrubWikitext": true,
27344 '''<span id="x">foo</span>'''
27349 1. Anchors: suppress newly created empty anchors
27352 "modes": ["html2wt"],
27353 "scrubWikitext": true
27356 <a rel="mw:WikiLink" href="./Test" title="Test"></a>
27361 2. Anchors: don't suppress empty anchors if scrubWikitext is false
27364 "modes": ["html2wt"],
27365 "scrubWikitext": false
27368 <a rel="mw:WikiLink" href="./Test" title="Test"></a>
27374 3. Anchors: suppress empty anchors on edits
27377 "modes": ["selser"],
27378 "scrubWikitext": true,
27384 [[Test|<span id="x">foo</span>]]
27389 3a. Anchors: do not suppress numbered extlinks
27392 "modes": ["wt2wt"],
27393 "scrubWikitext": true
27398 <a rel="mw:ExtLink" href="http://foo.com"></a>
27402 3b. Anchors: do not suppress numbered extlinks
27405 "modes": ["wt2wt"],
27406 "scrubWikitext": true,
27412 [http://foo.com <span id="x">foo</span>]
27418 Normalizations should be restricted to edited content
27421 "modes": ["selser"],
27422 "scrubWikitext": true,
27424 [ "h1", "before", "<i></i>"]
27438 1. Multiple normalizations (html2wt)
27441 "modes": ["html2wt"],
27442 "scrubWikitext": true
27446 <p><a href='Foo' rel='mw:WikiLink'>foo<i></i>
27447 </a><b><i></i></b>x</p>
27456 2. Multiple normalizations (selser)
27459 "modes": ["selser"],
27460 "scrubWikitext": true,
27462 [ "#x", "after", "<h1><i></i></h1>\n<p> x<b></b></p>"]
27466 <span id="x">foo</span>
27468 <span id="x">foo</span>
27474 1. Indent Pre Nowiki: suppress whitespace at the start of new paragraph
27477 "modes": ["html2wt"],
27478 "scrubWikitext": true
27490 2. Indent Pre Nowiki: don't suppress whitespace at the start of new paragraph if scrubWikitext is false
27497 <nowiki> </nowiki>hi
27499 <nowiki> </nowiki> hello
27503 3. Indent Pre Nowiki: suppress whitespace after newlines in new paragraph or table cell
27506 "modes": ["html2wt"],
27507 "scrubWikitext": true
27516 baz bang</td></tr></table>
27522 bar<span>boo</span></p>
27538 bar<span>boo</span>
27542 4. Indent Pre Nowiki: suppress leading whitespace in edited paragraphs
27545 "modes": ["selser"],
27546 "scrubWikitext": true,
27548 [ "p", "html", " a\n b" ]
27559 1. New links that end in spaces
27562 "modes": ["html2wt"],
27563 "scrubWikitext": false
27566 <p><a rel="mw:WikiLink" href="./Berlin" title="Berlin">Berlin </a>is the capital of Germany.</p>
27567 <p><a rel="mw:WikiLink" href="./Foo" title="Foo">Foo </a><b>bar</b></p>
27568 <p><a rel="mw:WikiLink" href="./Boston" title="Boston">Boston </a> is a city.</p>
27570 [[Berlin ]]<nowiki/>is the capital of Germany.
27574 [[Boston ]] is a city.
27578 2. New links that end in spaces
27581 "modes": ["html2wt"],
27582 "scrubWikitext": true
27585 <p><a rel="mw:WikiLink" href="./Berlin" title="Berlin">Berlin </a>is the capital of Germany.</p>
27586 <p><a rel="mw:WikiLink" href="./Foo" title="Foo">Foo </a><b>bar</b></p>
27587 <p><a rel="mw:WikiLink" href="./Boston" title="Boston">Boston </a> is a city.</p>
27589 [[Berlin]] is the capital of Germany.
27593 [[Boston]] is a city.
27597 1. Table cells with escapable prefixes
27600 "modes": ["html2wt"],
27601 "scrubWikitext": false
27605 <tr><td>a</td></tr>
27606 <tr><td>-</td></tr>
27607 <tr><td>+</td></tr>
27613 |<nowiki>-</nowiki>
27615 |<nowiki>+</nowiki>
27620 2. Table cells with escapable prefixes
27623 "modes": ["html2wt"],
27624 "scrubWikitext": true
27628 <tr><td>a</td></tr>
27629 <tr><td>-</td></tr>
27630 <tr><td>+</td></tr>
27643 3a. Table cells with escapable prefixes after edits
27646 "modes": ["selser"],
27647 "scrubWikitext": true,
27649 [ "table tbody tr:first-child td:first-child", "remove"]
27663 3b. Table cells with escapable prefixes after edits
27666 "modes": ["selser"],
27667 "scrubWikitext": true,
27669 [ "table tbody tr:first-child td:first-child", "html", "-" ],
27676 |<span id="x">foo</span>+
27685 # FIXME: This test will fail because
27686 # normalization doesn't realize that the id attribute
27687 # will eliminate the escapable scenario
27689 4a. Table cells without escapable prefixes after edits
27692 "modes": ["selser"],
27693 "scrubWikitext": true,
27695 [ "#x", "html", "-" ]
27708 ## This tests normalizer's ability to discriminate between
27709 ## cells having identical content.
27711 4b. Table cells without escapable prefixes after edits
27714 "modes": ["selser"],
27715 "scrubWikitext": true,
27717 [ "td", "html", "-" ]
27730 ## This tests normalizer's ability to not be tripped by
27731 ## comments (and whitespace)
27733 4c. Table cells without escapable prefixes after edits
27736 "modes": ["selser"],
27737 "scrubWikitext": true,
27739 [ "table tbody tr td:first-child", "remove" ]
27754 ## This tests normalizer's ability to handle HTML cells
27756 4d. Table cells without escapable prefixes after edits
27759 "modes": ["selser"],
27760 "scrubWikitext": true,
27762 [ "td", "html", "-" ]
27767 <tr><td>a</td></tr>
27771 <tr><td>-</td></tr>
27775 ## T111151 Remove font elements without attributes
27777 5a. font tags without attributes should be dropped in scrubWikitext mode
27780 "modes": ["html2wt"],
27781 "scrubWikitext": true
27785 <font><font>bar</font></font>
27786 <font class="x">boo</font>
27790 <font class="x">boo</font>
27794 5b. font tags should not be dropped without scrubWikitext being enabled
27797 "modes": ["html2wt"],
27798 "scrubWikitext": false
27807 Escape nowiki DOM elements
27811 <nowiki><i>foo</i></nowiki>
27813 <nowiki>''foo''</nowiki>
27816 # This is meant to be an interim fix while we go about figuring out
27817 # how to not introduce these trailing <nowiki/>s in the first place.
27819 T115717: Strip trailing <nowiki/>s (without affecting valid uses)
27823 <p>x<meta typeof="mw:Placeholder" data-parsoid='{"src":"<nowiki/>"}'/><meta typeof="mw:Placeholder" data-parsoid='{"src":"<nowiki/>"}'/>
27825 <p><span about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1","named":true,"spc":["\n"," "," ",""]}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki/>"}},"i":0}}]}'></span></p>
27826 <p><span about="#mwt1" typeof="mw:Transclusion" data-parsoid='{"pi":[[{"k":"1","named":true,"spc":["\n"," "," ","\n"]}]]}' data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki/>"}},"i":0}}]}'></span></p>
27839 # ---------------------------------------------------
27840 # End of tests spec'ing wikitext serialization norms |
27841 # ---------------------------------------------------
27845 Bare inline nodes not wrapped inside p-tags should be treated as p-wrapped
27853 <td><b>c</b><p>d</p></td>
27871 # -----------------------------------------------------------------
27872 # End of section for Parsoid-only html2wt tests for serialization
27874 # -----------------------------------------------------------------
27876 # -----------------------------------------------------------------
27877 # The following section of tests are primarily to spec behavior of
27878 # the selective serializer. All these tests have manual selser
27879 # changes. The automated selser changes for all tests handle the
27880 # wide variation of changes, but these tests here capture specs
27881 # deterministically.
27882 # ----------------------------------------------------------------
27886 Selser: New comments should not be lost
27889 "modes": ["selser"],
27891 [ "#a", "after", "<!--c1-->" ],
27892 [ "#b", "before", "<!--c2-->" ]
27896 <span id="a">a</span>
27898 <span id="b">b</span>
27900 <span id="a">a</span><!--c1-->
27902 <!--c2--><span id="b">b</span>
27907 Selser: Check for validity of DSR before using it
27910 "modes": ["selser"],
27912 [ "#a", "before", "<meta property='mw:PageProp/displaytitle' content='foo'>" ]
27916 <span id="a">a</span>
27918 {{DISPLAYTITLE:foo}}
27919 <span id="a">a</span>
27923 1. DOMDiff: Changes to <ref> content should be looked up using id
27926 "modes": ["selser"],
27928 ["#X", "after", "bar"],
27929 ["#Y", "after", "baz"]
27933 X <ref><span id="X">foo</span></ref>
27936 <ref name="a"><span id="Y">foo</span></ref>
27939 X <ref><span id="X">foo</span>bar</ref>
27942 <ref name="a"><span id="Y">foo</span>baz</ref>
27947 2. DOMDiff: Changes to <ref> content should be looked up using id
27950 "modes": ["selser"],
27952 ["#Z", "after", "bar"]
27956 A <ref>foo bar for a</ref>
27957 B <ref group="X" name="b" />
27961 <references group="X">
27962 <ref name="b"><span id="Z">foo</span></ref>
27965 A <ref>foo bar for a</ref>
27966 B <ref group="X" name="b" />
27970 <references group="X">
27971 <ref name="b"><span id="Z">foo</span>bar</ref>
27976 DOMDiff: Edits to content nested in elements with templated attributes should not be lost (T139388)
27979 "modes": ["selser"],
27981 [ "div:first-child", "text", "bar" ]
27985 <div style="{{1x|color:red;}}%">foo</div>
27987 <div style="{{1x|color:red;}}%">bar</div>
28000 <li class="mw-empty-elt"></li>
28001 <li class="mw-empty-elt"></li>
28009 [[File:Thumb.png|thumb]]
28011 <div class="thumb tright">
28012 <div class="thumbinner" style="width:137px;"><a href="/wiki/File:Thumb.png" class="image"><img alt="Thumb.png" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a>
28013 <div class="thumbcaption">
28014 <div class="magnify"><a href="/wiki/File:Thumb.png" class="internal" title="Enlarge"></a></div>
28021 unclosed internal link XSS (T137264)
28023 [[#%3Cscript%3Ealert(1)%3C/script%3E|
28025 <p>[[#<script>alert(1)</script>|
28028 <p>[[#%3Cscript%3Ealert(1)%3C/script%3E|</p>