1 # MediaWiki Parser test cases
2 # Some taken from http://meta.wikimedia.org/wiki/Parser_testing
3 # All (C) their respective authors and released under the GPL
5 # The syntax should be fairly self-explanatory.
7 # Currently supported test options:
8 # One of the following three:
10 # (default) generate HTML output
11 # pst apply pre-save transform
12 # msg apply message transform
14 # Plus any combination of these:
16 # cat add category links
17 # ill add inter-language links
18 # subpage enable subpages (disabled by default)
19 # noxml don't check for XML well formdness
20 # title=[[XXX]] run test using article title XXX
21 # language=XXX set content language to XXX for this test
22 # variant=XXX set the variant of language for this test (eg zh-tw)
23 # disabled do not run test
24 # parsoid parsoid-only test (not run by PHP parser)
25 # php php-only test (not run by the parsoid parser)
26 # showtitle make the first line the title
27 # comment run through Linker::formatComment() instead of main parser
28 # local format section links in edit comment text as local links
30 # You can also set the following parser properties via test options:
31 # wgEnableUploads, wgAllowExternalImages, wgMaxTocLevel,
32 # wgLinkHolderBatchSize, wgRawHtml
34 # For testing purposes, temporary articles can created:
35 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
36 # where '/' denotes a newline.
38 # This is the standard article assumed to exist.
63 MediaWiki:bad image list
65 * [[File:Bad.jpg]] except [[Nasty page]]
99 Template:echo_with_span
105 Template:echo_with_div
117 Template:table_attribs
120 |</noinclude>style="color: red"| Foo
126 {{table_attribs}} || Bar || Baz
130 Template:image_attribs
133 [[File:foobar.jpg|</noinclude>right|Caption text<noinclude>]]</noinclude>
155 This is a simple paragraph.
157 <p>This is a simple paragraph.
162 Paragraphs with extra newline spacing
185 Paragraphs with newline spacing with comment lines in between
193 <!--foo--><!--More than 1 comment disables stripping of this line!-->
250 Paragraphs with newline spacing with non-empty white-space lines in between
277 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
285 <!--foo--><!--More than 1 comment disables stripping of this line!-->
324 Extra newlines: More paragraphs with indented comment
339 Extra newlines followed by heading
354 <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>
355 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
358 <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>
363 Extra newlines between heading and content are swallowed
371 <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>
372 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
379 http://fr.wikipedia.org/wiki/🍺
380 <!-- EasterEgg we love beer, better be able be able to link to it -->
382 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
402 * plain''italic''plain
403 * plain''italic''plain''italic''plain
404 * plain'''bold'''plain
405 * plain'''bold'''plain'''bold'''plain
406 * plain''italic''plain'''bold'''plain
407 * plain'''bold'''plain''italic''plain
408 * plain''italic'''bold-italic'''italic''plain
409 * plain'''bold''bold-italic''bold'''plain
410 * plain'''''bold-italic'''italic''plain
411 * plain'''''bold-italic''bold'''plain
412 * plain''italic'''bold-italic'''''plain
413 * plain'''bold''bold-italic'''''plain
414 * plain l'''italic''plain
415 * plain l''''bold''' plain
418 </li><li> plain<i>italic</i>plain
419 </li><li> plain<i>italic</i>plain<i>italic</i>plain
420 </li><li> plain<b>bold</b>plain
421 </li><li> plain<b>bold</b>plain<b>bold</b>plain
422 </li><li> plain<i>italic</i>plain<b>bold</b>plain
423 </li><li> plain<b>bold</b>plain<i>italic</i>plain
424 </li><li> plain<i>italic<b>bold-italic</b>italic</i>plain
425 </li><li> plain<b>bold<i>bold-italic</i>bold</b>plain
426 </li><li> plain<i><b>bold-italic</b>italic</i>plain
427 </li><li> plain<b><i>bold-italic</i>bold</b>plain
428 </li><li> plain<i>italic<b>bold-italic</b></i>plain
429 </li><li> plain<b>bold<i>bold-italic</i></b>plain
430 </li><li> plain l'<i>italic</i>plain
431 </li><li> plain l'<b>bold</b> plain
436 # this example taken from the simple/Moon article
438 Italics and possessives
440 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
442 <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
447 ### 2-quote opening sequence tests
450 Italics and bold: 2-quote opening sequence: (2,2)
460 Italics and bold: 2-quote opening sequence: (2,3)
470 Italics and bold: 2-quote opening sequence: (2,4)
480 Italics and bold: 2-quote opening sequence: (2,5) (php)
489 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
491 Italics and bold: 2-quote opening sequence: (2,5) (parsoid)
503 ### 3-quote opening sequence tests
507 Italics and bold: 3-quote opening sequence: (3,2)
517 Italics and bold: 3-quote opening sequence: (3,3)
527 Italics and bold: 3-quote opening sequence: (3,4)
537 Italics and bold: 3-quote opening sequence: (3,5) (php)
546 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
548 Italics and bold: 3-quote opening sequence: (3,5) (parsoid)
560 ### 4-quote opening sequence tests
564 Italics and bold: 4-quote opening sequence: (4,2)
574 Italics and bold: 4-quote opening sequence: (4,3)
584 Italics and bold: 4-quote opening sequence: (4,4)
594 Italics and bold: 4-quote opening sequence: (4,5) (php)
603 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
605 Italics and bold: 4-quote opening sequence: (4,5) (parsoid)
611 <p>'<b>foo<i></i></b>
617 ### 5-quote opening sequence tests
621 Italics and bold: 5-quote opening sequence: (5,2) (php)
630 # Parsoid reverses the nesting order, compared to the PHP parser
632 Italics and bold: 5-quote opening sequence: (5,2) (parsoid)
644 Italics and bold: 5-quote opening sequence: (5,3)
654 Italics and bold: 5-quote opening sequence: (5,4)
658 <p><i><b>foo'</b></i>
664 Italics and bold: 5-quote opening sequence: (5,5)
673 ### multiple quote sequences in a line
676 Italics and bold: multiple quote sequences: (2,4,2)
680 <p><i>foo'<b>bar</b></i>
686 Italics and bold: multiple quote sequences: (2,4,3)
690 <p><i>foo'<b>bar</b></i>
696 Italics and bold: multiple quote sequences: (2,4,4)
700 <p><i>foo'<b>bar'</b></i>
706 Italics and bold: multiple quote sequences: (3,4,2) (php)
715 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
717 Italics and bold: multiple quote sequences: (3,4,2) (parsoid)
723 <p><b>foo'</b>bar<i></i>
729 Italics and bold: multiple quote sequences: (3,4,3) (php)
738 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
740 Italics and bold: multiple quote sequences: (3,4,3) (parsoid)
746 <p><b>foo'</b>bar<b></b>
751 ### other quote tests
754 Italics and bold: other quote tests: (2,3,5)
756 ''this is about '''foo's family'''''
758 <p><i>this is about <b>foo's family</b></i>
764 Italics and bold: other quote tests: (2,(3,3),2)
766 ''this is about '''foo's''' family''
768 <p><i>this is about <b>foo's</b> family</i>
774 Italics and bold: other quote tests: (3,2,3,2)
776 '''this is about ''foo'''s family''
778 <p><b>this is about <i>foo</i></b><i>s family</i>
783 # The Parsoid team believes the PHP parser's output on this test is wrong.
784 # It only checks for convert-to-bold-on-single-character-word when the word
785 # matches with a bold tag ("'''") that is *odd* in the list of quote tokens.
786 # This means that the bold token in position 2 (0-indexed) gets converted by
787 # parsoid, but doesn't get changed by the PHP parser.
789 Italics and bold: other quote tests: (3,2,3,3) (php)
793 '''this is about ''foo'''s family'''
795 <p>'<i>this is about </i>foo<b>s family</b>
798 # This is the output the Parsoid team believes to be correct.
800 Italics and bold: other quote tests: (3,2,3,3) (parsoid)
804 '''this is about ''foo'''s family'''
806 <p><b>this is about <i>foo'</i>s family</b>
812 Italics and bold: other quote tests: (3,(2,2),3)
814 '''this is about ''foo's'' family'''
816 <p><b>this is about <i>foo's</i> family</b>
822 Italicized possessive
824 The ''[[Main Page]]'''s talk page.
826 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
831 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
832 (Requires tidy for PHP parser output to be fixed up)
834 parsoid=wt2html,wt2wt
842 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
843 <td><i>a</i></td><td><i>b</i></td></tr>
852 Non-html5 tags should be accepted
854 <center>''foo''</center>
857 <strike>''foo''</strike>
860 <center><i>foo</i></center>
861 <p><big><i>foo</i></big>
862 <font><i>foo</i></font>
863 <strike><i>foo</i></strike>
869 <wbr> is valid wikitext (bug 52468)
877 # <strike> is HTML4, <s> is HTML4/5.
879 <s> or <strike> for strikethrough
881 <strike>strike</strike>
885 <p><strike>strike</strike>
891 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
893 <b→> doesn't work! </b>
895 <bä> doesn't work! </b>
897 <boo> works fine </b>
905 <p><b→> doesn't work! </b>
906 </p><p><bä> doesn't work! </b>
907 </p><p><boo> works fine </b>
908 </p><p><s.foo>foo</s>
909 </p><p><s.foo>s.foo</s.foo>
910 </p><p><sub-ID#1>
915 ### Special characters
919 Bare pipe character (bug 52363)
928 Bare pipe character from a template (bug 52363)
937 ### <nowiki> test cases
941 <nowiki> unordered list
943 <nowiki>* This is not an unordered list item.</nowiki>
945 <p>* This is not an unordered list item.
952 <nowiki>Lorem ipsum dolor
973 :There is not nowiki.
974 :There is <nowiki>nowiki</nowiki>.
976 #There is not nowiki.
977 #There is <nowiki>nowiki</nowiki>.
979 *There is not nowiki.
980 *There is <nowiki>nowiki</nowiki>.
982 <dl><dd>There is not nowiki.
983 </dd><dd>There is nowiki.
985 <ol><li>There is not nowiki.
986 </li><li>There is nowiki.
988 <ul><li>There is not nowiki.
989 </li><li>There is nowiki.
995 Entities inside <nowiki>
997 <nowiki><</nowiki>
1004 Entities inside template parameters
1010 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}'>–</span>
1018 Comments and Indent-Pre
1020 <!-- comment 1 --> asdf
1022 <!-- comment 1 --> asdf
1025 <!-- comment 1 --> asdf
1026 <!-- comment 2 -->xyz
1028 <!-- comment 1 --> asdf
1029 <!-- comment 2 --> xyz
1085 asdf<!-- comment 1 -->jkl
1095 <!-- foo --> b <!-- bar -->
1109 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1115 Comment semantics and delimiters
1117 <!-- --><!----><!-----><!------>
1123 Comment semantics and delimiters, redux
1125 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1126 -- foo -- funky huh? ... -->
1132 Comment semantics and delimiters: directors cut
1134 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1135 everything starting with < followed by !-- until the first -- and > we see,
1136 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1144 Comment semantics: nesting
1146 <!--<!-- no, we're not going to do anything fancy here -->-->
1153 Comment semantics: unclosed comment at end
1155 <!--This comment will run out to the end of the document
1161 Comment in template title
1170 Comment on its own line post-expand
1182 Comment on its own line post-expand with non-significant whitespace
1194 ### paragraph wrapping tests
1208 Block tag on one line
1220 Block tag on both lines
1232 Multiple lines without block tags
1250 Empty lines between lines with block tags
1280 ### Preformatted text
1289 And a [[Main Page|link]]
1295 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1300 Ident preformatting with inline content
1311 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1328 Regression with preformatted in <center>
1342 Bug 6200: Preformatted in <blockquote>
1356 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
1373 Bug 15491: <ins>/<del> in blockquote
1376 Foo <del>bar</del> <ins>baz</ins> quux
1380 <p>Foo <del>bar</del> <ins>baz</ins> quux
1386 # Note that the p-wrapping is newline sensitive, which could be
1387 # considered a bug: tidy will wrap only the 'Foo' in the example
1388 # below in a <p> tag. (see comment 23-25 of bug #6200)
1390 Bug 15491: <ins>/<del> in blockquote (2)
1392 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1395 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1401 <pre> with attributes (bug 3202)
1403 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1405 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1410 <pre> with width attribute (bug 3202)
1412 <pre width="8">Narrow screen goodies</pre>
1414 <pre width="8">Narrow screen goodies</pre>
1419 <pre> with forbidden attribute (bug 3202)
1421 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1423 <pre width="8">Narrow screen goodies</pre>
1428 Entities inside <pre>
1437 <pre> with forbidden attribute values (bug 3202)
1439 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1441 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1446 <nowiki> inside <pre> (bug 13238)
1454 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1462 <pre><nowiki>Foo</nowiki></pre>
1467 <nowiki> and <pre> preference (first one wins)
1498 </pre> inside nowiki
1500 <nowiki></pre></nowiki>
1507 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1515 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1525 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1537 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1558 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1562 {{echo| foo}}{{echo| bar}}
1567 {{echo|<!--cmt--> foo}}
1569 <!--cmt-->{{echo| foo}}
1571 {{echo|{{echo| }}bar}}
1589 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1626 Templates: Single-line variant of parameter whitespace stripping test
1632 {{echo|{{echo| a}}}}
1634 {{echo|1={{echo| a}}}}
1647 Templates: Strip whitespace from named parameters, but not positional ones
1675 Templates: Dont strip whitespace from whitespace/comment-only arguments
1679 {{echo| <!--cmt--> }}
1686 Templates: Parsoid parameter escaping test 1
1690 {{echo|[foo]|{{echo|[bar]}}}}
1692 <p about="#mwt1" typeof="mw:Transclusion"
1693 data-mw="{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}">[foo]</p>
1697 Parsoid: Pipes in external links in template parameter
1701 {{echo|[{{echo|http://example.com}} link]}}
1703 <p><a rel="mw:ExtLink" href="http://example.com" about="#mwt31" typeof="mw:Transclusion" data-mw="{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[{{echo|http://example.com}} link]"}},"i":0}">link</a></p>
1707 Parsoid: pipe in transclusion parameter
1711 {{echo|http://foo.com/a|b}}
1713 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
1714 typeof="mw:Transclusion"
1715 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://foo.com/a|b"}},"i":0}'>http://foo.com/a|b</a></p>
1719 Parsoid: Pipe in external link target and content in template parameter
1721 parsoid=html2wt,wt2wt
1723 {{echo|[http://foo.com/a|b a|b]}}
1725 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
1726 typeof="mw:Transclusion"
1727 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},
1728 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}'>a|b</a></p>
1732 Templates: Dont escape already nowiki-escaped text in template parameters
1734 parsoid=html2wt,wt2wt
1736 {{echo|foo<nowiki>|</nowiki>bar}}
1737 {{echo|<nowiki><div></nowiki>}}
1738 {{echo|<nowiki></nowiki>}}
1740 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"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>
1741 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt2" data-mw='{"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>
1742 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt3" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki></nowiki>"}},"i":0}'></span>
1747 ### Parsoid-centric tests for testing RT edge cases for pre
1751 1a. Indent-Pre and Comments
1764 1b. Indent-Pre and Comments
1777 1c. Indent-Pre and Comments
1790 2a. Indent-Pre and tables
1811 2b. Indent-Pre and tables
1827 2c. Indent-Pre and tables (bug 42252)
1844 3a. Indent-Pre and block tags (single-line html)
1852 <pre><span> foo </span>
1857 3b. Indent-Pre and block tags (pre-content on separate line)
1910 4. Multiple spaces at start-of-line
1929 5. White-space in indent-pre
1930 NOTE: the white-space char on 2nd line is significant
1943 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
1947 HTML-pre: 1. embedded newlines
1983 HTML-pre: 2: indented text
1996 HTML-pre: 3: other wikitext
2017 ### Definition lists
2024 <dl><dt> name </dt><dd> Definition
2030 Definition list for indentation only
2034 <dl><dd> Indented text
2040 Definition list with no space
2044 <dl><dt>name</dt><dd>Definition
2050 Definition list with URL link
2052 ; http://example.com/ : definition
2054 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt><dd> definition
2060 Definition list with bracketed URL link
2062 ;[http://www.example.com/ Example]:Something about it
2064 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt><dd>Something about it
2070 Definition list with wikilink containing colon
2072 ; [[Help:FAQ]]: The least-read page on Wikipedia
2074 <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><dd> The least-read page on Wikipedia
2079 # At Brion's and JeLuF's insistence... :)
2081 Definition list with news link containing colon
2083 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
2085 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt><dd> This isn't even a real newsgroup!
2091 Malformed definition list with colon
2093 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
2095 <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
2101 Definition lists: colon in external link text
2103 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
2105 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt><dd> OK, I made that up
2111 Definition lists: colon in HTML attribute
2113 ;<b style="display: inline">bold</b>
2115 <dl><dt><b style="display: inline">bold</b>
2121 Definition lists: self-closed tag
2123 ;one<br/>two : two-line fun
2125 <dl><dt>one<br />two </dt><dd> two-line fun
2131 Bug 11748: Literal closing tags
2135 <dd>test test test test test</dd>
2137 <dd>test test test test test</dd>
2142 <dd>test test test test test</dd>
2144 <dd>test test test test test</dd>
2150 Definition and unordered list using wiki syntax nested in unordered list using html tags.
2153 ; term : description
2159 <dl><dt> term </dt><dd> description
2170 Definition list with empty definition and following paragraph
2175 <dl><dt> term</dt><dd>
2182 Nested definition lists using html syntax
2199 Definition Lists: No nesting: Multiple dd's
2213 Definition Lists: Indentation: Regular
2229 Definition Lists: Indentation: Missing 1st level
2243 Definition Lists: Indentation: Multi-level indent
2247 <dl><dd><dl><dd><dl><dd>i3
2255 Definition Lists: Hacky use to indent tables
2262 should be left alone
2264 <dl><dd><dl><dd><table>
2269 </td></tr></table></dd></dl></dd></dl>
2271 should be left alone
2274 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
2275 ## as an empty dt item. It also ignores all but the last ";" when followed
2276 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
2277 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
2280 ## Ex: ";;t2 ::d2" is transformed into:
2292 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
2293 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
2304 ## All Parsoid only definition list tests have this difference.
2306 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
2307 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
2310 Table / list interaction: indented table with lists in table contents
2332 </td></tr></table></dd></dl>
2337 Table / list interaction: lists nested in tables nested in indented lists
2362 </td></tr></table></dd></dl>
2370 Definition Lists: Nesting: Multi-level (Parsoid only)
2400 Definition Lists: Nesting: Test 2 (Parsoid only)
2420 Definition Lists: Nesting: Test 3 (Parsoid only)
2448 Definition Lists: Nesting: Test 4
2453 <dl><dd><dl><dd><dl><dt>t3
2462 ## The Parsoid team believes the following three test exposes a
2463 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
2464 ## wrong to close the <dl> after the <dt> containing the <ul>.)
2466 Definition Lists: Mixed Lists: Test 1 (php)
2474 <dl><dd><dl><dt><ul><li> foo
2484 Definition Lists: Mixed Lists: Test 1 (parsoid)
2492 <dl><dd><dl><dt><ul><li> foo
2493 </li></ul></dt><dd><ul><li> bar
2494 </li></ul></dd><dt> baz</dt></dl></dd></dl>
2498 Definition Lists: Mixed Lists: Test 2
2512 Definition Lists: Mixed Lists: Test 3
2517 <ul><li><dl><dd><dl><dd><dl><dd> d1
2528 Definition Lists: Mixed Lists: Test 4
2533 <ul><li><dl><dt>d1 </dt><dd>d2
2534 </dd><dt>d3 </dt><dd>d4
2542 Definition Lists: Mixed Lists: Test 5
2557 Definition Lists: Mixed Lists: Test 6
2562 <ol><li><ul><li><dl><dd>d1
2574 Definition Lists: Mixed Lists: Test 7
2588 Definition Lists: Mixed Lists: Test 8
2604 Definition Lists: Mixed Lists: Test 9
2608 <ul><li><dl><dt>foo </dt><dd>bar
2616 Definition Lists: Mixed Lists: Test 10
2620 <ul><li><ol><li><dl><dt>foo </dt><dd>bar
2627 # The Parsoid team disagrees with the PHP parser's seemingly-random
2628 # rules regarding dd/dt on the next two tests. Parsoid is more
2629 # consistent, and recognizes the shared nesting and keeps the
2630 # still-open tags around until the nesting is complete.
2633 Definition Lists: Mixed Lists: Test 11 (php)
2640 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt><dd><ul><li><dl><dt><dl><dt>bar
2645 <dl><dt>boo </dt><dd>baz
2654 Definition Lists: Mixed Lists: Test 11 (parsoid)
2676 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2677 <dd data-parsoid='{"stx":"row"}'>bar</dd></dl></dt></dl></li></ul></dt>
2678 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2679 <dd data-parsoid='{"stx":"row"}'>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
2684 Definition Lists: Weird Ones: Test 1 (php)
2688 *#;*::;; foo : bar (who uses this?)
2690 <ul><li><ol><li><dl><dt> foo </dt><dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)
2702 Definition Lists: Weird Ones: Test 1 (parsoid)
2706 *#;*::;; foo : bar (who uses this?)
2723 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2724 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd></dl></dt></dl></dd></dl></dd></dl></li></ul></dt></dl></li></ol></li></ul>
2731 External links: non-bracketed
2733 Non-bracketed: http://example.com
2735 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2740 External links: numbered
2742 Numbered: [http://example.com]
2743 Numbered: [http://example.net]
2744 Numbered: [http://example.com]
2746 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
2747 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
2748 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
2753 External links: specified text
2755 Specified text: [http://example.com link]
2757 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
2762 External links: trail
2764 Linktrails should not work for external links: [http://example.com link]s
2766 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
2771 External links: dollar sign in URL
2773 http://example.com/1$2345
2775 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
2780 External links: dollar sign in URL (named)
2782 [http://example.com/1$2345]
2784 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
2789 External links: open square bracket forbidden in URL (bug 4377)
2791 http://example.com/1[2345
2793 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
2798 External links: open square bracket forbidden in URL (named) (bug 4377)
2800 [http://example.com/1[2345]
2802 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
2807 External links: nowiki in URL link text (bug 6230)
2809 [http://example.com/ <nowiki>''example site''</nowiki>]
2811 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
2816 External links: newline forbidden in text (bug 6230 regression check)
2818 [http://example.com/ first
2821 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
2827 External links: Pipe char between url and text
2829 [http://example.com | link]
2831 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
2836 External links: protocol-relative URL in brackets
2838 [//example.com/ Test]
2840 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
2845 External links: protocol-relative URL in brackets without text
2849 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
2854 External links: protocol-relative URL in free text is left alone
2858 <p>//example.com/Foo
2863 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
2865 foo//example.com/Foo
2867 <p>foo//example.com/Foo
2874 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2876 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2881 External image from https
2883 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2885 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2890 External image (when not allowed)
2892 wgAllowExternalImages=0
2894 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2896 <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>
2901 Link to non-http image, no img tag
2903 Link to non-http image, no img tag: ftp://example.com/test.jpg
2905 <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>
2910 External links: terminating separator
2912 Terminating separator: http://example.com/thing,
2914 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
2919 External links: intervening separator
2921 Intervening separator: http://example.com/1,2,3
2923 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
2928 External links: old bug with URL in query
2930 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
2932 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
2937 External links: old URL-in-URL bug, mixed protocols
2939 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
2941 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
2946 External links: URL in text
2948 URL in text: [http://example.com http://example.com]
2950 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2955 External links: Clickable images
2957 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
2959 <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>
2964 External links: raw ampersand
2966 Old & use: http://x&y
2968 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
2973 External links: encoded ampersand
2975 Old & use: http://x&y
2977 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
2982 External links: encoded equals (bug 6102)
2984 http://example.com/?foo=bar
2986 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
2991 External links: [raw ampersand]
2993 Old & use: [http://x&y]
2995 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3000 External links: [encoded ampersand]
3002 Old & use: [http://x&y]
3004 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3009 External links: [encoded equals] (bug 6102)
3011 [http://example.com/?foo=bar]
3013 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3018 External links: [IDN ignored character reference in hostname; strip it right off]
3020 [http://e‌xample.com/]
3022 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
3026 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
3027 # Where an external link could easily circumvent the sanitization of the text of
3028 # a link like this (where an IDN-ignore character is in the URL somewhere), this
3029 # test demands a higher standard. That's a bit strange.
3033 # http://example.com -> [http://example.com|http://example.com]
3034 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
3036 # The first example is sanitized, but the second is not. Any security benefits
3037 # from this production are trivial to circumvent. Either remove this test and
3038 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
3039 # the test accordingly.
3044 External links: IDN ignored character reference in hostname; strip it right off
3046 http://e‌xample.com/
3048 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
3053 External links: www.jpeg.org (bug 554)
3057 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
3062 External links: URL within URL (original bug 2)
3064 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
3066 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
3071 BUG 361: URL inside bracketed URL
3073 [http://www.example.com/foo http://www.example.com/bar]
3075 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
3080 BUG 361: URL within URL, not bracketed
3082 http://www.example.com/foo?=http://www.example.com/bar
3084 <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>
3089 BUG 289: ">"-token in URL-tail
3091 http://www.example.com/<hello>
3093 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
3098 BUG 289: literal ">"-token in URL-tail
3100 http://www.example.com/<b>html</b>
3102 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
3107 BUG 289: ">"-token in bracketed URL
3109 [http://www.example.com/<hello> stuff]
3111 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
3116 BUG 289: literal ">"-token in bracketed URL
3118 [http://www.example.com/<b>html</b> stuff]
3120 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
3125 BUG 289: literal double quote at end of URL
3127 http://www.example.com/"hello"
3129 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
3134 BUG 289: literal double quote in bracketed URL
3136 [http://www.example.com/"hello" stuff]
3138 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
3143 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
3145 [http://www.example.com test]
3147 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
3152 External links: link text with spaces
3154 [http://www.example.com a b c]
3155 [http://www.example.com ''a'' ''b'']
3157 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
3158 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
3163 External links: wiki links within external link (Bug 3695)
3165 [http://example.com [[wikilink]] embedded in ext link]
3167 <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>
3172 BUG 787: Links with one slash after the url protocol are invalid
3176 [http:/example.com title]
3178 <p>http:/example.com
3179 </p><p>[http:/example.com title]
3184 Bracketed external links with template-generated invalid target
3186 [{{echo|http:/example.com}} title]
3188 <p>[http:/example.com title]
3193 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
3195 ''[http://example.com text'']
3196 [http://example.com '''text]'''
3197 ''Something [http://example.com in italic'']
3198 ''Something [http://example.com mixed''''', even bold]'''
3199 '''''Now [http://example.com both''''']
3201 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
3202 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
3203 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
3204 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
3205 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
3211 Bug 4781: %26 in URL
3213 http://www.example.com/?title=AT%26T
3215 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
3219 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
3220 # % is actually legal in HTML5. Any change in output would need testing though.
3222 Bug 4781, 5267: %25 in URL
3224 http://www.example.com/?title=100%25_Bran
3226 <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>
3231 Bug 4781, 5267: %28, %29 in URL
3233 http://www.example.com/?title=Ben-Hur_%281959_film%29
3235 <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>
3241 Bug 4781: %26 in autonumber URL
3243 [http://www.example.com/?title=AT%26T]
3245 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
3250 Bug 4781, 5267: %26 in autonumber URL
3252 [http://www.example.com/?title=100%25_Bran]
3254 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
3259 Bug 4781, 5267: %28, %29 in autonumber URL
3261 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
3263 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
3269 Bug 4781: %26 in bracketed URL
3271 [http://www.example.com/?title=AT%26T link]
3273 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
3278 Bug 4781, 5267: %26 in bracketed URL
3280 [http://www.example.com/?title=100%25_Bran link]
3282 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
3287 Bug 4781, 5267: %28, %29 in bracketed URL
3289 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
3291 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
3296 External link containing double-single-quotes in text '' (bug 4598 sanity check)
3298 Some [http://example.com/ pretty ''italics'' and stuff]!
3300 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
3305 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
3307 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
3309 <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>
3314 External link containing double-single-quotes with no space separating the url from text in italics
3316 [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]].]
3318 <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>
3323 External link with comments in link text
3325 [http://www.google.com Google <!-- comment -->]
3327 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
3332 URL-encoding in URL functions (single parameter)
3334 {{localurl:Some page|amp=&}}
3336 <p>/index.php?title=Some_page&amp=&
3341 URL-encoding in URL functions (multiple parameters)
3343 {{localurl:Some page|q=?&=&}}
3345 <p>/index.php?title=Some_page&q=?&amp=&
3352 http://example.com/index.php?foozoid%5B%5D=bar
3354 http://example.com/index.php?foozoid[]=bar
3356 <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>
3357 </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>
3362 IPv6 urls (bug 21261)
3366 http://[2404:130:0:1000::187:2]/index.php
3368 <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>
3373 Non-extlinks in brackets
3382 [{{echo|foo}} ''bar'']
3383 [{{echo|foo}}l's] errand
3384 [{{echo|foo}}l's errand]
3386 [url=http://example.com]
3399 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
3404 Parsoid: Percent encoding in external links
3408 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
3410 <p><a rel="mw:ExtLink"
3411 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
3415 Parsoid: use url link syntax for links where the content is equal the link
3422 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
3432 Normal text. '''Bold text.''' Normal text. ''Italic text.''
3434 Normal text. '''''Bold italic text.''''' Normal text.
3436 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
3437 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
3443 Unclosed and unmatched quotes (php)
3447 '''''Bold italic text '''with bold deactivated''' in between.'''''
3449 '''''Bold italic text ''with italic deactivated'' in between.'''''
3453 ..spanning two paragraphs (should not work).'''
3455 '''Bold tag left open
3457 ''Italic tag left open
3461 <!-- Unmatching number of opening, closing tags: -->
3462 '''This year''''s election ''should'' beat '''last year''''s.
3464 ''Tom'''s car is bigger than ''Susan'''s.
3466 Plain ''italic'''s plain
3468 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3469 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
3470 </p><p><b>Bold text..</b>
3471 </p><p>..spanning two paragraphs (should not work).
3472 </p><p><b>Bold tag left open</b>
3473 </p><p><i>Italic tag left open</i>
3475 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3476 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3477 </p><p>Plain <i>italic'</i>s plain
3480 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
3481 # parser strips. The wikitext contains just the first half of the bold
3482 # quote pair. (There's also a case where Parsoid nests <b> and <i>
3483 # differently than the PHP parser.)
3485 Unclosed and unmatched quotes (parsoid)
3489 '''''Bold italic text '''with bold deactivated''' in between.'''''
3491 '''''Bold italic text ''with italic deactivated'' in between.'''''
3495 ..spanning two paragraphs (should not work).'''
3497 '''Bold tag left open
3499 ''Italic tag left open
3503 <!-- Unmatching number of opening, closing tags: -->
3504 '''This year''''s election ''should'' beat '''last year''''s.
3506 ''Tom'''s car is bigger than ''Susan'''s.
3508 Plain ''italic'''s plain
3510 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3511 </p><p><i><b>Bold italic text </b></i><b>with italic deactivated<i> in between.</i></b>
3512 </p><p><b>Bold text..</b>
3513 </p><p>..spanning two paragraphs (should not work).<b></b>
3514 </p><p><b>Bold tag left open</b>
3515 </p><p><i>Italic tag left open</i>
3517 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3518 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3519 </p><p>Plain <i>italic'</i>s plain
3526 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
3529 # This should not produce <table></table> as <table><tr><td></td></tr></table>
3530 # is the bare minimum required by the spec, see:
3531 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
3533 A table with no data. (php)
3540 # Parsoid team replies: empty table tags are legal in HTML5
3542 A table with no data. (parsoid)
3551 # A table with nothing but a caption is invalid XHTML, we might want to render
3552 # this as <p>caption</p>
3554 A table with nothing but a caption (php)
3564 </caption><tr><td></td></tr></table>
3567 # Parsoid team replies: table with only a caption is legal in HTML5
3569 A table with nothing but a caption (parsoid)
3577 <table><caption> caption</caption></table>
3581 A table with caption with default-spaced attributes and a table row
3584 |+ style="color: red;" | caption1
3590 <caption style="color: red;"> caption1
3599 A table with captions with non-default spaced attributes and a table row
3602 |+style="color: red;"|caption2
3603 |+ style="color: red;"| caption3
3609 <caption style="color: red;">caption2
3611 <caption style="color: red;"> caption3
3620 Table td-cell syntax variations
3624 | foo bar foo || baz
3625 | style='color:red;' | baz
3626 | style='color:red;' || baz
3633 <td> foo bar foo </td>
3636 <td style="color:red;"> baz
3638 <td> style='color:red;' </td>
3666 Simple table but with multiple dashes for row wikitext
3684 Multiplication table
3686 {| border="1" cellpadding="2"
3687 |+Multiplication table
3689 ! × !! 1 !! 2 !! 3
3707 <table border="1" cellpadding="2">
3708 <caption>Multiplication table
3755 Accept "||" in table headings
3770 Accept "||" in indented table headings
3780 </th></tr></table></dd></dl>
3785 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
3802 Accept "| !" at start of line in tables (ignore !-attribute)
3806 | !style="color:red" | bar
3818 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 +/-
3822 |style='color:red;'|+1
3823 |style='color:blue;'|-1
3835 <td style="color:red;">+1
3837 <td style="color:blue;">-1
3861 |rowspan=2| Cell 2, row 1 (and 2)
3872 <td rowspan="2"> Cell 2, row 1 (and 2)
3890 {| bgcolor=#ABCDEF border=2
3895 |the original table again
3903 <table bgcolor="#ABCDEF" border="2">
3911 <td>the original table again
3917 Invalid attributes in table cell (bug 1830)
3932 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
3935 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
3939 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
3940 <td>]" onmouseover="alert(document.cookie)">test
3949 Indented table markup mixed with indented pre content (proposed in bug 6200)
3954 Text that should be rendered preformatted
3962 <pre>Text that should be rendered preformatted
3971 Template-generated table cell attributes and cell content
3979 <td style="color: red"> Foo
3985 Template-generated table cell attributes and cell content (2)
3988 |align=center {{table_attribs}}
3993 <td align="center" style="color: red"> Foo
3999 Template-generated table cell attributes and cell content (3)
4002 |align=center {{table_cells}}
4007 <td align="center" style="color: red"> Foo </td>
4015 Table with row followed by newlines and table heading
4033 Table with empty line following the start tag
4050 # FIXME: Preserve the attribute properly (with an empty string as value) in
4051 # the PHP parser. Parsoid implements the behavior below.
4053 Table attributes with empty value
4065 </td></tr></tbody></table>
4070 Wikitext table with a lot of comments
4093 Wikitext table with double-line table cell
4110 Table cell with a single comment
4126 # The expected HTML structure in this test is debatable. The PHP parser does
4127 # not parse this kind of table at all. The main focus for Parsoid is on
4128 # round-tripping, so this output is ok for now. TODO: revisit!
4130 Wikitext table with html-syntax row (Parsoid)
4142 <td>foo</td></tr></tbody></table>
4146 Implicit <td> after a |-
4147 (PHP parser relies on Tidy to add the missing <td> tags)
4149 parsoid=wt2html,wt2wt
4162 Pres should be recognized in an explicit <td> context, but not in an implicit <td> context
4163 (PHP parser relies on Tidy to add the missing <td> tags)
4165 parsoid=wt2html,wt2wt
4177 <tr><td><pre>a</pre></td></tr>
4178 <tr><td> b</td></tr>
4184 Lists should be recognized in an implicit <td> context
4185 (PHP parser relies on Tidy to add the missing <td> tags)
4187 parsoid=wt2html,wt2wt
4196 <td><ul><li>a</li></ul></td>
4205 Plain link, capitalized
4209 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
4214 Plain link, uncapitalized
4218 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
4225 [[Main Page|The Main Page]]
4227 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
4232 Piped link with comment in link text
4234 [[Main Page|The Main<!--front--> Page]]
4236 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
4245 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
4250 Broken link with fragment
4252 [[Zigzagzogzagzig#zug]]
4254 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
4259 Special page link with fragment
4261 [[Special:Version#anchor]]
4263 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
4268 Nonexistent special page link with fragment
4270 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
4272 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
4279 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
4281 <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>
4288 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
4290 <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>!!!
4301 Bug 43661: Piped links with identical prefixes
4303 [[prefixed article|prefixed articles with spaces]]
4305 [[prefixed article|prefixed articlesaoeu]]
4307 [[Main Page|Main Page test]]
4309 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
4310 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
4311 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
4317 Link with HTML entity in suffix / tail
4319 [[Main Page]]", [[Main Page]]a
4321 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
4326 Link with 3 brackets
4335 Piped link with 3 brackets
4337 [[[main page|the main page]]]
4339 <p>[[[main page|the main page]]]
4344 Link with multiple pipes
4346 [[Main Page|The|Main|Page]]
4348 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
4355 [[Talk:Parser testing]], [[Meta:Disclaimers]]
4357 <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>
4362 Piped link to namespace
4364 [[Meta:Disclaimers|The disclaimers]]
4366 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
4373 [[Usually caused by a typo (oops}]]
4375 <p>[[Usually caused by a typo (oops}]]
4380 Link containing % (not as a hex sequence)
4384 <p><a href="/index.php?title=7%25_Solution&action=edit&redlink=1" class="new" title="7% Solution (page does not exist)">7% Solution</a>
4389 Link containing % as a single hex sequence interpreted to char
4393 <p><a href="/index.php?title=7%25_Solution&action=edit&redlink=1" class="new" title="7% Solution (page does not exist)">7% Solution</a>
4398 Link containing % as a double hex sequence interpreted to hex sequence
4402 <p>[[7%2525 Solution]]
4407 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
4408 Example for such a section: == < ==
4410 [[%23%3c]][[%23%3e]]
4412 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
4417 Link containing "<#" and ">#" as a hex sequences
4419 [[%3c%23]][[%3e%23]]
4421 <p>[[%3c%23]][[%3e%23]]
4426 Link containing an equals sign
4428 [[Special:BookSources/isbn=4-00-026157-6]]
4430 <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>
4437 Just a test of an article title containing a tilde.
4440 # note that links containing signatures, like [[Foo~~~~]], are
4441 # massaged by the pre-save transform (PST) and so the tildes are never
4442 # seen by the parser.
4444 Link containing a tilde
4448 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
4453 Link containing double-single-quotes '' (bug 4598)
4455 [[Lista d''e paise d''o munno]]
4457 <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>
4462 Link containing double-single-quotes '' in text (bug 4598 sanity check)
4464 Some [[Link|pretty ''italics'' and stuff]]!
4466 <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>!
4471 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
4473 ''Some [[Link|pretty ''italics'' and stuff]]!
4475 <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>
4480 Link with double quotes in title part (literal) and alternate part (interpreted)
4482 [[File:Denys Savchenko ''Pentecoste''.jpg]]
4486 [[''Pentecoste''|Pentecoste]]
4488 [[''Pentecoste''|''Pentecoste'']]
4490 <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>
4491 </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>
4492 </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>
4493 </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>
4498 Broken image links with HTML captions (bug 39700)
4500 [[File:Nonexistent|<script></script>]]
4501 [[File:Nonexistent|100px|<script></script>]]
4502 [[File:Nonexistent|<]]
4503 [[File:Nonexistent|a<i>b</i>c]]
4505 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
4506 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
4507 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
4508 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
4515 [[http://www.example.com]]
4517 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
4522 Plain link to URL with link text
4524 [[http://www.example.com Link text]]
4526 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
4531 Plain link to protocol-relative URL
4533 [[//www.example.com]]
4535 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
4540 Plain link to protocol-relative URL with link text
4542 [[//www.example.com Link text]]
4544 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
4549 Plain link to page with question mark in title
4555 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
4556 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
4561 # I'm fairly sure the expected result here is wrong.
4562 # We want these to be URL links, not pseudo-pages with URLs for titles....
4563 # However the current output is also pretty screwy.
4566 # I'm changing it to match the current output--it arguably makes more
4567 # sense in the light of the test above. Old expected result was:
4568 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
4570 # But I think this test is bordering on "garbage in, garbage out" anyway.
4575 Piped link to URL: [[http://www.example.com|an example URL]]
4577 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
4582 BUG 2: [[page|http://url/]] should link to page, not http://url/
4584 [[Main Page|http://url/]]
4586 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
4591 BUG 337: Escaped self-links should be bold
4595 [[Bug462]] [[Bug462]]
4597 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
4602 Self-link to section should not be bold
4606 [[Main Page#section]]
4608 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
4619 Self-link to numeric title
4625 <p><strong class="selflink">0</strong>
4630 Link to numeric-equivalent title
4636 <p><a href="/wiki/00" title="00">00</a>
4641 <nowiki> inside a link
4643 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
4645 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
4650 Non-breaking spaces in title
4652 [[ Main Page ]]
4654 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
4659 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
4665 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
4670 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
4676 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
4681 Internal link with en linktrail: no apostrophes (bug 27473)
4687 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
4692 Internal link with ca linktrail with apostrophes (bug 27473)
4698 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
4703 Internal link with kaa linktrail with apostrophes (bug 27473)
4709 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
4720 Internal link with is link prefix
4724 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
4726 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
4737 Internal link with is link trail and link prefix
4741 [[mótmælendatrú|xxx]]ar
4743 mótmælenda[[söfnuður]]
4744 mótmælenda[[söfnuður|söfnuðir]]
4745 mótmælenda[[söfnuður|söfnuðir]]xxx
4747 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
4748 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
4749 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
4750 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
4751 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
4756 Parsoid link trail escaping
4758 parsoid=html2wt,html2html
4762 <p><a rel="mw:WikiLink" href="Apple">apple</a>s</p>
4766 Parsoid link prefix escaping
4769 parsoid=html2wt,html2html
4771 Aðrir mótmælenda<nowiki/>[[söfnuður]]
4773 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður">söfnuður</a></p>
4777 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
4785 [http://wp.org ''foo'']
4787 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
4788 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
4789 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
4790 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
4795 ### Interwiki links (see maintenance/interwiki.sql)
4799 Inline interwiki link
4801 [[MeatBall:SoftSecurity]]
4803 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
4808 Inline interwiki link with empty title (bug 2372)
4812 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
4817 Interwiki link encoding conversion (bug 1636)
4819 *[[Wikipedia:ro:Olteniţa]]
4820 *[[Wikipedia:ro:Olteniţa]]
4822 <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>
4823 </li><li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a>
4829 Interwiki link with fragment (bug 2130)
4831 [[MeatBall:SoftSecurity#foo]]
4833 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
4848 Double interlanguage link
4859 Interlanguage link, with prefix links
4871 Double interlanguage link, with prefix links (bug 8897)
4884 Parsoid-specific test: Wikilinks with should RT properly
4890 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
4895 Parsoid: handle constructor well
4903 <p data-parsoid="{"dsr":[0,15,0,0]}"><a rel="mw:WikiLink" href="./Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"},"dsr":[0,15,2,2]}">constructor</a></p>
4906 <p data-parsoid="{"dsr":[17,36,0,0]}"><a rel="mw:WikiLink" href="./Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"},"dsr":[17,36,2,2]}">constructor:foo</a></p>
4910 ## Redirects, Parsoid-only
4913 Simple redirect to page
4917 #REDIRECT [[Main Page]]
4919 <link rel="mw:PageProp/redirect" href="./Main_Page">
4923 Redirect to category
4927 #REDIRECT [[Category:Foo]]
4929 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:WikiLink/Category" href="./Category:Foo">
4933 Redirect to category page
4935 parsoid=wt2html,html2html
4937 #REDIRECT [[:Category:Foo]]
4939 <p><a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a></p>
4943 Redirect to image page
4947 #REDIRECT [[File:Wiki.png]]
4949 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
4953 Redirect to language
4957 #REDIRECT [[en:File:Wiki.png]]
4959 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
4963 Redirect to interwiki
4967 #REDIRECT [[meatball:File:Wiki.png]]
4969 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
4986 Broken br tag sanitization
4996 # TODO: Fix html2html mode (bug 51055)!
4998 Parsoid: Broken br tag recognition
5008 Incorrecly removing closing slashes from correctly formed XHTML
5010 <br style="clear:both;" />
5012 <p><br style="clear:both;" />
5017 Failing to transform badly formed HTML into correct XHTML
5019 <br style="clear: left;">
5020 <br style="clear: right;">
5021 <br style="clear: both;">
5023 <p><br style="clear: left;" />
5024 <br style="clear: right;" />
5025 <br style="clear: both;" />
5030 Handling html with a div self-closing tag
5039 <p><div title />
5043 <p><div title=bar />
5044 <div title=bar/>
5046 <div title="bar/"></div>
5052 Handling html with a br self-closing tag
5061 <p><br title="title" />
5062 <br title="title" />
5071 Horizontal ruler (should it add that extra space?)
5085 Horizontal ruler -- 4+ dashes render hr
5094 Horizontal ruler -- eats additional dashes on the same line
5103 Horizontal ruler -- does not collapse dashes on consecutive lines
5114 Horizontal ruler -- <4 dashes render as plain text
5123 Horizontal ruler -- Supports content following dashes on same line
5132 ### Block-level elements
5155 <ol><li>Numbered list
5172 ***#Number on level 4
5174 **#Number on level 3
5175 **#Number on level 3
5179 #** Level 3, but ordered
5182 <ol><li> with numbers
5184 <ul><li> and bullets
5186 <ol><li> and numbers
5188 </li><li>bullets again
5189 <ul><li>bullet level 2
5190 <ul><li>bullet level 3
5191 <ol><li>Number on level 4
5194 </li><li>bullet level 2
5195 <ol><li>Number on level 3
5196 </li><li>Number on level 3
5199 <ol><li>number level 2
5202 <ul><li><ul><li> Level 3
5206 <ol><li><ul><li><ul><li> Level 3, but ordered
5240 Nested lists 3 (first element empty)
5253 Nested lists 4 (first element empty)
5266 Nested lists 5 (both elements empty)
5279 Nested lists 6 (both elements empty)
5292 Nested lists 7 (skip initial nesting levels)
5296 <ul><li><ul><li><ul><li> foo
5304 Nested lists 8 (multiple nesting transitions)
5312 <ul><li><ul><li> bar
5322 1. Lists with start-of-line-transparent tokens before bullets: Comments
5336 2. Lists with start-of-line-transparent tokens before bullets: Template close
5348 List items are not parsed correctly following a <pre> block (bug 785)
5354 <ul><li> <pre>foo</pre>
5355 </li><li> <pre>bar</pre>
5362 List items from template
5373 * notSOL{{inner list}}
5392 List interrupted by empty line or heading
5402 <ul><li><ul><li> bar
5405 <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>
5406 <ul><li> Another list item
5412 Multiple list tags generated by templates
5427 Single-comment whitespace lines dont break lists, but multi-comment whitespace lines do
5430 <!--This line will NOT split the list-->
5432 <!--This line will NOT split the list either-->
5434 <!--foo--> <!--This line with more than 1 comment will split the list-->
5448 (Cannot test this with PHP parser since it relies on Tidy for the hack)
5450 parsoid=wt2html,wt2wt
5454 * {{echo|<li>templated li-hack}}
5455 * <!--foo--> <li> unsupported li-hack with preceding comments
5458 <li><li>not a li-hack
5464 <li about="#mwt1" typeof="mw:Transclusion" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<li>templated li-hack"}}}'>templated li-hack</li>
5465 <li> <!--foo--> </li><li> li-hack with preceding comments</li></ul>
5468 <li></li><li>not a li-hack
5474 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
5485 <ol><li> foo<ol><li> bar</li></ol></li></ol><ul><li> foo<ul><li> bar</li></ul></li></ul><dl><dd> foo<dl><dd> bar</dd></dl></dd></dl>
5488 # ------------------------------------------------------------------------
5489 # The next set of tests are about Parsoid's ability to handle badly nested
5490 # tags (parse, minimize scope of fixup, and roundtrip back)
5491 # ------------------------------------------------------------------------
5494 Unbalanced closing block tags break a list
5495 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5505 </li></ul></div><div>
5511 Unbalanced closing non-block tags don't break a list
5512 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5522 <ul><li>a<span></span>
5528 Unclosed formatting tags that straddle lists are closed and reopened
5529 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5537 </li><li> <s> b </s>
5542 List embedded in a non-block tag
5543 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
5551 <p><small></small></p>
5557 <p><small></small></p>
5565 Magic Word: {{CURRENTDAY}}
5574 Magic Word: {{CURRENTDAY2}}
5583 Magic Word: {{CURRENTDAYNAME}}
5592 Magic Word: {{CURRENTDOW}}
5601 Magic Word: {{CURRENTMONTH}}
5610 Magic Word: {{CURRENTMONTHABBREV}}
5612 {{CURRENTMONTHABBREV}}
5619 Magic Word: {{CURRENTMONTHNAME}}
5621 {{CURRENTMONTHNAME}}
5628 Magic Word: {{CURRENTMONTHNAMEGEN}}
5630 {{CURRENTMONTHNAMEGEN}}
5637 Magic Word: {{CURRENTTIME}}
5646 Magic Word: {{CURRENTWEEK}} (@bug 4594)
5655 Magic Word: {{CURRENTYEAR}}
5664 Magic Word: {{FULLPAGENAME}}
5666 title=[[User:Ævar Arnfjörð Bjarmason]]
5670 <p>User:Ævar Arnfjörð Bjarmason
5675 Magic Word: {{FULLPAGENAMEE}}
5677 title=[[User:Ævar Arnfjörð Bjarmason]]
5681 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
5686 Magic Word: {{NAMESPACE}}
5688 title=[[User:Ævar Arnfjörð Bjarmason]]
5697 Magic Word: {{NAMESPACEE}}
5699 title=[[User:Ævar Arnfjörð Bjarmason]]
5708 Magic Word: {{NAMESPACENUMBER}}
5710 title=[[User:Ævar Arnfjörð Bjarmason]]
5719 Magic Word: {{NUMBEROFFILES}}
5728 Magic Word: {{PAGENAME}}
5730 title=[[User:Ævar Arnfjörð Bjarmason]]
5734 <p>Ævar Arnfjörð Bjarmason
5739 Magic Word: {{PAGENAME}} with metacharacters
5741 title=[['foo & bar = baz']]
5745 <p><i>'foo & bar = baz'</i>
5750 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
5752 title=[[*RFC 1234 http://example.com/]]
5756 <p>*RFC 1234 http://example.com/
5761 Magic Word: {{PAGENAMEE}}
5763 title=[[User:Ævar Arnfjörð Bjarmason]]
5767 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
5772 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
5774 title=[[*RFC 1234 http://example.com/]]
5778 <p>*RFC_1234_http://example.com/
5783 Magic Word: {{REVISIONID}}
5792 Magic Word: {{SCRIPTPATH}}
5801 Magic Word: {{SERVER}}
5805 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
5810 Magic Word: {{SERVERNAME}}
5819 Magic Word: {{SITENAME}}
5828 Case-sensitive magic words, when cased differently, should just be template transclusions
5835 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
5836 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
5837 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
5838 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
5843 Case-insensitive magic words should still work with weird casing.
5853 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
5858 Namespace 1 {{ns:1}}
5867 Namespace 1 {{ns:01}}
5876 Namespace 0 {{ns:0}} (bug 4783)
5884 Namespace 0 {{ns:00}} (bug 4783)
5892 Namespace -1 {{ns:-1}}
5901 Namespace User {{ns:User}}
5910 Namespace User talk {{ns:User_talk}}
5919 Namespace User talk {{ns:uSeR tAlK}}
5928 Namespace File {{ns:File}}
5937 Namespace File {{ns:Image}}
5946 Namespace (lang=de) Benutzer {{ns:User}}
5957 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
5963 <p>Benutzer Diskussion
5971 {{urlencode:hi world?!}}
5972 {{urlencode:hi world?!|WIKI}}
5973 {{urlencode:hi world?!|PATH}}
5974 {{urlencode:hi world?!|QUERY}}
5987 Magic links: internal link to RFC (bug 479)
5991 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
5996 Magic links: RFC (bug 479)
6000 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
6005 Magic links: ISBN (bug 1937)
6009 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
6014 Magic links: PMID incorrectly converts space to underscore
6018 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
6027 Nonexistent template
6029 {{thistemplatedoesnotexist}}
6031 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
6036 Template with invalid target containing tags
6038 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
6040 <p>{{a<b>b</b>|foo|a=b|a = b}}
6045 Template with invalid target containing unclosed tag
6047 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
6049 <p>{{a<b>|foo|a=b|a = b}}</b>
6056 This is a test template
6064 <p>This is a test template
6069 Template with explicit namespace
6073 <p>This is a test template
6081 This is a test template with parameter {{{param}}}
6087 {{paramtest|param=foo}}
6089 <p>This is a test template with parameter foo
6094 Template:paramtestnum
6100 Template unnamed parameter
6102 {{paramtestnum|Main Page|the main page}}
6104 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
6109 Template:templatesimple
6115 Template:templateredirect
6117 #redirect [[Template:templatesimple]]
6121 Template:templateasargtestnum
6127 Template:templateasargtest
6129 {{template{{{templ}}}}}
6133 Template:templateasargtest2
6139 Template with template name as unnamed argument
6141 {{templateasargtestnum|templatesimple}}
6148 Template with template name as argument
6150 {{templateasargtest|templ=simple}}
6157 Template with template name as argument (2)
6159 {{templateasargtest2|templ=templatesimple}}
6166 Template:templateasargtestdefault
6168 {{{{{templ|templatesimple}}}}}
6178 Template with default value
6180 {{templateasargtestdefault}}
6187 Template with default value (value set)
6189 {{templateasargtestdefault|templ=templa}}
6198 {{templateredirect}}
6205 Template with argument in separate line
6207 {{ templateasargtest |
6215 Template with complex template as argument
6218 param ={{ templateasargtest |
6221 <p>This is a test template with parameter (test)
6226 Template with thumb image (with link in description)
6229 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
6231 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>
6236 Template:complextemplate
6238 {{{1}}} {{paramtest|
6239 param ={{{param}}}}}
6243 Template with complex arguments
6246 param ={{ templateasargtest |
6247 templ = simple }}|[[Template:complextemplate|link]]}}
6249 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
6254 BUG 553: link with two variables in a piped link
6257 |[[{{{1}}}|{{{2}}}]]
6262 <td>[[{{{1}}}|{{{2}}}]]
6268 Magic variable as template parameter
6270 {{paramtest|param={{SITENAME}}}}
6272 <p>This is a test template with parameter MediaWiki
6279 [[{{{param}}}|link]]
6283 Template parameter as link source
6285 {{linktest|param=Main Page}}
6287 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
6292 Template-generated attribute string (k='v')
6294 <span {{attr_str|id|v1}}>bar</span>
6296 <p><span id="v1">bar</span>
6303 including another template, {{paramtest|param={{{arg}}}}}
6307 Template passing argument to another template
6309 {{paramtest2|arg='hmm'}}
6311 <p>including another template, This is a test template with parameter 'hmm'
6322 Template as link source
6326 [[{{linktest2}}|Main Page]]
6328 [[{{linktest2}}]]Page
6330 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6331 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6332 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
6350 Template infinite loop
6354 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
6359 Template from main namespace
6378 BUG 529: Template with table, not included at beginning of line
6397 BUG 523: Template shouldn't eat newline (or add an extra one before table)
6417 BUG 41: Template parameters shown as broken links
6426 Template with targets containing wikilinks
6430 {{[[{{echo|foo}}]]}}
6432 {{{{echo|[[foo}}]]}}
6434 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
6435 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
6443 ''None'' of '''this''' should be
6445 but rather passed unmodified
6449 # hmm, fix this or just deprecate msgnw and document its behavior?
6455 {{msgnw:MSGNW test}}
6457 <p>''None'' of '''this''' should be
6459 but rather passed unmodified
6467 {{int:youhavenewmessages|lots of money|not!}}
6469 <p>You have lots of money (not!).
6476 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
6480 <includeonly> and <noinclude> being included
6491 <onlyinclude>Foo</onlyinclude>bar
6495 <onlyinclude> being included
6507 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
6511 <onlyinclude> and <includeonly> being included
6520 <includeonly> and <noinclude> on a page
6522 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
6529 Un-closed <noinclude>
6536 <onlyinclude> on a page
6538 <onlyinclude>Foo</onlyinclude>bar
6545 Un-closed <onlyinclude>
6552 Self-closed noinclude, includeonly, onlyinclude tags
6563 Unbalanced includeonly and noinclude tags
6567 |b</noinclude></noinclude>
6568 |c</noinclude></includeonly>
6569 |d</includeonly></includeonly>
6578 <td>c</includeonly>
6580 <td>d</includeonly></includeonly>
6586 Template:Includeonly section
6589 ==Includeonly section==
6595 Bug 6563: Edit link generation for section shown by <includeonly>
6597 {{includeonly section}}
6599 <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>
6600 <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>
6604 # Uses same input as the contents of [[Template:Includeonly section]]
6606 Bug 6563: Section extraction for section shown by <includeonly>
6611 ==Includeonly section==
6619 Bug 6563: Edit link generation for section suppressed by <includeonly>
6622 ==Includeonly section==
6626 <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>
6631 Bug 6563: Section extraction for section suppressed by <includeonly>
6636 ==Includeonly section==
6644 Un-closed <includeonly>
6650 # TODO: test with DOM fragment reuse!
6652 Parsoid: DOM fragment reuse
6654 parsoid=wt2wt,wt2html
6656 a{{echo|b<table></table>c}}d
6668 a<span typeof="mw:Transclusion">b</span>
6669 <table></table><span>c</span>d
6670 <p typeof="mw:Transclusion">ab</p>
6673 <p typeof="mw:Transclusion">a</p>
6679 ### <includeonly> and <noinclude> in attributes
6682 0. includeonly around the entire attribute
6684 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
6686 <p><span id="v2">bar</span>
6691 1. includeonly in html attr key
6693 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
6695 <p><span id="foo">bar</span>
6700 2. includeonly in html attr value
6702 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
6703 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
6705 <p><span id="v1">bar</span>
6706 <span id="v1">bar</span>
6711 3. includeonly in part of an attr value
6713 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
6715 <p><span style="color:red;">bar</span>
6720 ### Testing parsing of templates where a template arg
6721 ### has the same name as the template itself.
6731 Templates: Template Name/Arg clash: 1. Use of positional param
6740 Templates: Template Name/Arg clash: 2. Use of named param
6749 Templates: Template Name/Arg clash: 3. Use of named param with empty input
6758 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
6762 Templates: 1. Simple use
6771 Templates: 2. Inside a block tag
6773 <div>{{echo|Foo}}</div>
6780 Templates: P-wrapping: 1a. Templates on consecutive lines
6791 Templates: P-wrapping: 1b. Templates on consecutive lines
6805 Templates: P-wrapping: 1c. Templates on consecutive lines
6808 {{echo|bar}} <div>baz</div>
6817 Templates: P-wrapping: 1d. Template preceded by comment-only line
6819 parsoid=wt2html,wt2wt
6825 <p typeof="mw:Transclusion">Bar
6830 Templates: Inline Text: 1. Multiple tmeplate uses
6832 {{echo|Foo}}bar{{echo|baz}}
6839 Templates: Inline Text: 2. Back-to-back template uses
6841 {{echo|Foo}}{{echo|bar}}
6848 Templates: Block Tags: 1. Multiple template uses
6850 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
6852 <div>Foo</div><div>bar</div><div>baz</div>
6857 Templates: Block Tags: 2. Back-to-back template uses
6859 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
6861 <div>Foo</div><div>bar</div>
6866 Templates: Links: 1. Simple example
6868 {{echo|[[Foo|bar]]}}
6870 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6875 Templates: Links: 2. Generation of link href
6877 [[{{echo|Foo}}|bar]]
6879 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6884 Templates: Links: 3. Generation of part of a link href
6886 [[Fo{{echo|o}}|bar]]
6890 [[Foo{{echo|bar}}baz]]
6892 [[Foo{{echo|bar}}|bar]]
6894 [[:Foo{{echo|bar}}]]
6896 [[:Foo{{echo|bar}}|bar]]
6898 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6899 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
6900 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
6901 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
6902 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
6903 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
6908 Templates: Links: 4. Multiple templates generating link href
6910 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
6912 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
6917 Templates: Links: 5. Generation of link text
6919 [[Foo|{{echo|bar}}]]
6921 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6926 Templates: Links: 5. Nested templates (only outermost template should be marked)
6928 {{echo|[[{{echo|Foo}}|bar]]}}
6930 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6935 Templates: HTML Tag: 1. Generation of HTML attr. key
6937 <div {{echo|style}}="color:red;">foo</div>
6939 <div style="color:red;">foo</div>
6944 Templates: HTML Tag: 2. Generation of HTML attr. value
6946 <div style={{echo|'color:red;'}}>foo</div>
6948 <div style="color:red;">foo</div>
6953 Templates: HTML Tag: 3. Generation of HTML attr key and value
6955 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
6957 <div style="color:red;">foo</div>
6962 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
6964 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
6966 <div title="This is a long title with just one piece templated">foo</div>
6971 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
6973 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
6975 <div title="This is a long title with just one piece templated">foo</div>
6980 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
6982 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
6984 <div title="This is a long title with just one piece templated">foo</div>
6989 Templates: HTML Tag: 7. Generation of partial attribute key string
6991 <div st{{echo|yle}}="color:red;">foo</div>
6993 <div style="color:red;">foo</div>
6998 Templates: HTML Tables: 1. Generating start of a HTML table
7000 {{echo|<table><tr><td>foo</td>}}</tr></table>
7002 <table><tr><td>foo</td></tr></table>
7007 Templates: HTML Tables: 2a. Generating middle of a HTML table
7009 <table><tr>{{echo|<td>foo</td>}}</tr></table>
7011 <table><tr><td>foo</td></tr></table>
7016 Templates: HTML Tables: 2b. Generating middle of a HTML table
7018 <table>{{echo|<tr><td>foo</td></tr>}}</table>
7020 <table><tr><td>foo</td></tr></table>
7025 Templates: HTML Tables: 3. Generating end of a HTML table
7027 <table><tr>{{echo|<td>foo</td></tr></table>}}
7029 <table><tr><td>foo</td></tr></table>
7034 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
7036 {{echo|<table>}}<tr><td>foo</td></tr></table>
7038 <table><tr><td>foo</td></tr></table>
7043 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
7045 <table>{{echo|<tr>}}<td>foo</td></tr></table>
7047 <table><tr><td>foo</td></tr></table>
7052 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
7054 <table><tr>{{echo|<td>}}foo</td></tr></table>
7056 <table><tr><td>foo</td></tr></table>
7061 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
7063 <table><tr><td>foo{{echo|</td>}}</tr></table>
7065 <table><tr><td>foo</td></tr></table>
7070 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
7072 <table><tr><td>foo</td>{{echo|</tr>}}</table>
7074 <table><tr><td>foo</td></tr></table>
7079 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
7081 <table><tr><td>foo</td></tr>{{echo|</table>}}
7083 <table><tr><td>foo</td></tr></table>
7088 Templates: HTML Tables: 5. Proper fostering of categories from inside
7090 parsoid=wt2html,wt2wt
7092 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
7093 <!--Two categories (Bug 50330)-->
7094 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
7096 <link rel="mw:WikiLink/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
7097 <!--Two categories (Bug 50330)-->
7098 <link rel="mw:WikiLink/Category" href="./Category:Bar1"><link rel="mw:WikiLink/Category" href="./Category:Bar2"><table><tbody><tr><td>foo</td></tr></tbody></table>
7102 Templates: Wiki Tables: 1a. Fostering of entire template content
7110 <tr><td></td></tr></table>
7115 Templates: Wiki Tables: 1b. Fostering of entire template content
7128 <tr><td></td></tr></table>
7133 Templates: Wiki Tables: 2. Fostering of partial template content
7143 <tr><td></td></tr></table>
7148 Templates: Wiki Tables: 3. td-content via multiple templates
7151 {{echo|{{pipe}}a}}{{echo|b}}
7162 Templates: Wiki Tables: 4. Templated tags, no content
7168 <tr><td></td></tr></table>
7173 Templates: Wiki Tables: 5. Templated tags, regular td-tags
7187 Templates: Wiki Tables: 6. Templated tags, templated td-tags
7201 Templates: Lists: Multi-line list-items via templates
7203 *{{echo|a {{nonexistent|
7205 *{{echo|b {{nonexistent|
7208 <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>
7209 </li><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>
7215 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
7217 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
7219 <p><i>ab</i>c<i>d</i>e
7224 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
7225 (PHP parser generates misnested html)
7227 parsoid=wt2html,wt2wt
7229 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
7231 <p><span typeof="mw:Transclusion"><i>a</i></span><i typeof="mw:Transclusion"><span>b</span></i><span>c</span><i>d</i><span>e</span></p>
7235 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
7236 (PHP parser generates misnested html)
7238 parsoid=wt2html,wt2wt
7240 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
7242 <div typeof="mw:Transclusion"><i>a</i></div>
7243 <div typeof="mw:Transclusion"><i>b</i>c<i>d</i></div>
7244 <div typeof="mw:Transclusion">e</div>
7248 Templates: Ugly nesting: 4. Divs opened/closed across templates
7250 a<div>b{{echo|c</div>d}}e
7257 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
7263 |{{echo|foo</table>}}
7267 <table typeof="mw:Transclusion">
7270 <td>foo</td></tr></tbody></table><span>bar</span>
7274 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
7284 <td>1. {{echo|foo </table>}}</td>
7286 <td>2. {{echo|baz </table>}}</td>
7299 <table about="#mwt1" typeof="mw:Transclusion">
7304 <td >1. foo </td></tr></tbody></table></td>
7306 <td >2. baz </td></tr></tbody></table><span about="#mwt1">
7307 </span><span about="#mwt1">
7309 abc</span><span about="#mwt1">
7310 </span><span about="#mwt1">
7311 </span><span about="#mwt1">
7312 </span><span about="#mwt1">
7313 </span><span about="#mwt1">
7315 xyz</span><span about="#mwt1">
7316 </span><span about="#mwt1">
7321 Templates: Ugly templates: 3. newline-only template parameter
7330 # This looks like a bug: a single newline triggers p/br for some reason.
7332 Templates: Ugly templates: 4. newline-only template parameter inconsistency
7343 Parser Functions: 1. Simple example
7352 Parser Functions: 2. Nested use (only outermost should be marked up)
7361 ### Pre-save transform tests
7364 pre-save transform: subst:
7370 This is a test template
7374 pre-save transform: normal template
7384 pre-save transform: nonexistent template
7388 {{thistemplatedoesnotexist}}
7390 {{thistemplatedoesnotexist}}
7395 pre-save transform: subst magic variables
7404 # This is bug 89, which I fixed. -- wtm
7406 pre-save transform: subst: templates with parameters
7410 {{subst:paramtest|param="something else"}}
7412 This is a test template with parameter "something else"
7418 <nowiki>'''not wiki'''</nowiki>
7422 pre-save transform: nowiki in subst (bug 1188)
7426 {{subst:nowikitest}}
7428 <nowiki>'''not wiki'''</nowiki>
7433 Template:commenttest
7435 This template has <!-- a comment --> in it.
7439 pre-save transform: comment in subst (bug 1936)
7443 {{subst:commenttest}}
7445 This template has <!-- a comment --> in it.
7449 pre-save transform: unclosed tag
7453 <nowiki>'''not wiki'''
7455 <nowiki>'''not wiki'''
7459 pre-save transform: mixed tag case
7463 <NOwiki>'''not wiki'''</noWIKI>
7465 <NOwiki>'''not wiki'''</noWIKI>
7469 pre-save transform: unclosed comment in <nowiki>
7473 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
7475 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
7478 # Leading @ in this template definition works around a limitation
7479 # in parsoid's parserTests which otherwise strips the <span> from the
7480 # result (confusing it for a template wrapper)
7484 @<span onmouseover="alert('crap')">Oh no</span>
7488 (confirming safety of fix for subst bug 1936)
7490 {{Template:dangerous}}
7492 <p>@<span>Oh no</span>
7497 pre-save transform: comment containing gallery (bug 5024)
7501 <!-- <gallery>data</gallery> -->
7503 <!-- <gallery>data</gallery> -->
7507 pre-save transform: comment containing extension
7511 <!-- <tag>data</tag> -->
7513 <!-- <tag>data</tag> -->
7517 pre-save transform: comment containing nowiki
7521 <!-- <nowiki>data</nowiki> -->
7523 <!-- <nowiki>data</nowiki> -->
7527 pre-save transform: <noinclude> in subst (bug 3298)
7537 pre-save transform: <onlyinclude> in subst (bug 3298)
7549 {{<includeonly>subst:</includeonly>Includes}}
7553 Template:SafeSubstTest
7555 {{<includeonly>safesubst:</includeonly>Includes}}
7559 bug 22297: safesubst: works during PST
7563 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
7569 bug 22297: safesubst: works during normal parse
7578 subst: does not work during normal parse
7582 <p>{{subst:Includes}}
7587 pre-save transform: context links ("pipe trick")
7591 [[Article (context)|]]
7594 [[Bar:Article (context)|]]
7595 [[:Bar:Article (context)|]]
7597 [[|Article (context)]]
7601 [[Article (context)|Article]]
7602 [[Bar:Article|Article]]
7603 [[:Bar:Article|Article]]
7604 [[Bar:Article (context)|Article]]
7605 [[:Bar:Article (context)|Article]]
7607 [[Article (context)]]
7608 [[Bar:X (Y) Z|X (Y) Z]]
7609 [[:Bar:X (Y) Z|X (Y) Z]]
7613 pre-save transform: context links ("pipe trick") with interwiki prefix
7617 [[interwiki:Article|]]
7618 [[:interwiki:Article|]]
7619 [[interwiki:Bar:Article|]]
7620 [[:interwiki:Bar:Article|]]
7622 [[interwiki:Article|Article]]
7623 [[:interwiki:Article|Article]]
7624 [[interwiki:Bar:Article|Bar:Article]]
7625 [[:interwiki:Bar:Article|Bar:Article]]
7629 pre-save transform: context links ("pipe trick") with parens in title
7631 pst title=[[Somearticle (context)]]
7635 [[Article (context)|Article]]
7639 pre-save transform: context links ("pipe trick") with comma in title
7641 pst title=[[Someplace, Somewhere]]
7644 [[Otherplace, Elsewhere|]]
7645 [[Otherplace, Elsewhere, Anywhere|]]
7647 [[Otherplace, Somewhere|Otherplace]]
7648 [[Otherplace, Elsewhere|Otherplace]]
7649 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
7653 pre-save transform: context links ("pipe trick") with parens and comma
7655 pst title=[[Someplace (IGNORED), Somewhere]]
7658 [[Otherplace (place), Elsewhere|]]
7660 [[Otherplace, Somewhere|Otherplace]]
7661 [[Otherplace (place), Elsewhere|Otherplace]]
7665 pre-save transform: context links ("pipe trick") with comma and parens
7667 pst title=[[Who, me? (context)]]
7670 [[Me, Myself, and I (1937 song)|]]
7672 [[Yes, you. (context)|Yes, you.]]
7673 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
7677 pre-save transform: context links ("pipe trick") with namespace
7679 pst title=[[Ns:Somearticle]]
7683 [[Ns:Article|Article]]
7687 pre-save transform: context links ("pipe trick") with namespace and parens
7689 pst title=[[Ns:Somearticle (context)]]
7693 [[Ns:Article (context)|Article]]
7697 pre-save transform: context links ("pipe trick") with namespace and comma
7699 pst title=[[Ns:Somearticle, Context, Whatever]]
7703 [[Ns:Article, Context, Whatever|Article]]
7707 pre-save transform: context links ("pipe trick") with namespace, comma and parens
7709 pst title=[[Ns:Somearticle, Context (context)]]
7713 [[Ns:Article (context)|Article]]
7717 pre-save transform: context links ("pipe trick") with namespace, parens and comma
7719 pst title=[[Ns:Somearticle (IGNORED), Context]]
7723 [[Ns:Article, Context|Article]]
7727 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
7731 [[Article(context)|]]
7732 [[Bar:Article(context)|]]
7733 [[:Bar:Article(context)|]]
7734 [[|Article(context)]]
7738 [[Article(context)|Article]]
7739 [[Bar:Article(context)|Article]]
7740 [[:Bar:Article(context)|Article]]
7741 [[Article(context)]]
7743 [[:Bar:X(Y)Z|X(Y)Z]]
7747 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
7751 [[Article (context)|]]
7752 [[Bar:Article (context)|]]
7753 [[:Bar:Article (context)|]]
7754 [[|Article (context)]]
7758 [[Article (context)|Article]]
7759 [[Bar:Article (context)|Article]]
7760 [[:Bar:Article (context)|Article]]
7761 [[Article (context)]]
7762 [[Bar:X (Y) Z|X (Y) Z]]
7763 [[:Bar:X (Y) Z|X (Y) Z]]
7767 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
7771 [[Article(context)|]]
7772 [[Bar:Article(context)|]]
7773 [[:Bar:Article(context)|]]
7774 [[|Article(context)]]
7778 [[Article(context)|Article]]
7779 [[Bar:Article(context)|Article]]
7780 [[:Bar:Article(context)|Article]]
7781 [[Article(context)]]
7783 [[:Bar:X(Y)Z|X(Y)Z]]
7787 pre-save transform: context links ("pipe trick") with commas (bug 21660)
7791 [[Article (context), context|]]
7792 [[Article (context),context|]]
7793 [[Bar:Article (context), context|]]
7794 [[Bar:Article (context),context|]]
7795 [[:Bar:Article (context), context|]]
7796 [[:Bar:Article (context),context|]]
7798 [[Article (context), context|Article]]
7799 [[Article (context),context|Article]]
7800 [[Bar:Article (context), context|Article]]
7801 [[Bar:Article (context),context|Article]]
7802 [[:Bar:Article (context), context|Article]]
7803 [[:Bar:Article (context),context|Article]]
7807 pre-save transform: trim trailing empty lines
7811 Empty lines are trimmed
7817 Empty lines are trimmed
7821 pre-save transform: Signature expansion
7826 * <noinclude>~~~</noinclude>
7827 * <includeonly>~~~</includeonly>
7828 * <onlyinclude>~~~</onlyinclude>
7830 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
7831 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
7832 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
7833 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
7838 pre-save transform: Signature expansion in nowiki tags (bug 93)
7844 <nowiki>~~~~</nowiki>
7846 <includeonly><nowiki>~~~~</nowiki></includeonly>
7848 <noinclude><nowiki>~~~~</nowiki></noinclude>
7850 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
7852 {{subst:Foo}} shall be converted to FOO
7854 As well as inside noinclude/onlyinclude
7855 <noinclude>{{subst:Foo}}</noinclude>
7856 <onlyinclude>{{subst:Foo}}</onlyinclude>
7858 But not inside includeonly
7859 <includeonly>{{subst:Foo}}</includeonly>
7863 <nowiki>~~~~</nowiki>
7865 <includeonly><nowiki>~~~~</nowiki></includeonly>
7867 <noinclude><nowiki>~~~~</nowiki></noinclude>
7869 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
7871 FOO shall be converted to FOO
7873 As well as inside noinclude/onlyinclude
7874 <noinclude>FOO</noinclude>
7875 <onlyinclude>FOO</onlyinclude>
7877 But not inside includeonly
7878 <includeonly>{{subst:Foo}}</includeonly>
7882 Parsoid: Recognize nowiki with trailing space in tags
7886 <nowiki ><div>[[foo]]</nowiki >
7894 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
7901 Parsoid: Recognize nowiki with odd capitalization
7905 <noWikI ><div>[[foo]]</Nowiki >
7907 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
7912 Parsoid: Escape nowiki with trailing space in tags
7916 <nowiki > foo </nowiki >
7922 <p><nowiki > foo </nowiki ></p>
7923 <p>a<nowiki />b</p>
7924 <p>c<nowiki/ >d</p>
7928 Parsoid: Escape weird noWikI capitalizations
7932 <noWikI > foo </NoWikI >
7934 <p><noWikI > foo </NoWikI ></p>
7938 ### Message transform tests
7941 message transform: magic variables
7951 message transform: should not transform wiki markup
7961 message transform: <noinclude> in transcluded template (bug 4926)
7971 message transform: <onlyinclude> in transcluded template (bug 4926)
7981 {{#special:}} page name, known
7985 {{#special:Recentchanges}}
7987 Special:RecentChanges
7991 {{#special:}} page name with subpage, known
7995 {{#special:Recentchanges/param}}
7997 Special:RecentChanges/param
8001 {{#special:}} page name, unknown
8005 {{#special:foobar nonexistent}}
8007 Special:Foobar nonexistent
8011 {{#speciale:}} page name, known
8015 {{#speciale:Recentchanges}}
8017 Special:RecentChanges
8021 {{#speciale:}} page name with subpage, known
8025 {{#speciale:Recentchanges/param}}
8027 Special:RecentChanges/param
8031 {{#speciale:}} page name, unknown
8035 {{#speciale:foobar nonexistent}}
8037 Special:Foobar_nonexistent
8046 [[Image:foobar.jpg]]
8048 <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>
8055 [[Image:foobar.jpg|right]]
8057 <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>
8062 Simple image (using File: namespace, now canonical)
8066 <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>
8073 [[Image:foobar.jpg|right|Caption text]]
8075 <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>
8080 Image with empty attribute
8082 [[Image:foobar.jpg|right||Caption text]]
8084 <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>
8089 Image with attributes from template.
8091 [[Image:foobar.jpg|{{image_attribs}}]]
8093 <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>
8098 Image with link tails
8100 123[[Image:foobar.jpg]]456
8101 123[[Image:foobar.jpg|right]]456
8102 123[[Image:foobar.jpg|thumb]]456
8104 <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
8106 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
8107 123<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>456
8112 Image with multiple captions -- only last one is accepted
8114 [[Image:foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
8116 <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>
8121 Image with width attribute at different positions
8123 [[Image:foobar.jpg|200px|right|Caption]]
8124 [[Image:foobar.jpg|right|200px|Caption]]
8125 [[Image:foobar.jpg|right|Caption|200px]]
8127 <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>
8128 <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>
8129 <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>
8134 Image with link parameter, wiki target
8136 [[Image:foobar.jpg|link=Target page]]
8138 <p><a href="/wiki/Target_page" title="Target page"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8143 Image with link parameter, URL target
8145 [[Image:foobar.jpg|link=http://example.com/]]
8147 <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>
8152 Image with link parameter, wgExternalLinkTarget
8154 [[Image:foobar.jpg|link=http://example.com/]]
8156 wgExternalLinkTarget='foobar'
8158 <p><a href="http://example.com/" target="foobar" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8163 Image with link parameter, wgNoFollowLinks set to false
8165 [[Image:foobar.jpg|link=http://example.com/]]
8167 wgNoFollowLinks=false
8169 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8174 Image with link parameter, wgNoFollowDomainExceptions
8176 [[Image:foobar.jpg|link=http://example.com/]]
8178 wgNoFollowDomainExceptions='example.com'
8180 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8185 Image with link parameter, wgExternalLinkTarget, unnamed parameter
8187 [[Image:foobar.jpg|link=http://example.com/|Title]]
8189 wgExternalLinkTarget='foobar'
8191 <p><a href="http://example.com/" title="Title" target="foobar" rel="nofollow"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8196 Image with empty link parameter
8198 [[Image:foobar.jpg|link=]]
8200 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
8205 Image with link parameter (wiki target) and unnamed parameter
8207 [[Image:foobar.jpg|link=Target page|Title]]
8209 <p><a href="/wiki/Target_page" title="Title"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8214 Image with link parameter (URL target) and unnamed parameter
8216 [[Image:foobar.jpg|link=http://example.com/|Title]]
8218 <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>
8223 Thumbnail image with link parameter
8227 [[Image:foobar.jpg|thumb|link=http://example.com/|Title]]
8229 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="http://example.com/"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
8234 Manually-specified thumbnail image
8238 [[Image:Foobar.jpg|thumb=Thumb.png|Title]]
8240 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/File:Foobar.jpg"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
8245 Manually-specified thumbnail image with explicit link to wiki page
8249 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|Title]]
8251 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
8256 Manually-specified thumbnail image with explicit link to url
8260 [[Image:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
8262 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="http://example.com"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
8267 Manually-specified thumbnail image with explicit no link
8271 [[Image:Foobar.jpg|thumb=Thumb.png|link=|Title]]
8273 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
8278 Manually-specified thumbnail image with explicit link and alt text
8282 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|alt=alttext|Title]]
8284 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="alttext" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
8289 Image with frame and link
8291 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
8293 <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>
8298 Image with frame and link and explicit alt
8300 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
8302 <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>
8307 Image with wiki markup in implicit alt
8309 [[Image:Foobar.jpg|testing '''bold''' in alt]]
8311 <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>
8316 Image with wiki markup in explicit alt
8318 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
8320 <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>
8325 Link to image page- image page normally doesn't exists, hence edit link
8326 Add test with existing image page
8327 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
8331 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
8336 bug 18784 Link to non-existent image page with caption should use caption as link text
8338 [[:Image:test|caption]]
8340 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
8345 Frameless image caption with a free URL
8347 [[Image:foobar.jpg|http://example.com]]
8349 <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>
8354 Thumbnail image caption with a free URL
8356 [[Image:foobar.jpg|thumb|http://example.com]]
8358 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
8363 Thumbnail image caption with a free URL and explicit alt
8365 [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]]
8367 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
8372 SVG thumbnails with no language set
8375 [[File:Foobar.svg|thumb|width=200]]
8377 <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="180" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>width=200</div></div></div>
8382 SVG thumbnails with language de
8385 [[File:Foobar.svg|thumb|width=200|lang=de]]
8387 <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="180" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/langde-270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/langde-360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>width=200</div></div></div>
8392 SVG thumbnails with invalid language code
8395 [[File:Foobar.svg|thumb|width=200|lang=invalid.language.code]]
8397 <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="180" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>lang=invalid.language.code</div></div></div>
8402 BUG 1887: A ISBN with a thumbnail
8404 [[Image:foobar.jpg|thumb|ISBN 1235467890]]
8406 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div>
8411 BUG 1887: A RFC with a thumbnail
8413 [[Image:foobar.jpg|thumb|This is RFC 12354]]
8415 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
8420 BUG 1887: A mailto link with a thumbnail
8422 [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]]
8424 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a rel="nofollow" class="external free" href="mailto:nobody@example.com">mailto:nobody@example.com</a></div></div></div>
8428 # Pending resolution to bug 368
8430 BUG 648: Frameless image caption with a link
8432 [[Image:foobar.jpg|text with a [[link]] in it]]
8434 <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>
8439 BUG 648: Frameless image caption with a link (suffix)
8441 [[Image:foobar.jpg|text with a [[link]]foo in it]]
8443 <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>
8448 BUG 648: Frameless image caption with an interwiki link
8450 [[Image:foobar.jpg|text with a [[MeatBall:Link]] in it]]
8452 <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>
8457 BUG 648: Frameless image caption with a piped interwiki link
8459 [[Image:foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
8461 <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>
8466 Escape HTML special chars in image alt text
8468 [[Image:foobar.jpg|& < > "]]
8470 <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>
8475 BUG 499: Alt text should have Ӓ, not &1234;
8477 [[Image:foobar.jpg|♀]]
8479 <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>
8484 Broken image caption with link
8486 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
8488 <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.
8493 Image caption containing another image
8495 [[Image:Foobar.jpg|thumb|This is a caption with another [[Image:icon.png|image]] inside it!]]
8497 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is a caption with another <a href="/index.php?title=Special:Upload&wpDestFile=Icon.png" class="new" title="File:Icon.png">image</a> inside it!</div></div></div>
8502 Image caption containing a newline
8504 [[Image:Foobar.jpg|This
8507 <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>
8512 Parsoid: Image caption containing leading space
8513 (The leading space should not trigger nowiki escaping in wt2wt mode)
8515 [[Image:Foobar.jpg|thumb| bar]]
8517 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>bar</div></div></div>
8522 Bug 3090: External links other than http: in image captions
8524 [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
8526 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a rel="nofollow" class="external text" href="irc://example.net">irc</a> and <a rel="nofollow" class="external text" href="https://example.com">Secure</a> ext links in it.</div></div></div>
8533 [[Image:foobar.jpg|a|class=b]]
8535 <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>
8540 Localized image handling (1).
8544 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
8546 <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>
8551 Localized image handling (2).
8555 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
8557 <div class="thumb tleft"><div class="thumbinner" style="width:182px;"><a href="/wiki/Foo" title="Foo"><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/Archivo:Foobar.jpg" class="internal" title="Aumentar"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
8562 "border", "frameless" and "class" attributes on an image.
8564 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
8566 <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" class="extra thumbborder" 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>
8573 #REDIRECT [[File:Barfoo.jpg]]
8579 [[Image:Barfoo.jpg]]
8581 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
8586 Missing image with uploads disabled
8590 [[Image:Foobaz.jpg]]
8592 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
8596 # Parsoid-specific testing for images
8597 # http://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
8598 # Currently imperfect due to a flaw in the Parsoid testrunner
8602 Parsoid-specific image handling - simple image
8606 [[Image:Foobar.jpg]]
8609 <span class="mw-default-size" typeof="mw:Image">
8610 <a href="File:Foobar.jpg">
8611 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg" height="220" width="1941">
8618 Parsoid-specific image handling - simple image without link
8622 [[Image:Foobar.jpg|link=]]
8625 <span class="mw-default-size" typeof="mw:Image">
8627 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg" height="220" width="1941">
8634 Parsoid-specific image handling - simple image with specific link
8638 [[Image:Foobar.jpg|link=Main Page]]
8641 <span class="mw-default-size" typeof="mw:Image">
8642 <a href="Main_Page">
8643 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg" height="220" width="1941">
8650 Parsoid-specific image handling - simple image with size and middle alignment
8654 [[Image:Foobar.jpg|50px|middle]]
8657 <span class="mw-valign-middle" typeof="mw:Image">
8658 <a href="File:Foobar.jpg">
8659 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
8666 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
8670 [[Image:Foobar.jpg|500x10px|baseline|caption]]
8673 <span class="mw-valign-baseline" typeof="mw:Image" data-mw="{"caption":"caption"}">
8674 <a href="File:Foobar.jpg">
8675 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/89px-Foobar.jpg" height="10" width="89">
8682 Parsoid-specific image handling - simple image with border and size spec
8686 [[Image:Foobar.jpg|50px|border|caption]]
8689 <span class="mw-image-border" typeof="mw:Image" data-mw="{"caption":"caption"}">
8690 <a href="File:Foobar.jpg">
8691 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
8698 Parsoid-specific image handling - thumbnail with halign, valign, and caption
8702 [[Image:Foobar.jpg|thumb|left|baseline|caption content]]
8704 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb">
8705 <a href="File:Foobar.jpg">
8706 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/180px-Foobar.jpg" height="21" width="180" />
8708 <figcaption>caption content</figcaption>
8713 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
8717 [[Image:Foobar.jpg|thumb|50x50px|right|middle|caption]]
8719 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb">
8720 <a href="File:Foobar.jpg">
8721 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" />
8723 <figcaption>caption</figcaption>
8728 Parsoid-specific image handling - framed image with specific size and caption
8732 [[Image:Foobar.jpg|500x50px|frame|caption]]
8734 <figure typeof="mw:Image/Frame">
8735 <a href="File:Foobar.jpg">
8736 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
8738 <figcaption>caption</figcaption>
8743 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
8747 [[Image:Foobar.jpg|500x50px|frame|left|baseline|caption]]
8749 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame">
8750 <a href="File:Foobar.jpg">
8751 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
8753 <figcaption>caption</figcaption>
8758 Parsoid-specific image handling - frameless image with specific size, border, and caption
8762 [[Image:Foobar.jpg|frameless|500x50px|border|caption]]
8765 <span class="mw-image-border" typeof="mw:Image/Frameless" data-mw="{"caption":"caption"}">
8766 <a href="File:Foobar.jpg">
8767 <img resource="./File:Foobar.jpg" src="//upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
8773 #Parsoid-specific image handling - simple image with a formatted caption
8777 #[[Image:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
8780 #<span typeof="mw:Image">
8781 #<a class="mw-default-size" href="Image:Foobar.jpg">
8782 #<img alt="Foobar.jpg" class="mw-default-size" src="http://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg" height="220" width="1941">
8793 Subpage test/subpage
8801 subpage title=[[Subpage test]]
8805 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
8810 Subpage noslash link
8812 subpage title=[[Subpage test]]
8816 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
8820 # TODO: make this PHP-parser compatible!
8822 Relative subpage noslash link
8824 parsoid=wt2wt,wt2html,html2html
8825 subpage title=[[Subpage test/1/2/3/4]]
8831 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage/">subpage</a></p>
8832 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
8835 # TODO: make this PHP-parser compatible!
8837 Parsoid: dot-slash prefixed wikilinks
8839 parsoid=wt2wt,wt2html,html2html
8847 <p><a rel="mw:WikiLink" href="./Foo">foo</a></p>
8848 <p><a rel="mw:WikiLink" href="./Bar">bar</a></p>
8849 <p><a rel="mw:WikiLink" href="./Baz/">baz/</a></p>
8857 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
8862 BUG 561: {{/Subpage}}
8864 subpage title=[[Page]]
8868 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
8876 Category:MediaWiki User's Guide
8884 [[:Category:MediaWiki User's Guide]]
8886 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
8895 [[Category:MediaWiki User's Guide]]
8897 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
8901 PAGESINCATEGORY invalid title fatal (r33546 fix)
8903 {{PAGESINCATEGORY:<bogus>}}
8910 Category with different sort key
8914 [[Category:MediaWiki User's Guide|Foo]]
8916 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
8920 Category with identical sort key
8924 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
8926 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
8930 Category with empty sort key
8935 [[Category:MediaWiki User's Guide|]]
8937 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
8941 Category with empty sort key and parentheses
8946 [[Category:Foo (bar)|]]
8948 [[Category:Foo (bar)|Foo]]
8952 Category with link tail
8957 123[[Category:Foo]]456
8959 123[[Category:Foo]]456
8963 Category with template
8968 [[Category:{{echo|Foo}}]]
8970 [[Category:{{echo|Foo}}]]
8974 Category with template in sort key
8979 [[Category:Foo|{{echo|Bar}}]]
8981 [[Category:Foo|{{echo|Bar}}]]
8985 Category with template in sort key and title
8990 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
8992 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
8996 Category / paragraph interactions
8998 Foo [[Category:Baz]] Bar
9000 Foo [[Category:Baz]]
9008 [[Category:Baz]] Bar
9021 {{echo|[[Category:Baz]]}}
9036 Parsoid: Serialize link to category page with colon escape
9042 [[:Category:Foo|Bar]]
9045 <a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a>
9046 <a rel="mw:WikiLink" href="Category:Foo">Bar</a>
9051 Parsoid: Link prefix/suffixes aren't applied to category links
9053 parsoid=wt2html,wt2wt,html2html
9058 <p>x<link rel="mw:WikiLink/Category" href="Category:Foo">y</p>
9062 Parsoid: Serialize link to file page with colon escape
9068 [[:File:Foo.png|Bar]]
9071 <a rel="mw:WikiLink" href="File:Foo.png">File:Foo.png</a>
9072 <a rel="mw:WikiLink" href="File:Foo.png">Bar</a>
9077 Parsoid: Serialize a genuine category link without colon escape
9082 [[Category:Foo|Bar]]
9084 <link rel="mw:WikiLink/Category" href="Category:Foo">
9085 <link rel="mw:WikiLink/Category" href="Category:Foo#Bar">
9089 ### Inter-language links
9092 Inter-language links
9098 [[zh:食品]]
9100 es:Alimento fr:Nourriture zh:食品
9104 Duplicate interlanguage links (bug 24502)
9120 Basic section headings
9127 ===Smaller headline===
9130 <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>
9133 <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>
9136 <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>
9142 Section headings with TOC
9145 === Subheadline 1 ===
9146 ===== Skipping a level =====
9147 ====== Skipping a level ======
9151 ===Another headline===
9153 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9155 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
9157 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
9159 <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>
9161 <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>
9168 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
9170 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
9175 <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>
9176 <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>
9177 <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>
9178 <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>
9179 <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>
9182 <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>
9186 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
9188 Handling of sections up to level 6 and beyond
9191 == Level 2 Heading==
9192 === Level 3 Heading===
9193 ==== Level 4 Heading====
9194 ===== Level 5 Heading=====
9195 ====== Level 6 Heading======
9196 ======= Level 7 Heading=======
9197 ======== Level 8 Heading========
9198 ========= Level 9 Heading=========
9199 ========== Level 10 Heading==========
9201 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9203 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
9205 <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>
9207 <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>
9209 <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>
9211 <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>
9213 <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>
9214 <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>
9215 <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>
9216 <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>
9217 <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>
9230 <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>
9231 <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>
9232 <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>
9233 <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>
9234 <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>
9235 <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>
9236 <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>
9237 <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>
9238 <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>
9239 <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>
9244 TOC regression (bug 9764)
9248 ==== title 1.1.1 ====
9253 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9255 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9257 <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>
9259 <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>
9262 <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>
9265 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
9267 <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>
9272 <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>
9273 <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>
9274 <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>
9275 <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>
9276 <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>
9277 <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>
9282 TOC with wgMaxTocLevel=3 (bug 6204)
9288 ==== title 1.1.1 ====
9293 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9295 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9297 <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>
9298 <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>
9301 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
9303 <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>
9308 <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>
9309 <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>
9310 <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>
9311 <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>
9312 <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>
9313 <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>
9318 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
9324 ====Section 1.1.1====
9325 ====Section 1.1.1.1====
9328 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9330 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
9332 <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>
9335 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
9338 <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>
9339 <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>
9340 <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>
9341 <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>
9342 <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>
9348 Resolving duplicate section names
9353 <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>
9354 <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>
9359 Resolving duplicate section names with differing case (bug 10721)
9364 <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>
9365 <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>
9377 Template with sections, __NOTOC__
9384 <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>
9385 <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>
9386 <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>
9387 <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>
9392 __NOEDITSECTION__ keyword
9398 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
9399 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
9404 Link inside a section heading
9406 ==Section with a [[Main Page|link]] in it==
9408 <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>
9413 TOC regression (bug 12077)
9420 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9422 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9424 <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>
9427 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
9430 <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>
9431 <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>
9432 <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>
9437 BUG 1219 URL next to image (good)
9439 http://example.com [[Image:foobar.jpg]]
9441 <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>
9446 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
9449 The line above must have a trailing space!
9452 But just in case it doesn't...
9454 <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>
9455 <p>The line above must have a trailing space!
9457 <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>
9458 <p>But just in case it doesn't...
9463 Header with special characters (bug 25462)
9465 The tooltips shall not show entities to the user (ie. be double escaped)
9482 <p>The tooltips shall not show entities to the user (ie. be double escaped)
9484 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9486 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
9487 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
9488 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
9489 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
9490 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
9493 <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>
9496 <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>
9499 <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>
9502 <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>
9505 <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>
9511 Headers with excess '=' characters
9512 (Are similar tests necessary beyond the 1st level?)
9516 =''italic'' heading==
9517 ==''italic'' heading=
9519 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9521 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
9522 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
9523 <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>
9524 <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>
9527 <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>
9528 <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>
9529 <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>
9530 <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>
9535 HTML headers vs TOC (bug 23393)
9536 (__NOEDITSECTION__ for clearer output, doesn't matter here)
9548 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9550 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
9552 <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>
9553 <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>
9556 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
9558 <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>
9559 <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>
9564 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
9565 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
9566 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
9567 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
9568 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
9569 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
9574 BUG 1219 URL next to image (broken)
9576 http://example.com[[Image:foobar.jpg]]
9578 <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>
9583 Bug 1186 news: in the middle of text
9585 http://en.wikinews.org/wiki/Wikinews:Workplace
9587 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
9593 Namespaced link must have a title
9602 Namespaced link must have a title (bad fragment version)
9604 [[Project:#fragment]]
9606 <p>[[Project:#fragment]]
9612 ### HTML tags and HTML attributes
9616 div with no attributes
9618 <div>HTML rocks</div>
9620 <div>HTML rocks</div>
9625 div with double-quoted attribute
9627 <div id="rock">HTML rocks</div>
9629 <div id="rock">HTML rocks</div>
9634 div with single-quoted attribute
9636 <div id='rock'>HTML rocks</div>
9638 <div id="rock">HTML rocks</div>
9643 div with unquoted attribute
9645 <div id=rock>HTML rocks</div>
9647 <div id="rock">HTML rocks</div>
9652 div with illegal double attributes
9654 <div id="a" id="b">HTML rocks</div>
9656 <div id="b">HTML rocks</div>
9660 # FIXME: produce empty string instead of "class" in the PHP parser, following
9663 div with empty attribute value, space before equals
9667 <div class =>HTML rocks</div>
9669 <div class="">HTML rocks</div>
9673 # The PHP parser escapes the opening brace to { for some reason, so
9674 # disabled this test for it.
9676 div with braces in attribute value
9680 <div title="{}">Foo</div>
9682 <div title="{}">Foo</div>
9685 # This it very inconsistent in the PHP parser: it returns
9686 # class="class" if there is a space between the name and the equal sign (see
9687 # 'div with empty attribute value, space before equals'), but strips the
9688 # attribute completely if the space is missing. We hope that not much content
9689 # depends on this, so are implementing the behavior below in Parsoid for
9690 # consistencies' sake. Disabled for the PHP parser.
9691 # FIXME: fix this behavior in the PHP parser?
9693 div with empty attribute value, no space before equals
9697 <div class=>HTML rocks</div>
9699 <div class="">HTML rocks</div>
9704 HTML multiple attributes correction
9706 <p class="error" class="awesome">Awesome!</p>
9708 <p class="awesome">Awesome!</p>
9713 Table multiple attributes correction
9716 !+ class="error" class="awesome"| status
9721 <th class="awesome"> status
9729 <DIV ID="x">HTML ROCKS</DIV>
9731 <div id="x">HTML ROCKS</div>
9736 Non-ASCII pseudo-tags are rendered as text
9745 Pseudo-tag with URL 'name' renders as url link
9747 <http://example.com/>
9749 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
9754 text with amp in the middle of nowhere
9758 <p>Remember AT&T?
9763 text with character entity: eacute
9765 I always thought é was a cute letter.
9767 <p>I always thought é was a cute letter.
9772 text with entity-escaped character entity-like string: eacute
9774 I always thought &eacute; was a cute letter.
9776 <p>I always thought &eacute; was a cute letter.
9781 text with undefined character entity: xacute
9783 I always thought &xacute; was a cute letter.
9785 <p>I always thought &xacute; was a cute letter.
9791 ### Nesting tests (see bug 41545, 50604, 51081)
9794 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
9795 # Note that html2wt is considerably more difficult if we use <b> in
9796 # the test case, instead of <big>
9798 Ensure that HTML adoption agency algorithm is properly implemented.
9800 <big>X<big>Y</big>Z</big>
9802 <p><big>X<big>Y</big>Z</big>
9806 # This was bug 41545 in the PHP parser.
9810 <kbd>X<kbd>Y</kbd>Z</kbd>
9812 <p><kbd>X<kbd>Y</kbd>Z</kbd>
9816 # The following cases were bug 51081 in the PHP parser.
9817 # Note that there are some other nestable tags (b, i, etc) which are
9818 # not covered; see bug 51081 for discussion.
9822 <em>X<em>Y</em>Z</em>
9824 <p><em>X<em>Y</em>Z</em>
9831 <strong>X<strong>Y</strong>Z</strong>
9833 <p><strong>X<strong>Y</strong>Z</strong>
9842 <p><q>X<q>Y</q>Z</q>
9849 <ruby>X<ruby>Y</ruby>Z</ruby>
9851 <p><ruby>X<ruby>Y</ruby>Z</ruby>
9858 <bdo>X<bdo>Y</bdo>Z</bdo>
9860 <p><bdo>X<bdo>Y</bdo>Z</bdo>
9872 [[Media:Foobar.jpg]]
9874 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
9879 Media link with text
9881 [[Media:Foobar.jpg|A neat file to look at]]
9883 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
9887 # FIXME: this is still bad HTML tag nesting
9889 Media link with nasty text
9890 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
9892 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
9894 <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>
9899 Media link to nonexistent file (bug 1702)
9901 [[Media:No such.jpg]]
9903 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
9908 Image link to nonexistent file (bug 1850 - good)
9910 [[Image:No such.jpg]]
9912 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
9917 :Image link to nonexistent file (bug 1850 - bad)
9919 [[:Image:No such.jpg]]
9921 <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>
9928 Character reference normalization in link text (bug 1938)
9930 [[Main Page|this&that]]
9932 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
9939 Test for unicode normalization
9941 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
9945 (bug 19451) Links should refer to the normalized form.
9953 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
9954 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
9955 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
9956 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
9957 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
9962 Empty attribute crash test (bug 2067)
9964 <font color="">foo</font>
9966 <p><font color="">foo</font>
9971 Empty attribute crash test single-quotes (bug 2067)
9973 <font color=''>foo</font>
9975 <p><font color="">foo</font>
9980 Attribute test: equals, then nothing
9982 <font color=>foo</font>
9989 Attribute test: unquoted value
9991 <font color=x>foo</font>
9993 <p><font color="x">foo</font>
9998 Attribute test: unquoted but illegal value (hash)
10000 <font color=#x>foo</font>
10002 <p><font color="#x">foo</font>
10007 Attribute test: no value
10009 <font color>foo</font>
10011 <p><font color="color">foo</font>
10016 Bug 2095: link with three closing brackets
10020 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
10025 Bug 2095: link with pipe and three closing brackets
10027 [[Main Page|link]]]
10029 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
10034 Bug 2095: link with pipe and three closing brackets, version 2
10036 [[Main Page|[http://example.com/]]]
10038 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
10048 Template:Dangerous attribute
10050 " onmouseover="alert(document.cookie)
10054 Template:Dangerous style attribute
10056 border-size: expression(alert(document.cookie))
10062 <div style="float: right; {{{1}}}">Magic div</div>
10066 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
10068 <div title="{{test}}"></div>
10070 <div title="This is a test template"></div>
10075 Bug 2304: HTML attribute safety (dangerous template; 2309)
10077 <div title="{{dangerous attribute}}"></div>
10079 <div title=""></div>
10084 Bug 2304: HTML attribute safety (dangerous style template; 2309)
10086 <div style="{{dangerous style attribute}}"></div>
10088 <div style="/* insecure input */"></div>
10093 Bug 2304: HTML attribute safety (safe parameter; 2309)
10095 {{div style|width: 200px}}
10097 <div style="float: right; width: 200px">Magic div</div>
10102 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
10104 {{div style|width: expression(alert(document.cookie))}}
10106 <div style="/* insecure input */">Magic div</div>
10111 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
10113 {{div style|"><script>alert(document.cookie)</script>}}
10115 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
10120 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
10122 {{div style|" ><script>alert(document.cookie)</script>}}
10124 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
10129 Bug 2304: HTML attribute safety (link)
10131 <div title="[[Main Page]]"></div>
10133 <div title="[[Main Page]]"></div>
10138 Bug 2304: HTML attribute safety (italics)
10140 <div title="''foobar''"></div>
10142 <div title="''foobar''"></div>
10147 Bug 2304: HTML attribute safety (bold)
10149 <div title="'''foobar'''"></div>
10151 <div title="'''foobar'''"></div>
10157 Bug 2304: HTML attribute safety (ISBN)
10159 <div title="ISBN 1234567890"></div>
10161 <div title="ISBN 1234567890"></div>
10166 Bug 2304: HTML attribute safety (RFC)
10168 <div title="RFC 1234"></div>
10170 <div title="RFC 1234"></div>
10175 Bug 2304: HTML attribute safety (PMID)
10177 <div title="PMID 1234567890"></div>
10179 <div title="PMID 1234567890"></div>
10184 Bug 2304: HTML attribute safety (web link)
10186 <div title="http://example.com/"></div>
10188 <div title="http://example.com/"></div>
10193 Bug 2304: HTML attribute safety (named web link)
10195 <div title="[http://example.com/ link]"></div>
10197 <div title="[http://example.com/ link]"></div>
10202 Bug 3244: HTML attribute safety (extension; safe)
10204 <div style="<nowiki>background:blue</nowiki>"></div>
10206 <div style="background:blue"></div>
10211 Bug 3244: HTML attribute safety (extension; unsafe)
10213 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
10215 <div style="/* insecure input */"></div>
10219 # More MSIE fun discovered by Tom Gilder
10222 MSIE CSS safety test: spurious slash
10224 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
10226 <div style="/* insecure input */">evil</div>
10231 MSIE CSS safety test: hex code
10233 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
10235 <div style="/* insecure input */">evil</div>
10240 MSIE CSS safety test: comment in url
10242 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
10244 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
10249 MSIE CSS safety test: comment in expression
10251 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
10253 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
10259 Table attribute legitimate extension
10262 !+ style="<nowiki>color:blue</nowiki>"| status
10267 <th style="color:blue"> status
10273 Table attribute safety
10276 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
10281 <th style="/* insecure input */"> status
10287 CSS line continuation 1
10289 <div style="background-image: u\ rl(test.jpg);"></div>
10291 <div style="/* insecure input */"></div>
10296 CSS line continuation 2
10298 <div style="background-image: u\ rl(test.jpg); "></div>
10300 <div style="/* insecure input */"></div>
10311 Expansion of multi-line templates in attribute values (bug 6255)
10313 <div style="background: {{identity|#00FF00}}">-</div>
10315 <div style="background: #00FF00">-</div>
10321 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
10323 <div style="background:
10326 <div style="background: #00FF00">-</div>
10331 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
10333 <div style="background: #00FF00">-</div>
10335 <div style="background: #00FF00">-</div>
10340 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
10343 Parser hook: empty input
10356 Parser hook: empty input using terminated empty elements
10369 Parser hook: empty input using terminated empty elements (space before)
10382 Parser hook: basic input
10396 Parser hook: case insensitive
10410 Parser hook: case insensitive, redux
10423 Parser hook: nested tags
10427 <tag><tag></tag></tag>
10438 Parser hook: basic arguments
10440 <tag width=200 height = "100" depth = '50' square></tag>
10448 'square' => 'square',
10455 Parser hook: argument containing a forward slash (bug 5344)
10457 <tag filename='/tmp/bla'></tag>
10462 'filename' => '/tmp/bla',
10469 Parser hook: empty input using terminated empty elements (bug 2374)
10482 # </tag> should be output literally since there is no matching tag that begins it
10484 Parser hook: basic arguments using terminated empty elements (bug 2374)
10486 <tag width=200 height = "100" depth = '50' square/>
10496 'square' => 'square',
10505 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
10509 Parser hook: static parser hook not inside a comment
10511 <statictag>hello, world</statictag>
10512 <statictag action=flush/>
10520 Parser hook: static parser hook inside a comment
10522 <!-- <statictag>hello, world</statictag> -->
10523 <statictag action=flush/>
10529 # Nested template calls; this case was broken by Parser.php rev 1.506,
10533 Template:One-parameter
10535 (My parameter is: {{{1}}})
10539 Template:Map-one-parameter
10541 {{{{{1}}}|{{{2}}}}}
10545 Nested template calls
10547 {{Map-one-parameter|One-parameter|param}}
10549 <p>(My parameter is: param)
10558 Sanitizer: Closing of open tags
10560 <s></s><table></table>
10562 <s></s><table></table>
10567 Sanitizer: Closing of open but not closed tags
10576 Sanitizer: Closing of closed but not open tags
10585 Sanitizer: Closing of closed but not open table tags
10587 Table not started</td></tr></table>
10589 <p>Table not started</td></tr></table>
10594 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
10596 <span id="æ: v">byte</span>[[#æ: v|backlink]]
10598 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
10603 Sanitizer: Validating the contents of the id attribute (bug 4515)
10609 Something, but definitely not <br id="9" />...
10613 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
10617 <br id="foo" /><br id="foo" />
10619 Something need to be done. foo-2 ?
10623 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
10626 <meta itemprop="hello" content="world">
10627 <meta http-equiv="refresh" content="5">
10628 <meta itemprop="hello" http-equiv="refresh" content="5">
10629 <link itemprop="hello" href="{{SERVER}}">
10630 <link rel="stylesheet" href="{{SERVER}}">
10631 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
10634 <div itemscope="itemscope">
10635 <p> <meta itemprop="hello" content="world" />
10636 <meta http-equiv="refresh" content="5">
10637 <meta itemprop="hello" content="5" />
10639 <link itemprop="hello" href="http://example.org" />
10640 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
10641 <link itemprop="hello" href="http://example.org" />
10647 Language converter: output gets cut off unexpectedly (bug 5757)
10651 this bit is safe: }-
10653 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
10655 then we get cut off here: }-
10657 all additional text is vanished
10659 <p>this bit is safe: }-
10660 </p><p>but if we add a conversion instance: xxx
10661 </p><p>then we get cut off here: }-
10662 </p><p>all additional text is vanished
10667 Self closed html pairs (bug 5487)
10670 <center><font id="bug" />Centered text</center>
10671 <div><font id="bug2" />In div text</div>
10673 <center><font id="bug" />Centered text</center>
10674 <div><font id="bug2" />In div text</div>
10683 Punctuation: nbsp before exclamation
10687 <p>C'est grave !
10692 Punctuation: CSS !important (bug 11874)
10694 <div style="width:50% !important">important</div>
10696 <div style="width:50% !important">important</div>
10701 Punctuation: CSS ! important (bug 11874; with space after)
10703 <div style="width:50% ! important">important</div>
10705 <div style="width:50% ! important">important</div>
10711 HTML bullet list, closed tags (bug 5497)
10726 HTML bullet list, unclosed tags (bug 5497)
10743 HTML ordered list, closed tags (bug 5497)
10758 HTML ordered list, unclosed tags (bug 5497)
10775 HTML nested bullet list, closed tags (bug 5497)
10800 HTML nested bullet list, open tags (bug 5497)
10825 HTML nested ordered list, closed tags (bug 5497)
10850 HTML nested ordered list, open tags (bug 5497)
10875 HTML ordered list item with parameters oddity
10877 <ol><li id="fragment">One</li></ol>
10879 <ol><li id="fragment">One</li></ol>
10884 bug 5918: autonumbering
10886 [http://first/] [http://second] [ftp://ftp]
10890 [mailto:enclosed@mail.tld With target]
10892 [mailto:enclosed@mail.tld]
10894 mailto:inline@mail.tld
10896 <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>
10897 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
10898 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
10899 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
10900 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
10906 # Security and HTML correctness
10907 # From Nick Jenkins' fuzz testing
10911 Fuzz testing: Parser13
10926 Fuzz testing: Parser14
10931 <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>
10932 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10934 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
10941 Fuzz testing: Parser14-table
10946 <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>
10947 <table style="__TOC__">
10953 # Known to produce bogus xml (extra </td>)
10955 Fuzz testing: Parser16
10975 Fuzz testing: Parser21
10978 ! irc://{{ftp://a" onmouseover="alert('hello world');"
10983 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
10993 Fuzz testing: Parser22
10995 http://===r:::https://b
10999 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
11007 # Known to produce bad XML for now
11009 Fuzz testing: Parser24
11016 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
11017 <br style="onmouseover='alert(document.cookie);' " />
11019 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
11024 <u class="|">}}}} >
11025 <br style="onmouseover='alert(document.cookie);'" />
11027 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
11036 # Note: the current result listed for this is not what the original one was,
11037 # but the original bug was JavaScript injection, which is fixed in any case.
11038 # It's not clear that the original result listed was any more correct than the
11039 # current one. Original result:
11042 # <li class="||">
11043 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
11045 Fuzz testing: Parser25 (bug 6055)
11051 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
11053 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
11058 Fuzz testing: URL adjacent extension (with space, clean)
11061 http://example.com <nowiki>junk</nowiki>
11063 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
11068 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
11071 http://example.com<nowiki>junk</nowiki>
11073 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
11078 Fuzz testing: URL adjacent extension (no space, dirty; pre)
11081 http://example.com<pre>junk</pre>
11083 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
11088 Fuzz testing: image with bogus manual thumbnail
11090 [[Image:foobar.jpg|thumbnail= ]]
11092 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
11097 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
11099 <pre dir=" "></pre>
11101 <pre dir=" "></pre>
11106 Parsing optional HTML elements (Bug 6171)
11111 <td> Some tabular data</td>
11112 <td> More tabular data ...
11113 <td> And yet som tabular data</td>
11119 <td> Some tabular data</td>
11120 <td> More tabular data ...
11121 </td><td> And yet som tabular data</td>
11128 Correct handling of <td>, <tr> (Bug 6171)
11133 <td> Some tabular data</td>
11134 <td> More tabular data ...</td>
11135 <td> And yet som tabular data</td>
11141 <td> Some tabular data</td>
11142 <td> More tabular data ...</td>
11143 <td> And yet som tabular data</td>
11151 Parsing crashing regression (fr:JavaScript)
11155 <p></body></x>
11160 Inline wiki vs wiki block nesting
11166 <p><b>Bold paragraph</b>
11167 </p><p>New wiki paragraph
11172 Inline HTML vs wiki block nesting
11180 <p><b>Bold paragraph</b>
11181 </p><p>New wiki paragraph
11185 # Original result was this:
11186 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
11188 # While that might be marginally more intuitive, maybe, the six-apostrophe
11189 # construct is clearly pathological and the result stated here (which is what
11190 # the parser actually does) is about as reasonable as anything.
11192 Mixing markup for italics and bold
11195 '''bold''''''bold''bolditalics'''''
11197 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
11205 Article for special page transclusion test
11209 Special page transclusion
11212 {{Special:Prefixindex/Xyzzyx}}
11214 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11219 Special page transclusion twice (bug 5021)
11222 {{Special:Prefixindex/Xyzzyx}}
11223 {{Special:Prefixindex/Xyzzyx}}
11225 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11226 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11231 Transclusion of default MediaWiki message
11233 {{MediaWiki:Mainpage}}
11240 Transclusion of nonexistent MediaWiki message
11242 {{MediaWiki:Mainpagexxx}}
11244 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
11249 Transclusion of MediaWiki message with underscore
11251 {{MediaWiki:history_short}}
11258 Transclusion of MediaWiki message with space
11260 {{MediaWiki:history short}}
11267 Invalid header with following text
11277 Section extraction test (section 0)
11297 Section extraction test (section 1)
11319 Section extraction test (section 2)
11340 Section extraction test (section 3)
11360 Section extraction test (section 4)
11384 Section extraction test (section 5)
11404 Section extraction test (section 6)
11425 Section extraction test (section 7)
11445 Section extraction test (section 8)
11465 Section extraction test (section 9)
11486 Section extraction test (section 10)
11506 Section extraction test (nonexistent section 11)
11525 Section extraction test with bogus heading (section 1)
11530 ==bogus== not a legal section
11534 ==bogus== not a legal section
11538 Section extraction test with bogus heading (section 2)
11543 ==bogus== not a legal section
11550 Section extraction test with comment after heading (section 1)
11562 Section extraction test with comment after heading (section 2)
11574 Section extraction test with bogus <nowiki> heading (section 1)
11579 ==bogus== <nowiki>not a legal section</nowiki>
11583 ==bogus== <nowiki>not a legal section</nowiki>
11587 Section extraction test with bogus <nowiki> heading (section 2)
11592 ==bogus== <nowiki>not a legal section</nowiki>
11599 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
11600 # instead of respecting commented sections
11602 Section extraction prefixed by comment (section 1)
11613 Section extraction prefixed by comment (section 2)
11624 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
11625 # instead of respecting HTML-style headings
11627 Section extraction, mixed wiki and html (section 1)
11643 Section extraction, mixed wiki and html (section 2)
11659 # Formerly testing for bug 3342
11661 Section extraction, heading surrounded by <noinclude>
11665 <noinclude>==unmarked==</noinclude>
11671 # Test behavior of bug 19910
11673 Sectiion with all-equals
11678 The line above must have a trailing space
11681 But just in case it doesn't...
11685 But just in case it doesn't...
11689 Section replacement test (section 0)
11720 Section replacement test (section 1)
11749 Section replacement test (section 2)
11779 Section replacement test (section 3)
11810 Section replacement test (section 4)
11837 Section replacement test (section 5)
11868 Section replacement test (section 6)
11898 Section replacement test (section 7)
11929 Section replacement test (section 8)
11960 Section replacement test (section 9)
11989 Section replacement test (section 10)
12019 Section replacement test with initial whitespace (bug 13728)
12023 Preformatted initial line
12027 Preformatted initial line
12034 Section extraction, heading followed by pre with 20 spaces (bug 6398)
12046 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
12059 Section extraction, <pre> around bogus header (bug 10309)
12076 Section replacement, <pre> around bogus header (bug 10309)
12078 noxml replace=2,"xxx"
12099 Handling of 
 in URLs
12103 <ul><li><ul><li><a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a>
12110 5 quotes, code coverage +1 line (php)
12117 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
12119 5 quotes, code coverage +1 line (parsoid)
12125 <p><i><b></b></i></p>
12129 Special:Search page linking.
12133 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
12145 * {{ROOTPAGENAMEE}}
12147 * {{BASEPAGENAMEE}}
12149 * {{TALKPAGENAMEE}}
12150 * {{SUBJECTPAGENAME}}
12151 * {{SUBJECTPAGENAMEE}}
12157 * {{SUBJECTSPACEE}}
12158 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
12160 <ul><li> Parser test
12161 </li><li> Parser test
12162 </li><li> Parser test
12163 </li><li> Parser_test
12164 </li><li> Parser test
12165 </li><li> Parser_test
12166 </li><li> Parser test
12167 </li><li> Parser_test
12168 </li><li> Talk:Parser test
12169 </li><li> Talk:Parser_test
12170 </li><li> Parser test
12171 </li><li> Parser_test
12178 </li><li> <a href="/index.php?title=Template:Dynamic&action=edit&redlink=1" class="new" title="Template:Dynamic (page does not exist)">Template:Dynamic</a>
12182 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
12192 image4 |300px| centre
12193 image5.svg| http://///////
12198 <ul class="gallery">
12199 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12200 <div style="height: 150px;">Image1.png</div>
12201 <div class="gallerytext">
12204 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12205 <div style="height: 150px;">Image2.gif</div>
12206 <div class="gallerytext">
12211 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12212 <div style="height: 150px;">Image3</div>
12213 <div class="gallerytext">
12216 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12217 <div style="height: 150px;">Image4</div>
12218 <div class="gallerytext">
12223 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12224 <div style="height: 150px;">Image5.svg</div>
12225 <div class="gallerytext">
12226 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
12230 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12231 <div style="height: 150px;">* image6</div>
12232 <div class="gallerytext">
12240 Gallery (with options)
12242 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
12243 File:Nonexistant.jpg|caption
12244 File:Nonexistant.jpg
12245 image:foobar.jpg|some '''caption''' [[Main Page]]
12247 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
12250 <ul class="gallery" style="max-width: 226px;_width: 226px;">
12251 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
12252 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12253 <div style="height: 70px;">Nonexistant.jpg</div>
12254 <div class="gallerytext">
12259 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12260 <div style="height: 70px;">Nonexistant.jpg</div>
12261 <div class="gallerytext">
12264 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12265 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
12266 <div class="gallerytext">
12267 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
12271 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12272 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
12273 <div class="gallerytext">
12276 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12277 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="This is a foo-bar." src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
12278 <div class="gallerytext">
12288 Gallery with wikitext inside caption
12291 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
12292 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
12295 <ul class="gallery">
12296 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12297 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
12298 <div class="gallerytext">
12299 <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>
12303 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12304 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
12305 <div class="gallerytext">
12306 <p>This is a test template
12315 gallery (with showfilename option)
12317 <gallery showfilename>
12318 File:Nonexistant.jpg|caption
12319 File:Nonexistant.jpg
12320 image:foobar.jpg|some '''caption''' [[Main Page]]
12324 <ul class="gallery">
12325 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12326 <div style="height: 150px;">Nonexistant.jpg</div>
12327 <div class="gallerytext">
12328 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
12333 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12334 <div style="height: 150px;">Nonexistant.jpg</div>
12335 <div class="gallerytext">
12336 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
12340 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12341 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
12342 <div class="gallerytext">
12343 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
12344 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
12348 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12349 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
12350 <div class="gallerytext">
12351 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
12360 Gallery (with namespace-less filenames)
12363 File:Nonexistant.jpg
12369 <ul class="gallery">
12370 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12371 <div style="height: 150px;">Nonexistant.jpg</div>
12372 <div class="gallerytext">
12375 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12376 <div style="height: 150px;">Nonexistant.jpg</div>
12377 <div class="gallerytext">
12380 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12381 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
12382 <div class="gallerytext">
12385 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12386 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
12387 <div class="gallerytext">
12395 HTML Hex character encoding (spells the word "JavaScript")
12397 JavaScript
12399 <p>JavaScript
12404 HTML Hex character encoding bogus encoding (bug 26437 regression check)
12408 <p>&#xsee;&#XSEE;
12413 HTML Hex character encoding mixed case
12422 __FORCETOC__ override
12434 ISBN 978-0-1234-56 789
12436 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
12441 ISBN followed by 5 spaces
12452 ISBN ISBN 1234567890
12454 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
12459 Bug 22905: <abbr> followed by ISBN followed by </a>
12461 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
12463 <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>
12472 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
12477 Double RFC with a wiki link
12481 <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>
12490 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
12495 Centre-aligned image
12497 [[Image:foobar.jpg|centre]]
12499 <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>
12506 [[Image:foobar.jpg|none]]
12508 <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>
12513 Width + Height sized image (using px) (height is ignored)
12515 [[Image:foobar.jpg|640x480px]]
12517 <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>
12522 Width-sized image (using px, no following whitespace)
12524 [[Image:foobar.jpg|640px]]
12526 <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>
12531 Width-sized image (using px, with following whitespace - test regression from r39467)
12533 [[Image:foobar.jpg|640px ]]
12535 <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>
12540 Width-sized image (using px, with preceding whitespace - test regression from r39467)
12542 [[Image:foobar.jpg| 640px]]
12544 <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>
12549 Another italics / bold test
12557 # Note the results may be incorrect, as parserTest output included this:
12558 # XML error: Mismatched tag at byte 6120:
12559 # ...<dd> </dt></dl> </dd...
12567 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd>
12578 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
12580 Images with the "|" character in the comment
12582 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
12584 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&param2=%7Cx">external</a> URL</div></div></div>
12589 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
12591 <html><script>alert(1);</script></html>
12593 <p><html><script>alert(1);</script></html>
12598 HTML with raw HTML ($wgRawHtml==true)
12602 <html><script>alert(1);</script></html>
12604 <p><script>alert(1);</script>
12609 Parents of subpages, one level up
12611 subpage title=[[Subpage test/L1/L2/L3]]
12615 <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>
12621 Parents of subpages, one level up, not named
12623 subpage title=[[Subpage test/L1/L2/L3]]
12627 <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>
12634 Parents of subpages, two levels up
12636 subpage title=[[Subpage test/L1/L2/L3]]
12642 <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
12643 </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>
12648 Parents of subpages, two levels up, without trailing slash or name.
12650 subpage title=[[Subpage test/L1/L2/L3]]
12659 Parents of subpages, two levels up, with lots of extra trailing slashes.
12661 subpage title=[[Subpage test/L1/L2/L3]]
12665 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
12670 Subpage test/L1/L2/L3Sibling
12676 Transclusion of a sibling page (one level up)
12678 subpage title=[[Subpage test/L1/L2/L3]]
12687 Transclusion of a child page
12689 subpage title=[[Subpage test/L1/L2]]
12698 Non-transclusion because of too many up levels
12700 subpage title=[[Subpage test/L1/L2/L3]]
12702 {{../../../../More than parent}}
12704 <p>{{../../../../More than parent}}
12709 Definition list code coverage
12715 <dl><dt> title  </dt><dd> def
12716 </dd><dt> title </dt><dd> def
12717 </dd><dt>title</dt><dd> def
12723 Don't fall for the self-closing div
12725 <div>hello world</div/>
12727 <div>hello world</div>
12736 <p>[[:Template:Msg]]
12745 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
12749 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
12751 Always escape literal '>' in output, not just after '<'
12765 <p>This is a test template
12766 This is a test template
12778 Inclusion of !userCanEdit() content
12782 <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>
12788 Out-of-order TOC heading levels
12797 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
12799 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
12801 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
12802 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
12805 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
12807 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
12808 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
12813 <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>
12814 <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>
12815 <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>
12816 <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>
12817 <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>
12818 <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>
12824 ISBN with a dummy number
12834 ISBN with space-delimited number
12838 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
12844 ISBN with multiple spaces, no number
12863 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
12864 </p><p>ISBN 12345678901
12870 ISBN with trailing year (bug 8110)
12872 ISBN 1-234-56789-0 - 2006
12874 ISBN 1 234 56789 0 - 2006
12876 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
12877 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
12885 {{anchorencode:foo bar©#%n}}
12887 <p>foo_bar.C2.A9.23.25n
12892 anchorencode trims spaces
12894 {{anchorencode: __pretty__please__}}
12901 anchorencode deals with links
12903 {{anchorencode: [[hello|world]] [[hi]]}}
12910 anchorencode deals with templates
12912 {{anchorencode: {{Foo}} }}
12919 anchorencode encodes like the TOC generator: (bug 18431)
12921 === _ +:.3A%3A&&]] ===
12922 {{anchorencode: _ +:.3A%3A&&]] }}
12925 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
12926 <p>.2B:.3A.253A.26.26.5D.5D
12931 Bug 6200: blockquotes and paragraph formatting
12952 Bug 8293: Use of center tag ruins paragraph formatting
12973 Parsing of overlapping (improperly nested) inline html tags (PHP parser)
12977 <span><s>x</span></s>
12979 <p><span><s>x</span></s></span>
12984 Parsing of overlapping (improperly nested) inline html tags (Parsoid)
12988 <span><s>x</span></s>
12990 <p><span><s>x</s></span><s></s>
12995 ### Language variants related tests
12998 Self-link in language variants
13000 title=[[Dunav]] language=sr
13002 Both [[Dunav]] and [[Дунав]] are names for this river.
13004 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
13015 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
13017 title=[[Duna]] language=sr
13019 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
13021 <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.
13026 Link to pages in language variants
13030 Main Page can be written as [[Маин Паге]]
13032 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
13038 Multiple links to pages in language variants
13042 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
13044 <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>.
13050 Simple template in language variants
13056 <p>This is a test template
13062 Template with explicit namespace in language variants
13068 <p>This is a test template
13074 Basic test for template parameter in language variants
13078 {{парамтест|param=foo}}
13080 <p>This is a test template with parameter foo
13086 Simple category in language variants
13090 [[Category:МедиаWики Усер'с Гуиде]]
13092 <a href="/wiki/%D0%9A%D0%B0%D1%82%D0%B5%D0%B3%D0%BE%D1%80%D0%B8%D1%98%D0%B0:MediaWiki_User%27s_Guide" title="Категорија:MediaWiki User's Guide">MediaWiki User's Guide</a>
13109 Don't convert blue categorylinks to another variant (bug 33210)
13113 [[A]][[Category:分类]]
13115 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
13120 Stripping -{}- tags (language variants)
13124 Latin proverb: -{Ne nuntium necare}-
13126 <p>Latin proverb: Ne nuntium necare
13132 Prevent conversion with -{}- tags (language variants)
13134 language=sr variant=sr-ec
13136 Latinski: -{Ne nuntium necare}-
13138 <p>Латински: Ne nuntium necare
13144 Prevent conversion of text with -{}- tags (language variants)
13146 language=sr variant=sr-ec
13148 Latinski: -{Ne nuntium necare}-
13150 <p>Латински: Ne nuntium necare
13156 Prevent conversion of links with -{}- tags (language variants)
13158 language=sr variant=sr-ec
13162 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
13168 -{}- tags within headlines (within html for parserConvert())
13170 language=sr variant=sr-ec
13174 <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>
13180 Explicit definition of language variant alternatives
13182 language=zh variant=zh-tw
13184 -{zh:China;zh-tw:Taiwan}-, not China
13186 <p>Taiwan, not China
13192 Conversion around HTML tags
13194 language=sr variant=sr-ec
13196 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
13197 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
13200 <span title="ЛаCтин">ски</span>
13206 Explicit session-wise language variant mapping (A flag and - flag)
13208 language=zh variant=zh-tw
13210 Taiwan is not China.
13211 But -{A|zh:China;zh-tw:Taiwan}- is China,
13212 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
13213 and -{China}- is China.
13215 <p>Taiwan is not China.
13216 But Taiwan is Taiwan,
13217 (This should be stripped!)
13218 and China is China.
13223 Explicit session-wise language variant mapping (H flag for hide)
13225 language=zh variant=zh-tw
13227 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
13230 <p>(This should be stripped!)
13236 Adding explicit conversion rule for title (T flag)
13238 language=zh variant=zh-tw showtitle
13240 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13243 <p>Should be stripped!
13248 Testing that changing the language variant here in the tests actually works
13250 language=zh variant=zh showtitle
13252 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13255 <p>Should be stripped!
13260 Recursive conversion of alt and title attrs shouldn't clear converter state
13262 language=zh variant=zh-cn showtitle
13264 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
13265 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
13269 Should be stripped<span title="Exclamation">!</span>
13274 Bug 24072: more test on conversion rule for title
13276 language=zh variant=zh-tw showtitle
13278 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13279 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
13282 <p>This should be stripped!
13283 This won't take interferes with the title rule.
13288 Partly disable title conversion if variant == main language code
13290 language=zh variant=zh title=[[ZH]] showtitle
13292 -{T|zh-cn:CN;zh-tw:TW}-
13300 Partly disable title conversion if variant == main language code, more
13302 language=zh variant=zh title=[[ZH]] showtitle
13312 Raw output of variant escape tags (R flag)
13314 language=zh variant=zh-tw
13316 Raw: -{R|zh:China;zh-tw:Taiwan}-
13318 <p>Raw: zh:China;zh-tw:Taiwan
13323 Nested using of manual convert syntax
13325 language=zh variant=zh-hk
13327 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
13329 <p>Nested: Hello Hong Kong!
13334 Proper conversion of text in external links
13336 language=sr variant=sr-ec
13338 http://www.google.com
13339 gopher://www.google.com
13340 [http://www.google.com http://www.google.com]
13341 [gopher://www.google.com gopher://www.google.com]
13342 [https://www.google.com irc://www.google.com]
13343 [ftp://www.google.com www.google.com/ftp://dir]
13344 [//www.google.com www.google.com]
13346 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
13347 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
13348 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
13349 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
13350 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
13351 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
13352 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
13357 Do not convert roman numbers to language variants
13359 language=sr variant=sr-ec
13363 <p>Фридрих IV је цар.
13368 Unclosed language converter markup "-{"
13379 Don't convert raw rule "-{R|=>}-" to "=>"
13396 Bug 529: Uncovered bullet
13406 # Plain MediaWiki does not remove empty lists, but tidy actually does.
13407 # Templates in Wikipedia rely on this behavior, as tidy has always been
13408 # enabled there. These tests are normally run *without* tidy, so specify the
13409 # full output here.
13410 # To test realistic parsing behavior, apply a tidy-like transformation to both
13411 # the expected output and your parser's output.
13413 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
13415 ******* Foo {{bullet}}
13417 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo
13430 Bug 529: Uncovered table already at line-start
13453 Bug 529: Uncovered bullet in parser function result
13455 * Foo {{lc:{{bullet}} }}
13464 Bug 5678: Double-parsed template argument
13466 {{lc:{{{1}}}|hello}}
13473 Bug 5678: Double-parsed template invocation
13475 {{lc:{{paramtest {{!}} param = hello }} }}
13477 <p>{{paramtest | param = hello }}
13482 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
13485 title=[[Main Page]]
13487 {{PRVNÍVELKÉ:ěščř}}
13488 {{prvnívelké:ěščř}}
13508 Morwen/13: Unclosed link followed by heading
13515 <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>
13520 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
13527 <h1><span class="mw-headline" id="heading">heading</span></h1>
13532 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
13539 <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>
13554 Paragraphs inside divs (no extra line breaks)
13566 Paragraphs inside divs (extra line break on open)
13581 Paragraphs inside divs (extra line break on close)
13596 Paragraphs inside divs (extra line break on open and close)
13613 Nesting tags, paragraphs on lines which begin with <div>
13617 <div></div><strong>A
13626 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
13628 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
13630 <blockquote>Line one
13632 Line two</blockquote>
13634 <blockquote>Line one
13635 Line two</blockquote>
13640 Bug 6200: paragraphs inside blockquotes (extra line break on open)
13645 Line two</blockquote>
13650 Line two</blockquote>
13655 Bug 6200: paragraphs inside blockquotes (extra line break on close)
13657 <blockquote>Line one
13662 <blockquote>Line one
13670 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
13687 Paragraphs inside blockquotes/divs (no extra line breaks)
13689 <blockquote><div>Line one
13691 Line two</div></blockquote>
13693 <blockquote><div>Line one
13694 Line two</div></blockquote>
13699 Paragraphs inside blockquotes/divs (extra line break on open)
13704 Line two</div></blockquote>
13709 Line two</div></blockquote>
13714 Paragraphs inside blockquotes/divs (extra line break on close)
13716 <blockquote><div>Line one
13719 </div></blockquote>
13721 <blockquote><div>Line one
13724 </div></blockquote>
13729 Paragraphs inside blockquotes/divs (extra line break on open and close)
13735 </div></blockquote>
13741 </div></blockquote>
13746 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
13748 wgLinkHolderBatchSize=0
13754 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
13755 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
13756 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
13761 Free external link invading image caption
13763 [[Image:Foobar.jpg|thumb|http://x|hello]]
13765 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>hello</div></div></div>
13770 Bug 15196: localised external link numbers
13774 [http://en.wikipedia.org/]
13776 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
13781 Multibyte character in padleft
13783 {{padleft:-Hello|7|Æ}}
13790 Multibyte character in padright
13792 {{padright:Hello-|7|Æ}}
13799 formatdate parser function
13801 {{#formatdate:2009-03-24}}
13803 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
13808 formatdate parser function, with default format
13810 {{#formatdate:2009-03-24|mdy}}
13812 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
13817 Spacing of numbers in formatted dates
13819 {{#formatdate:January 15}}
13821 <p><span class="mw-formatted-date" title="01-15">January 15</span>
13826 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
13828 language=nl title=[[MediaWiki:Common.css]]
13830 {{#formatdate:2009-03-24|dmy}}
13832 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
13845 Edit comment with link
13849 I like the [[Main Page]] a lot
13851 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
13855 Edit comment with link and link text
13859 I like the [[Main Page|best pages]] a lot
13861 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
13865 Edit comment with link and link text with suffix
13869 I like the [[Main Page|best page]]s a lot
13871 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
13875 Edit comment with section link (non-local, eg in history list)
13877 comment title=[[Main Page]]
13879 /* External links */ removed bogus entries
13881 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
13885 Edit comment with section link and text before it (non-local, eg in history list)
13887 comment title=[[Main Page]]
13889 pre-comment text /* External links */ removed bogus entries
13891 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>
13895 Edit comment with section link (local, eg in diff view)
13897 comment local title=[[Main Page]]
13899 /* External links */ removed bogus entries
13901 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
13905 Edit comment with subpage link (bug 14080)
13909 title=[[Subpage test]]
13911 Poked at a [[/subpage]] here...
13913 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
13917 Edit comment with subpage link and link text (bug 14080)
13921 title=[[Subpage test]]
13923 Poked at a [[/subpage|neat little page]] here...
13925 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
13929 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
13932 title=[[Subpage test]]
13934 Poked at a [[/subpage]] here...
13936 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
13940 Edit comment with bare anchor link (local, as on diff)
13944 title=[[Main Page]]
13948 <a href="#section">#section</a>
13952 Edit comment with bare anchor link (non-local, as on history)
13955 title=[[Main Page]]
13959 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
13963 Anchor starting with underscore
13967 <p><a href="#_ref">One</a>
13972 Id starting with underscore
13974 <div id="_ref"></div>
13976 <div id="_ref"></div>
13981 Space normalisation on autocomment (bug 22784)
13984 title=[[Main Page]]
13986 /* __hello__world__ */
13988 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
13992 percent-encoding and + signs in comments (Bug 26410)
13996 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
13998 <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>
14002 Bad images - basic functionality
14011 Bad images - bug 16039: text after bad image disappears
14025 Verify that displaytitle works (bug #22501) no displaytitle
14029 wgAllowDisplayTitle=true
14030 wgRestrictDisplayTitle=false
14032 this is not the the title
14035 <p>this is not the the title
14040 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
14045 wgAllowDisplayTitle=true
14046 wgRestrictDisplayTitle=false
14048 this is not the the title
14049 {{DISPLAYTITLE:whatever}}
14052 <p>this is not the the title
14057 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
14062 wgAllowDisplayTitle=true
14063 wgRestrictDisplayTitle=true
14065 this is not the the title
14066 {{DISPLAYTITLE:whatever}}
14069 <p>this is not the the title
14074 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
14079 wgAllowDisplayTitle=true
14080 wgRestrictDisplayTitle=true
14082 this is not the the title
14083 {{DISPLAYTITLE:screen}}
14086 <p>this is not the the title
14091 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
14096 wgAllowDisplayTitle=false
14098 this is not the the title
14099 {{DISPLAYTITLE:screen}}
14102 <p>this is not the the title
14103 <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>
14108 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
14113 wgAllowDisplayTitle=false
14115 this is not the the title
14118 <p>this is not the the title
14123 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
14128 wgAllowDisplayTitle=true
14129 wgRestrictDisplayTitle=true
14131 this is not the the title
14132 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
14134 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
14135 <p>this is not the the title
14140 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
14145 wgAllowDisplayTitle=true
14146 wgRestrictDisplayTitle=true
14148 this is not the the title
14149 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
14151 <span style="color: red;">s</span>creen
14152 <p>this is not the the title
14157 preload: check <noinclude> and <includeonly>
14161 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
14167 preload: check <onlyinclude>
14171 Goodbye <onlyinclude>Hello world</onlyinclude>
14177 preload: can pass tags through if we want to
14181 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
14183 <includeonly>Hello world</includeonly>
14187 preload: check that it doesn't try to do tricks
14191 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
14193 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
14197 Play a bit with r67090 and bug 3158
14201 <div style="width:50% !important"> </div>
14202 <div style="width:50% !important"> </div>
14203 <div style="width:50% !important"> </div>
14204 <div style="border : solid;"> </div>
14206 <div style="width:50% !important"> </div>
14207 <div style="width:50% !important"> </div>
14208 <div style="width:50% !important"> </div>
14209 <div style="border : solid;"> </div>
14214 HTML5 data attributes
14216 <span data-foo="bar">Baz</span>
14217 <p data-abc-def_hij="">Quuz</p>
14219 <p><span data-foo="bar">Baz</span>
14221 <p data-abc-def_hij="">Quuz</p>
14226 percent-encoding and + signs in internal links (Bug 26410)
14228 [[User:+%]] [[Page+title%]]
14229 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
14230 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
14231 [[%33%45]] [[%33%45+]]
14233 <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>
14234 <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>
14235 <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>
14236 <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>
14241 Special characters in embedded file links (bug 27679)
14243 [[File:Contains & ampersand.jpg]]
14244 [[File:Does not exist.jpg|Title with & ampersand]]
14246 <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>
14247 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
14253 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
14255 Text's been normalized?
14257 <p>Text's been normalized?
14262 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
14264 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
14266 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
14271 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
14273 [http://www.example.org/ ideograms]
14275 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
14280 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
14282 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
14284 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
14308 Bug 31098 Template which includes system messages which includes the template
14312 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
14313 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
14318 Bug31490 Turkish: ucfirst 'blah'
14329 Bug31490 Turkish: ucfirst 'ix'
14340 Bug31490 Turkish: lcfirst 'BLAH'
14351 Bug31490 Turkish: ucfırst (with a dotless i)
14357 <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>
14362 Bug31490 ucfırst (with a dotless i) with English language
14368 <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>
14373 Bug 26375: TOC with italics
14375 title=[[Main Page]]
14378 == ''Lost'' episodes ==
14380 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14382 <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>
14385 <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>
14390 Bug 26375: TOC with bold
14392 title=[[Main Page]]
14395 == '''should be bold''' then normal text ==
14397 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14399 <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>
14402 <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>
14407 Bug 33845: Headings become cursive in TOC when they contain an image
14409 title=[[Main Page]]
14412 == Image [[Image:foobar.jpg]] ==
14414 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14416 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
14419 <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>
14424 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
14426 title=[[Main Page]]
14429 == <blockquote>Quote</blockquote> ==
14431 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14433 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
14436 <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>
14441 Unclosed tags in TOC
14443 title=[[Main Page]]
14447 <small>Hanc marginis exiguitas non caperet.</small>
14450 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14452 <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>
14455 <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>
14456 <p><small>Hanc marginis exiguitas non caperet.</small>
14462 Multiple tags in TOC
14465 == <i>Foo</i> <b>Bar</b> ==
14467 == <i>Foo</i> <blockquote>Bar</blockquote> ==
14469 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14471 <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>
14472 <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>
14475 <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>
14476 <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>
14481 Tags with parameters in TOC
14484 == <sup class="in-h2">Hello</sup> ==
14486 == <sup class="a > b">Evilbye</sup> ==
14488 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14490 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
14491 <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>
14494 <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>
14495 <h2><span class="mw-headline" id="b.22.3EEvilbye"><sup> b">Evilbye</sup></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: b">Evilbye">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
14500 span tags with directionality in TOC
14503 == <span dir="ltr">C++</span> ==
14505 == <span dir="rtl">זבנג!</span> ==
14507 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
14509 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
14511 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
14513 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14515 <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>
14516 <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>
14517 <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>
14518 <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>
14519 <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>
14522 <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>
14523 <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>
14524 <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>
14525 <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>
14526 <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>
14533 == {{int:headline_sample}} ==
14537 Bug 32057: Title needed when expanding <h> nodes.
14539 title=[[Main Page]]
14543 <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>
14548 Strip marker in urlencode
14550 {{urlencode:x<nowiki/>y}}
14551 {{urlencode:x<nowiki/>y|wiki}}
14552 {{urlencode:x<nowiki/>y|path}}
14579 Strip marker in formatNum
14581 {{formatnum:1<nowiki/>2}}
14582 {{formatnum:1<nowiki/>2|R}}
14590 Check noCommafy in formatNum
14594 {{formatnum:123456.78}}
14595 {{formatnum:123456.78|NOSEP}}
14603 Strip marker in grammar
14607 {{grammar:elative|foo<nowiki/>bar}}
14614 Strip marker in padleft
14616 {{padleft:|2|x<nowiki/>y}}
14623 Strip marker in padright
14625 {{padright:|2|x<nowiki/>y}}
14632 Strip marker in anchorencode
14634 {{anchorencode:x<nowiki/>y}}
14641 nowiki inside link inside heading (bug 18295)
14643 ==[[foo|x<nowiki>y</nowiki>z]]==
14645 <h2><span class="mw-headline" id="xyz"><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">xyz</a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: xyz">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
14650 new support for bdi element (bug 31817)
14652 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
14654 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
14659 Ignore pipe between table row attributes
14663 |- id=foo | style='color: red'
14671 <tr id="foo" style="color: red">
14678 Gallery override link with WikiLink (bug 34852)
14681 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
14684 <ul class="gallery">
14685 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14686 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/InterWikiLink"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14687 <div class="gallerytext">
14697 Gallery override link with absolute external link (bug 34852)
14700 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
14703 <ul class="gallery">
14704 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14705 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="http://www.example.org"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14706 <div class="gallerytext">
14716 Gallery override link with malicious javascript (bug 34852)
14719 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
14722 <ul class="gallery">
14723 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14724 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/%22_onclick%3D%22alert(%27malicious_javascript_code!%27);"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14725 <div class="gallerytext">
14735 Gallery with invalid title as link (bug 43964)
14738 File:foobar.jpg|link=<
14741 <ul class="gallery">
14742 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14743 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14744 <div class="gallerytext">
14752 Language parser function
14761 Padleft and padright as substr
14763 {{padleft:|3|abcde}}
14764 {{padright:|3|abcde}}
14772 Special parser function
14774 {{#special:RandomPage}}
14775 {{#special:BaDtItLe}}
14776 {{#special:Foobar}}
14785 Bug 34939 - Case insensitive link parsing ([HttP://])
14787 [HttP://MediaWiki.Org/]
14789 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
14794 Bug 34939 - Case insensitive link parsing ([HttP:// title])
14796 [HttP://MediaWiki.Org/ MediaWiki]
14798 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
14803 Bug 34939 - Case insensitive link parsing (HttP://)
14805 HttP://MediaWiki.Org/
14807 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
14813 ### Parsoids-specific tests
14814 ### Parsoid-PHP parser incompatibilities
14817 1. SOL-sensitive wikitext tokens as template-args
14819 parsoid=wt2html,wt2wt
14825 <span about="#mwt1" typeof="mw:Transclusion">
14826 </span><ul about="#mwt1"><li>a</li></ul>
14827 <span about="#mwt2" typeof="mw:Transclusion">
14828 </span><ol about="#mwt2"><li>a</li></ol>
14829 <span about="#mwt3" typeof="mw:Transclusion">
14830 </span><dl about="#mwt3"><dd>a</dd></dl>
14833 #### ----------------------------------------------------------------
14834 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
14835 #### tags. Parsoid's output for these tags differs from that of the
14837 #### ----------------------------------------------------------------
14840 Ref: 1. ref-location should be replaced with an index span
14845 B <ref name="x">foo</ref>
14848 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
14849 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-2">[2]</a></span>
14850 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"y"}}' id="cite_ref-y-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-y-3">[3]</a></span></p>
14854 Ref: 2. ref-tags with identical names should all get the same index
14858 A <ref name="x">foo</ref>
14861 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
14862 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
14866 Ref: 3. spaces in ref-names should be ignored
14870 A <ref name="x">foo</ref>
14871 B <ref name=" x " />
14874 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
14875 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
14876 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-2" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
14880 Ref: 4. 'constructor' should be accepted as a valid ref-name
14881 (NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
14885 A <ref name="constructor">foo</ref>
14887 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"constructor"}}' id="cite_ref-constructor-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-constructor-1">[1]</a></span></p>
14891 Ref: 5. body should accept generic wikitext
14896 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
14901 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"This is a <b data-parsoid=\"{&quot;dsr&quot;:[19,40,3,3]}\"><a rel=\"mw:WikiLink\" href=\"./Bolded_link\" data-parsoid=\"{&quot;a&quot;:{&quot;href&quot;:&quot;./Bolded_link&quot;},&quot;sa&quot;:{&quot;href&quot;:&quot;bolded link&quot;},&quot;stx&quot;:&quot;simple&quot;,&quot;dsr&quot;:[22,37,2,2]}\">bolded link</a></b> and this is a <span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;transclusion&quot;}}}\" data-parsoid=\"{&quot;src&quot;:&quot;{{echo|transclusion}}&quot;,&quot;dsr&quot;:[55,76,null,null]}\">transclusion</span>\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
14903 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
14904 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> This is a <b><a rel="mw:WikiLink" href="./Bolded_link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}}}'>transclusion</span>
14909 Ref: 6. indent-pres should not be output in ref-body
14921 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n bar\n baz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
14923 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
14924 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
14931 Ref: 6. No p-wrapping in ref-body
14950 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n\nbar\n\n\nbaz\n\n\n\nbooz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
14952 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
14953 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
14967 Ref: 8. transclusion wikitext has lower precedence
14971 A <ref> foo {{echo|</ref> B C}}
14975 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo <span typeof=\"mw:Nowiki\" data-parsoid=\"{&quot;src&quot;:&quot;{{&quot;,&quot;dsr&quot;:[12,14,2,null]}\">{{</span>echo|"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C<span typeof="mw:Nowiki">}}</span></p>
14977 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
14978 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <span typeof="mw:Nowiki">{{</span>echo|</li></ol>
14982 Ref: 9. unclosed comments should not leak out of ref-body
14986 A <ref> foo <!--</ref> B C
14990 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo <!---->"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C</p>
14992 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
14993 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <!----></li></ol>
14997 Ref: 10. Unclosed HTML tags should not leak out of ref-body
15001 A <ref> <b> foo </ref> B C
15005 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"<b data-parsoid=\"{&quot;stx&quot;:&quot;html&quot;,&quot;autoInsertedEnd&quot;:true,&quot;dsr&quot;:[8,16,3,0]}\"> foo </b>"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C</p>
15007 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15008 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> <b> foo </b></li></ol>
15012 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
15019 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B
15020 C <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span> D</p>
15024 Ref: 12. ref-tags act as trailing newline migration barrier
15028 <!--the newline at the end of this line moves out of the p-tag-->a
15030 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
15035 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
15038 <p>b<!--the newline at the end of this line stays inside the p-tag--> <span about="#mwt1" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
15039 <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span></p>
15046 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
15054 <p><span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> A
15055 <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"bar\n"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span> B</p>
15059 Ref: 14. A nested ref-tag should be emitted as plain text
15063 <ref>foo <ref>bar</ref> baz</ref>
15067 <span about="#mwt1" class="reference" data-mw="{"name":"ref","body":{"html":"foo &lt;ref&gt;bar&lt;/ref&gt; baz"},"attrs":{}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
15069 <ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw="{"name":"references","attrs":{}}">
15070 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <ref>bar</ref> baz</li></ol>
15074 Ref: 15. ref-tags with identical names should get identical indexes
15078 A1 <ref name="a">foo</ref> A2 <ref name="a" />
15079 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
15083 <p>A1 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span> A2 <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span>
15084 B1 <span about="#mwt7" class="reference" data-mw='{"name":"ref","attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span> B2 <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span></p>
15086 <ol about="#mwt10" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy">↑ <a href="#cite_ref-a-1-0">1.0</a> <a href="#cite_ref-a-1-1">1.1</a></span> foo</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy">↑ <a href="#cite_ref-b-2-0">2.0</a> <a href="#cite_ref-b-2-1">2.1</a></span> bar</li></ol>
15090 References: 1. references tag without any refs should be handled properly
15096 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"></ol>
15100 References: 2. references tag with group only outputs references from that group
15104 A <ref group="a">foo</ref>
15105 B <ref group="b">bar</ref>
15107 <references group='a' />
15109 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
15110 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"group":"b"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[b 1]</a></span></p>
15112 <ol about="#mwt6" class="references" data-mw='{"name":"references","attrs":{"group":"a"}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
15116 References: 3. ref list should be cleared after processing references
15128 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
15130 <ol about="#mwt4" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
15132 <p>B <span about="#mwt6" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
15134 <ol about="#mwt8" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> bar</li></ol>
15138 References: 4. only referenced group should be cleared after processing references
15142 A <ref group="a">afoo</ref>
15145 <references group="a"/>
15151 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"afoo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
15152 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bfoo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bfoo</ref>","dsr":[30,45,5,6]}'><a href="#cite_note-1">[1]</a></span></p>
15154 <ol about="#mwt6" class="references" data-mw='{"name":"references","attrs":{"group":"a"}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> afoo</li></ol>
15156 <p>C <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"cfoo"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span></p>
15158 <ol about="#mwt10" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> bfoo</li><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> cfoo</li></ol>
15162 References: 5. ref tags in references should be processed while ignoring all other content
15167 B <ref name="b">bar</ref>
15170 <ref name="a">foo</ref>
15171 This should just get lost.
15174 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span>
15175 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span></p>
15177 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","body":{"extsrc":"<ref name=\"a\">foo</ref>\nThis should just get lost.","html":"<span about=\"#mwt8\" class=\"reference\" data-mw=\"{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;foo&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;a&quot;}}\" rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-a-1\">[1]</a></span>"},"attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy"><a href="#cite_ref-a-1-0">↑</a></span> foo</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> bar</li></ol>
15181 References: 6. <references /> from a transclusion
15185 {{echo|<references />}}
15187 <ol class="references" about="#mwt2" typeof="mw:Transclusion" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references />"}},"i":0}'></ol>
15191 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
15195 A <ref>foo bar for a</ref>
15201 <ref name="b">foo</ref>
15204 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo bar for a"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
15205 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span></p>
15207 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo bar for a</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> </li></ol>
15209 <ol class="references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","body":{"extsrc":"<ref name=\"b\">foo</ref>","html":"\n<span about=\"#mwt10\" class=\"reference\" data-mw=\"{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;foo&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;b&quot;}}\" rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-b-1\">[1]</a></span>\n"},"attrs":{}}'><li about="#cite_note-b-1" id="cite_note-b-1"><span rel="mw:referencedBy">↑</span> foo</li></ol>
15213 #### ----------------------------------------------------------------
15214 #### The following section of tests are primarily to test
15215 #### wikitext escaping capabilities of Parsoid. Given that
15216 #### escaping can be done any number of ways, the wikitext (input)
15217 #### is always adjusted to reflect how Parsoid adds nowiki
15220 #### We are marking several tests as parsoid-only since the
15221 #### HTML in the result section is different from what the
15222 #### PHP parser generates for it.
15223 #### ----------------------------------------------------------------
15226 #### --------------- Headings ---------------
15228 #### 1. Nested inside html <h1>=foo=</h1>
15229 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
15230 #### 3. Nested inside html with wikitext split by html tags
15231 #### 4. No escape needed
15232 #### 5. Empty headings <h1></h1>
15233 #### 6. Heading chars in SOL context
15234 #### ----------------------------------------
15236 Headings: 0. Unnested
15240 <nowiki>=foo=</nowiki>
15242 <nowiki> =foo= </nowiki>
15244 <nowiki>=foo=</nowiki>
15246 =foo''a''<nowiki>=</nowiki>
15248 <p><span typeof="mw:Nowiki">=foo=</span></p>
15250 <p><span typeof="mw:Nowiki"> =foo= </span>
15252 <span typeof="mw:Nowiki">=foo=</span></p>
15254 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
15258 Headings: 1. Nested inside html
15262 =<nowiki>=foo=</nowiki>=
15264 ==<nowiki>=foo=</nowiki>==
15266 ===<nowiki>=foo=</nowiki>===
15268 ====<nowiki>=foo=</nowiki>====
15270 =====<nowiki>=foo=</nowiki>=====
15272 ======<nowiki>=foo=</nowiki>======
15274 <h1><span typeof="mw:Nowiki">=foo=</span></h1>
15275 <h2><span typeof="mw:Nowiki">=foo=</span></h2>
15276 <h3><span typeof="mw:Nowiki">=foo=</span></h3>
15277 <h4><span typeof="mw:Nowiki">=foo=</span></h4>
15278 <h5><span typeof="mw:Nowiki">=foo=</span></h5>
15279 <h6><span typeof="mw:Nowiki">=foo=</span></h6>
15283 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
15288 <nowiki>*</nowiki>bar
15294 <nowiki>=bar=</nowiki>
15302 Headings: 3. Nested inside html with wikitext split by html tags
15306 =='''bold'''<nowiki>foo=</nowiki>=
15308 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
15312 Headings: 4a. No escaping needed (testing just h1 and h2)
15330 =<nowiki>=</nowiki>=
15338 <h1><i>=</i>foo=</h1>
15339 <h1><span typeof="mw:Nowiki">=</span></h1>
15343 Headings: 4b. No escaping needed (inside p-tags)
15358 Headings: 5. Empty headings
15370 =====<nowiki/>=====
15372 ======<nowiki/>======
15383 Headings: 6a. Heading chars in SOL context (with trailing spaces)
15387 <nowiki>=a=</nowiki>
15389 <nowiki>=a=</nowiki>
15391 <nowiki>=a=</nowiki>
15393 <nowiki>=a=</nowiki>
15402 Headings: 6b. Heading chars in SOL context (with trailing newlines)
15430 Headings: 6c. Heading chars in SOL context (leading newline break)
15435 <nowiki>=b=</nowiki>
15442 Headings: 6d. Heading chars in SOL context (with interspersed comments)
15446 <!--c0--><nowiki>=a=</nowiki>
15448 <nowiki>=a=</nowiki> <!--c2--> <!--c3-->
15450 <p><!--c0-->=a=</p>
15451 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
15455 Headings: 6d. Heading chars in SOL context (No escaping needed)
15464 #### --------------- Lists ---------------
15465 #### 0. Outside nests (*foo, etc.)
15466 #### 1. Nested inside html <ul><li>*foo</li></ul>
15467 #### 2. Inside definition lists
15468 #### 3. Only bullets at start should be escaped
15469 #### 4. No escapes needed
15470 #### 5. No unnecessary escapes
15471 #### 6. Escape bullets in SOL position
15472 #### 7. Escape bullets in a multi-line context
15473 #### ----------------------------------------
15476 Lists: 0. Outside nests
15478 <nowiki>*</nowiki>foo
15480 <nowiki>#</nowiki>foo
15488 Lists: 1. Nested inside html
15490 *<nowiki>*foo</nowiki>
15492 *<nowiki>#foo</nowiki>
15494 *<nowiki>:foo</nowiki>
15496 *<nowiki>;foo</nowiki>
15498 #<nowiki>*foo</nowiki>
15500 #<nowiki>#foo</nowiki>
15502 #<nowiki>:foo</nowiki>
15504 #<nowiki>;foo</nowiki>
15526 Lists: 2. Inside definition lists
15528 ;<nowiki>;foo</nowiki>
15530 ;<nowiki>:foo</nowiki>
15532 ;<nowiki>:foo</nowiki>
15535 :<nowiki>:foo</nowiki>
15550 Lists: 3. Only bullets at start of text should be escaped
15552 *<nowiki>*foo*bar</nowiki>
15554 *<nowiki>*foo</nowiki>''it''*bar
15558 <ul><li>*foo<i>it</i>*bar
15564 Lists: 4. No escapes needed
15576 <ul><li><i>foo</i>*bar
15578 <ul><li><a rel="mw:WikiLink" href="Foo">Foo</a>: bar
15583 Lists: 5. No unnecessary escapes
15585 * bar <span><nowiki>[[foo]]</nowiki></span>
15587 *=bar <span><nowiki>[[foo]]</nowiki></span>
15589 *[[bar <span><nowiki>[[foo]]</nowiki></span>
15591 *]]bar <span><nowiki>[[foo]]</nowiki></span>
15593 *=bar <span>foo]]</span>=
15597 <ul><li> bar <span>[[foo]]</span>
15599 <ul><li>=bar <span>[[foo]]</span>
15601 <ul><li>[[bar <span>[[foo]]</span>
15603 <ul><li>]]bar <span>[[foo]]</span>
15605 <ul><li>=bar <span>foo]]</span>=
15607 <ul><li> <s></s>: a
15613 Lists: 6. Escape bullets in SOL position
15617 <!--cmt--><nowiki>*foo</nowiki>
15619 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
15623 Lists: 7. Escape bullets in a multi-line context
15626 <nowiki>*</nowiki>b
15633 #### --------------- HRs ---------------
15634 #### 1. Single line
15635 #### -----------------------------------
15638 HRs: 1. Single line
15642 ----<nowiki>----</nowiki>
15646 <hr><span typeof="mw:Nowiki">----</span>
15651 #### --------------- Tables ---------------
15652 #### 1a. Simple example
15653 #### 1b. No escaping needed (!foo)
15654 #### 1c. No escaping needed (|foo)
15655 #### 1d. No escaping needed (|}foo)
15657 #### 2a. Nested in td (<td>foo|bar</td>)
15658 #### 2b. Nested in td (<td>foo||bar</td>)
15659 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
15661 #### 3a. Nested in th (<th>foo!bar</th>)
15662 #### 3b. Nested in th (<th>foo!!bar</th>)
15663 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
15667 #### 4c. No escaping needed
15668 #### --------------------------------------
15671 Tables: 1a. Simple example
15682 Tables: 1b. No escaping needed
15691 Tables: 1c. No escaping needed
15700 Tables: 1d. No escaping needed
15709 Tables: 2a. Nested in td
15714 |<nowiki>foo|bar</nowiki>
15718 <td><span typeof="mw:Nowiki">foo|bar</span></td></tr></tbody></table>
15722 Tables: 2b. Nested in td
15727 |<nowiki>foo||bar</nowiki>
15728 |''it''<nowiki>foo||bar</nowiki>
15732 <td><span typeof="mw:Nowiki">foo||bar</span></td>
15733 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
15737 Tables: 2c. Nested in td -- no escaping needed
15745 <table><tbody><tr><td>foo!!bar
15746 </td></tr></tbody></table>
15751 Tables: 3a. Nested in th
15759 <table><tbody><tr><th>foo!bar
15760 </th></tr></tbody></table>
15765 Tables: 3b. Nested in th
15770 !<nowiki>foo!!bar</nowiki>
15774 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
15779 Tables: 3c. Nested in th -- no escaping needed
15784 !<nowiki>foo||bar</nowiki>
15788 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
15792 Tables: 4a. Escape -
15800 |<nowiki>-bar</nowiki>
15804 <tr><th>-bar</th></tr>
15806 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
15810 Tables: 4b. Escape +
15818 |<nowiki>+bar</nowiki>
15822 <tr><th>+bar</th></tr>
15824 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
15828 Tables: 4c. No escaping needed
15847 <tr><td>foo-bar</td><td>foo+bar</td></tr>
15848 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
15856 ### SSS FIXME: Disabled right now because accurate html2wt
15857 ### on this snippet requires data-parsoid flags that we've
15858 ### stripped out of these tests. We should scheme how we
15859 ### we want to handle these kind of tests that require
15860 ### data-parsoid flags for accurate html2wt serialization
15863 Tables: 4d. No escaping needed
15881 #### --------------- Links ----------------
15882 #### 1. Quote marks in link text
15883 #### 2. Wikilinks: Escapes needed
15884 #### 3. Wikilinks: No escapes needed
15885 #### 4. Extlinks: Escapes needed
15886 #### 5. Extlinks: No escapes needed
15887 #### --------------------------------------
15889 Links 1. Quote marks in link text
15893 [[Foo|Foo<nowiki>''boo''</nowiki>]]
15895 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
15899 Links 2. WikiLinks: Escapes needed
15903 [[Foo|<nowiki>[Foobar]</nowiki>]]
15904 [[Foo|<nowiki>Foobar]</nowiki>]]
15905 [[Foo|x [Foobar] x]]
15906 [[Foo|<nowiki>x [http://google.com g] x</nowiki>]]
15907 [[Foo|<nowiki>[[Bar]]</nowiki>]]
15908 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
15909 [[Foo|<nowiki>|Bar</nowiki>]]
15910 [[Foo|<nowiki>]]bar</nowiki>]]
15911 [[Foo|<nowiki>[[bar</nowiki>]]
15912 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
15914 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
15915 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
15916 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
15917 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
15918 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
15919 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
15920 <a href="Foo" rel="mw:WikiLink">|Bar</a>
15921 <a href="Foo" rel="mw:WikiLink">]]bar</a>
15922 <a href="Foo" rel="mw:WikiLink">[[bar</a>
15923 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
15927 Links 3. WikiLinks: No escapes needed
15934 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
15935 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
15939 Links 4. ExtLinks: Escapes needed
15943 [http://google.com <nowiki>[google]</nowiki>]
15944 [http://google.com <nowiki>google]</nowiki>]
15946 <a href="http://google.com" rel="mw:ExtLink">[google]</a>
15947 <a href="http://google.com" rel="mw:ExtLink">google]</a>
15951 Links 5. ExtLinks: No escapes needed
15955 [http://google.com [google]
15957 <a href="http://google.com" rel="mw:ExtLink">[google</a>
15960 #### --------------- Quotes ---------------
15961 #### 1. Quotes inside <b> and <i>
15962 #### 2. Link fragments separated by <i> and <b> tags
15963 #### 3. Link fragments inside <i> and <b>
15964 #### 4. No escaping needed
15965 #### --------------------------------------
15967 1. Quotes inside <b> and <i>
15969 parsoid=html2wt,wt2wt
15971 ''<nowiki>'foo'</nowiki>''
15972 ''<nowiki>''foo''</nowiki>''
15973 ''<nowiki>'''foo'''</nowiki>''
15975 '''<nowiki>'foo'</nowiki>'''
15976 '''<nowiki>''foo''</nowiki>'''
15977 '''<nowiki>'''foo'''</nowiki>'''
15978 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
15979 '''foo'''<nowiki/>'s
15982 '<nowiki/>''foo''<nowiki/>'
15984 '''foo'''<nowiki/>'
15985 '<nowiki/>'''foo'''<nowiki/>'
15994 <b>foo'<i>bar'</i>baz</b>
16005 2. Link fragments separated by <i> and <b> tags
16007 [[''foo''<nowiki>hello]]</nowiki>
16009 [['''foo'''<nowiki>hello]]</nowiki>
16011 <p>[[<i>foo</i>hello]]
16012 </p><p>[[<b>foo</b>hello]]
16017 3. Link fragments inside <i> and <b>
16018 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
16019 this is one of the shortcomings of this format)
16021 ''[[foo''<nowiki>]]</nowiki>
16023 '''[[foo'''<nowiki>]]</nowiki>
16026 </p><p><b>[[foo</b>]]
16031 4. No escaping needed
16033 '<span>''bar''</span>'
16034 '<span>'''bar'''</span>'
16036 <p>'<span><i>bar</i></span>'
16037 '<span><b>bar</b></span>'
16041 #### ----------- Paragraphs ---------------
16042 #### 1. No unnecessary escapes
16043 #### --------------------------------------
16046 1. No unnecessary escapes
16048 bar <span><nowiki>[[foo]]</nowiki></span>
16050 =bar <span><nowiki>[[foo]]</nowiki></span>
16052 [[bar <span><nowiki>[[foo]]</nowiki></span>
16054 ]]bar <span><nowiki>[[foo]]</nowiki></span>
16056 =bar <span>foo]]</span><nowiki>=</nowiki>
16058 <p>bar <span>[[foo]]</span>
16059 </p><p>=bar <span>[[foo]]</span>
16060 </p><p>[[bar <span>[[foo]]</span>
16061 </p><p>]]bar <span>[[foo]]</span>
16062 </p><p>=bar <span>foo]]</span>=
16066 #### ----------------------- PRE --------------------------
16067 #### 1. Leading whitespace in SOL context should be escaped
16068 #### ------------------------------------------------------
16070 1. Leading whitespace in SOL context should be escaped
16074 <nowiki> </nowiki>a
16076 <nowiki> </nowiki> a
16078 <nowiki> </nowiki>a(tab)
16080 <nowiki> </nowiki> a
16082 <nowiki> </nowiki> a
16085 <nowiki> </nowiki>b
16088 <nowiki> </nowiki>b
16091 <nowiki> </nowiki> b
16097 <p><!--cmt--> a</p>
16106 #### --------------- HTML tags ---------------
16109 #### 3. multi-line html tag
16110 #### -----------------------------------------
16116 <a href="http://google.com">google</a>
16118 <a href="http://google.com">google</a>
16124 <nowiki><div>foo</div>
16125 <div style="color:red">foo</div></nowiki>
16127 <p><div>foo</div>
16128 <div style="color:red">foo</div>
16133 3. multi-line html tag
16148 <nowiki><ref>foo</ref></nowiki>
16150 <p><ref>foo</ref>
16154 #### --------------- Others ---------------
16158 <nowiki>foo</nowiki>
16160 <p><nowiki>foo</nowiki>
16164 ## The quote-char in the input is necessary for triggering the bug
16166 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
16168 parsoid=wt2wt,html2wt
16177 Tag-like HTML structures are passed through as text
16199 </p><p>1<d e>f
16204 # This was a bug in the PHP parser (see bug 17663 and its dups,
16205 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
16207 Tag names followed by punctuation should not be recognized as tags
16211 <p><s.ome> text
16216 HTML tag with necessary entities in attributes
16218 <span title="&amp;">foo</span>
16220 <p><span title="&amp;">foo</span>
16225 HTML tag with 'unnecessary' entity encoding in attributes
16227 <span title="&">foo</span>
16229 <p><span title="&">foo</span>
16234 HTML tag with broken attribute value quoting
16236 <span title="Hello world>Foo</span>
16238 <p><span>Foo</span>
16243 Parsoid-only: HTML tag with broken attribute value quoting
16247 <span title="Hello world>Foo</span>
16249 <p><span title="Hello world">Foo</span>
16254 Table with broken attribute value quoting
16257 | title="Hello world|Foo
16268 Table with broken attribute value quoting on consecutive lines
16271 | title="Hello world|Foo
16272 | style="color:red|Bar
16285 Parsoid-only: Table with broken attribute value quoting on consecutive lines
16290 | title="Hello world|Foo
16291 | style="color:red|Bar
16296 <td title="Hello world">Foo
16297 </td><td style="color: red">Bar
16298 </td></tr></tbody></table>
16303 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
16313 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
16323 Accept empty td cell attribute
16326 | align="center" | foo || |
16331 <td align="center"> foo </td>
16338 Non-empty attributes in th-cells
16341 ! Foo !! style="color: red" | Bar
16347 <th style="color: red"> Bar
16353 Accept empty attributes in th-cells
16368 Empty table rows go away
16389 ### Parsoid-centric tests for testing RTing of inter-element separators
16390 ### Edge cases not tested by existing parser tests and specific to
16391 ### Parsoid-specific serialization strategies.
16395 RT-ed inter-element separators should be valid separators
16408 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
16409 (Parsoid-only since PHP parser relies on Tidy for correct output)
16425 Empty TD followed by TD with tpl-generated attribute
16430 |{{echo|style='color:red'}}|foo
16444 Indented table with an empty td
16463 Empty TR followed by a template-generated TR
16464 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
16466 parsoid=wt2html,wt2wt
16470 {{echo|<tr><td>foo</td></tr>}}
16476 <tr typeof="mw:Transclusion">
16477 <td>foo</td></tr></tbody></table>
16480 ## PHP and parsoid output differ for this, and since this is primarily
16481 ## for testing Parsoid's serializer, marking this Parsoid only
16483 Empty TR followed by mixed-ws-comment line should RT correctly
16497 <td> <!--c--></td></tr>
16499 <td><!--c--> <!--d--></td></tr>
16505 Multi-line image caption generated by templates with/without trailing newlines
16509 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
16510 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
16512 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC</div></div></div>
16513 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC\n\n</div></div></div>
16517 ## PHP emits broken html for this, and since this is primarily
16518 ## a Parsoid serializer test, marking this Parsoid only
16520 Improperly nested inline or quotes tags with whitespace in between
16524 <span> <s>x</span> </s>
16527 <p><span> <s>x</s></span><s> </s>
16528 <b> <i>x</i></b><i> </i>
16533 Encapsulate protected attributes from wt
16537 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
16539 <body><div data-x-typeof="mw:placeholder stuff" data-x-data-parsoid="weird" data-x-data-parsoid-other="no" data-x-about="time" data-x-rel="mw:true">foo</div>
16543 # -----------------------------------------------------------------
16544 # The following section of tests are primarily to spec requirements
16545 # around serialization of new/edited content.
16547 # All these tests are marked Parsoid html2wt and html2html only
16548 # ----------------------------------------------------------------
16551 Image: Modifying size of an image
16555 [[Image:Wiki.png|230x230px]]
16557 <p data-parsoid='{"dsr":[0,24,0,0]}'><span typeof="mw:Image" data-parsoid='{"optList":[{"ck":"width","ak":"100px"}],"cacheKey":"[[Image:Wiki.png|100px]]","img":{"h":115,"w":100,"wdset":true},"dsr":[0,24,null,null]}'><a href="./File:Wiki.png" data-parsoid='{"a":{"href":"./File:Wiki.png"}}'><img resource="./File:Wiki.png" src="//upload.wikimedia.org/wikipedia/en/thumb/b/bc/Wiki.png/100px-Wiki.png" height="230" width="200" data-parsoid='{"a":{"resource":"./File:Wiki.png"},"sa":{"resource":"Image:Wiki.png"}}'></a></span></p>
16561 Image: New block level image should have \n before and after
16566 [[File:Wiki.png|right|thumb|150x150px]]
16569 <p>123</p><figure typeof="mw:Image/Thumb" class="mw-halign-right"><a href="./File:Wiki.png"><img src="http://192.168.142.128/mw/images/thumb/b/bc/Wiki.png/131px-Wiki.png" width="131" height="150" resource="./File:Wiki.png"></a></figure><p>456</p>
16573 Lists: Add space after bullets
16580 * <span> baz</span>
16585 <li><span> baz</span></li>
16590 Parsoid: Serialize positional parameters with = in them as named parameter
16596 <p about="#mwt1" typeof="mw:Transclusion"
16597 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}'
16601 # -----------------------------------------------------------------
16602 # End of section for Parsoid-only html2wt tests for serialization
16604 # -----------------------------------------------------------------
16611 Try for 100% code coverage