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>
161 This is a simple paragraph.
163 <p>This is a simple paragraph.
168 Paragraphs with extra newline spacing
191 Paragraphs with newline spacing with comment lines in between
199 <!--foo--><!--More than 1 comment, still stripped-->
203 <!--foo--> <!----> <!-- bar -->
264 Paragraphs with newline spacing with non-empty white-space lines in between
291 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
299 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
338 Extra newlines: More paragraphs with indented comment
353 Extra newlines followed by heading
368 <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>
369 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
372 <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>
377 Extra newlines between heading and content are swallowed
385 <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>
386 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
393 http://fr.wikipedia.org/wiki/🍺
394 <!-- EasterEgg we love beer, better be able be able to link to it -->
396 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
416 * plain''italic''plain
417 * plain''italic''plain''italic''plain
418 * plain'''bold'''plain
419 * plain'''bold'''plain'''bold'''plain
420 * plain''italic''plain'''bold'''plain
421 * plain'''bold'''plain''italic''plain
422 * plain''italic'''bold-italic'''italic''plain
423 * plain'''bold''bold-italic''bold'''plain
424 * plain'''''bold-italic'''italic''plain
425 * plain'''''bold-italic''bold'''plain
426 * plain''italic'''bold-italic'''''plain
427 * plain'''bold''bold-italic'''''plain
428 * plain l'''italic''plain
429 * plain l''''bold''' plain
432 </li><li> plain<i>italic</i>plain
433 </li><li> plain<i>italic</i>plain<i>italic</i>plain
434 </li><li> plain<b>bold</b>plain
435 </li><li> plain<b>bold</b>plain<b>bold</b>plain
436 </li><li> plain<i>italic</i>plain<b>bold</b>plain
437 </li><li> plain<b>bold</b>plain<i>italic</i>plain
438 </li><li> plain<i>italic<b>bold-italic</b>italic</i>plain
439 </li><li> plain<b>bold<i>bold-italic</i>bold</b>plain
440 </li><li> plain<i><b>bold-italic</b>italic</i>plain
441 </li><li> plain<b><i>bold-italic</i>bold</b>plain
442 </li><li> plain<i>italic<b>bold-italic</b></i>plain
443 </li><li> plain<b>bold<i>bold-italic</i></b>plain
444 </li><li> plain l'<i>italic</i>plain
445 </li><li> plain l'<b>bold</b> plain
450 # this example taken from the simple/Moon article
452 Italics and possessives
454 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
456 <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
461 ### 2-quote opening sequence tests
464 Italics and bold: 2-quote opening sequence: (2,2)
474 Italics and bold: 2-quote opening sequence: (2,3)
484 Italics and bold: 2-quote opening sequence: (2,4)
494 Italics and bold: 2-quote opening sequence: (2,5) (php)
503 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
505 Italics and bold: 2-quote opening sequence: (2,5) (parsoid)
517 ### 3-quote opening sequence tests
521 Italics and bold: 3-quote opening sequence: (3,2)
531 Italics and bold: 3-quote opening sequence: (3,3)
541 Italics and bold: 3-quote opening sequence: (3,4)
551 Italics and bold: 3-quote opening sequence: (3,5) (php)
560 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
562 Italics and bold: 3-quote opening sequence: (3,5) (parsoid)
574 ### 4-quote opening sequence tests
578 Italics and bold: 4-quote opening sequence: (4,2)
588 Italics and bold: 4-quote opening sequence: (4,3)
598 Italics and bold: 4-quote opening sequence: (4,4)
608 Italics and bold: 4-quote opening sequence: (4,5) (php)
617 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
619 Italics and bold: 4-quote opening sequence: (4,5) (parsoid)
625 <p>'<b>foo<i></i></b>
631 ### 5-quote opening sequence tests
635 Italics and bold: 5-quote opening sequence: (5,2) (php)
644 # Parsoid reverses the nesting order, compared to the PHP parser
646 Italics and bold: 5-quote opening sequence: (5,2) (parsoid)
658 Italics and bold: 5-quote opening sequence: (5,3)
668 Italics and bold: 5-quote opening sequence: (5,4)
672 <p><i><b>foo'</b></i>
678 Italics and bold: 5-quote opening sequence: (5,5)
687 ### multiple quote sequences in a line
690 Italics and bold: multiple quote sequences: (2,4,2)
694 <p><i>foo'<b>bar</b></i>
700 Italics and bold: multiple quote sequences: (2,4,3)
704 <p><i>foo'<b>bar</b></i>
710 Italics and bold: multiple quote sequences: (2,4,4)
714 <p><i>foo'<b>bar'</b></i>
720 Italics and bold: multiple quote sequences: (3,4,2) (php)
729 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
731 Italics and bold: multiple quote sequences: (3,4,2) (parsoid)
737 <p><b>foo'</b>bar<i></i>
743 Italics and bold: multiple quote sequences: (3,4,3) (php)
752 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
754 Italics and bold: multiple quote sequences: (3,4,3) (parsoid)
760 <p><b>foo'</b>bar<b></b>
765 ### other quote tests
768 Italics and bold: other quote tests: (2,3,5)
770 ''this is about '''foo's family'''''
772 <p><i>this is about <b>foo's family</b></i>
778 Italics and bold: other quote tests: (2,(3,3),2)
780 ''this is about '''foo's''' family''
782 <p><i>this is about <b>foo's</b> family</i>
788 Italics and bold: other quote tests: (3,2,3,2)
790 '''this is about ''foo'''s family''
792 <p><b>this is about <i>foo</i></b><i>s family</i>
797 # The Parsoid team believes the PHP parser's output on this test is wrong.
798 # It only checks for convert-to-bold-on-single-character-word when the word
799 # matches with a bold tag ("'''") that is *odd* in the list of quote tokens.
800 # This means that the bold token in position 2 (0-indexed) gets converted by
801 # parsoid, but doesn't get changed by the PHP parser.
803 Italics and bold: other quote tests: (3,2,3,3) (php)
807 '''this is about ''foo'''s family'''
809 <p>'<i>this is about </i>foo<b>s family</b>
812 # This is the output the Parsoid team believes to be correct.
814 Italics and bold: other quote tests: (3,2,3,3) (parsoid)
818 '''this is about ''foo'''s family'''
820 <p><b>this is about <i>foo'</i>s family</b>
826 Italics and bold: other quote tests: (3,(2,2),3)
828 '''this is about ''foo's'' family'''
830 <p><b>this is about <i>foo's</i> family</b>
836 Italicized possessive
838 The ''[[Main Page]]'''s talk page.
840 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
845 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
846 (Requires tidy for PHP parser output to be fixed up)
848 parsoid=wt2html,wt2wt
856 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
857 <td><i>a</i></td><td><i>b</i></td></tr>
866 Non-html5 tags should be accepted
868 <center>''foo''</center>
871 <strike>''foo''</strike>
874 <center><i>foo</i></center>
875 <p><big><i>foo</i></big>
876 <font><i>foo</i></font>
877 <strike><i>foo</i></strike>
883 <wbr> is valid wikitext (bug 52468)
891 # <strike> is HTML4, <s> is HTML4/5.
893 <s> or <strike> for strikethrough
895 <strike>strike</strike>
899 <p><strike>strike</strike>
905 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
907 <b→> doesn't work! </b>
909 <bä> doesn't work! </b>
911 <boo> works fine </b>
919 <p><b→> doesn't work! </b>
920 </p><p><bä> doesn't work! </b>
921 </p><p><boo> works fine </b>
922 </p><p><s.foo>foo</s>
923 </p><p><s.foo>s.foo</s.foo>
924 </p><p><sub-ID#1>
929 ### Special characters
933 Bare pipe character (bug 52363)
942 Bare pipe character from a template (bug 52363)
951 ### <nowiki> test cases
955 <nowiki> unordered list
957 <nowiki>* This is not an unordered list item.</nowiki>
959 <p>* This is not an unordered list item.
966 <nowiki>Lorem ipsum dolor
987 :There is not nowiki.
988 :There is <nowiki>nowiki</nowiki>.
990 #There is not nowiki.
991 #There is <nowiki>nowiki</nowiki>.
993 *There is not nowiki.
994 *There is <nowiki>nowiki</nowiki>.
996 <dl><dd>There is not nowiki.
997 </dd><dd>There is nowiki.
999 <ol><li>There is not nowiki.
1000 </li><li>There is nowiki.
1002 <ul><li>There is not nowiki.
1003 </li><li>There is nowiki.
1009 Entities inside <nowiki>
1011 <nowiki><</nowiki>
1018 Entities inside template parameters
1024 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}'>–</span>
1032 Comments and Indent-Pre
1034 <!-- comment 1 --> asdf
1036 <!-- comment 1 --> asdf
1039 <!-- comment 1 --> asdf
1040 <!-- comment 2 -->xyz
1042 <!-- comment 1 --> asdf
1043 <!-- comment 2 --> xyz
1099 asdf<!-- comment 1 -->jkl
1109 <!-- foo --> b <!-- bar -->
1123 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1129 Comment semantics and delimiters
1131 <!-- --><!----><!-----><!------>
1137 Comment semantics and delimiters, redux
1139 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1140 -- foo -- funky huh? ... -->
1146 Comment semantics and delimiters: directors cut
1148 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1149 everything starting with < followed by !-- until the first -- and > we see,
1150 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1158 Comment semantics: nesting
1160 <!--<!-- no, we're not going to do anything fancy here -->-->
1167 Comment semantics: unclosed comment at end
1169 <!--This comment will run out to the end of the document
1175 Comment in template title
1184 Comment on its own line post-expand
1196 Comment on its own line post-expand with non-significant whitespace
1208 ### paragraph wrapping tests
1222 Block tag on one line
1234 Block tag on both lines
1246 Multiple lines without block tags
1264 Empty lines between lines with block tags
1294 ### Preformatted text
1303 And a [[Main Page|link]]
1309 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1314 Tabs don't trigger preformatted text
1318 This is preformatted text.
1324 <pre>This is preformatted text.
1330 Ident preformatting with inline content
1341 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1358 Regression with preformatted in <center>
1371 # Expected output in the following test is not really expected (there should be
1372 # <pre> in the output) -- it's only testing for well-formedness.
1374 Bug 6200: Preformatted in <blockquote>
1387 <pre> with attributes (bug 3202)
1389 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1391 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1396 <pre> with width attribute (bug 3202)
1398 <pre width="8">Narrow screen goodies</pre>
1400 <pre width="8">Narrow screen goodies</pre>
1405 <pre> with forbidden attribute (bug 3202)
1407 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1409 <pre width="8">Narrow screen goodies</pre>
1414 Entities inside <pre>
1423 <pre> with forbidden attribute values (bug 3202)
1425 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1427 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1432 <nowiki> inside <pre> (bug 13238)
1440 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1448 <pre><nowiki>Foo</nowiki></pre>
1453 <nowiki> and <pre> preference (first one wins)
1484 </pre> inside nowiki
1486 <nowiki></pre></nowiki>
1493 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1501 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1511 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1523 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1544 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1548 {{echo| foo}}{{echo| bar}}
1553 {{echo|<!--cmt--> foo}}
1555 <!--cmt-->{{echo| foo}}
1557 {{echo|{{echo| }}bar}}
1575 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1612 Templates: Single-line variant of parameter whitespace stripping test
1618 {{echo|{{echo| a}}}}
1620 {{echo|1={{echo| a}}}}
1633 Templates: Strip whitespace from named parameters, but not positional ones
1661 Templates: Dont strip whitespace from whitespace/comment-only arguments
1665 {{echo| <!--cmt--> }}
1672 Templates: Parsoid parameter escaping test 1
1676 {{echo|[foo]|{{echo|[bar]}}}}
1678 <p about="#mwt1" typeof="mw:Transclusion"
1679 data-mw="{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}">[foo]</p>
1683 Parsoid: Pipes in external links in template parameter
1687 {{echo|[{{echo|http://example.com}} link]}}
1689 <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>
1693 Parsoid: pipe in transclusion parameter
1697 {{echo|http://foo.com/a|b}}
1699 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
1700 typeof="mw:Transclusion"
1701 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>
1705 Parsoid: Pipe in external link target and content in template parameter
1707 parsoid=html2wt,wt2wt
1709 {{echo|[http://foo.com/a|b a|b]}}
1711 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
1712 typeof="mw:Transclusion"
1713 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},
1714 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}'>a|b</a></p>
1718 Templates: Dont escape already nowiki-escaped text in template parameters
1720 parsoid=html2wt,wt2wt
1722 {{echo|foo<nowiki>|</nowiki>bar}}
1723 {{echo|<nowiki><div></nowiki>}}
1724 {{echo|<nowiki></nowiki>}}
1726 <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>
1727 <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>
1728 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt3" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki></nowiki>"}},"i":0}'></span>
1733 ### Parsoid-centric tests for testing RT edge cases for pre
1737 1a. Indent-Pre and Comments
1750 1b. Indent-Pre and Comments
1763 1c. Indent-Pre and Comments
1776 1d. Indent-Pre and Comments
1777 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
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)
1909 4. Multiple spaces at start-of-line
1928 5. White-space in indent-pre
1929 NOTE: the white-space char on 2nd line is significant
1942 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
1965 7a. Indent-pre and category links
1967 parsoid=wt2html,wt2wt
1969 [[Category:foo]] <!-- No pre-wrapping -->
1970 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
1972 <span typeof="mw:Transclusion"> </span>
1976 7b. Indent-pre and category links
1978 parsoid=wt2html,wt2wt
1981 [[Category:foo]] {{echo|b}}
1983 <pre> a <span typeof="mw:Transclusion">b</span>
1988 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
1992 HTML-pre: 1. embedded newlines
2028 HTML-pre: 2: indented text
2041 HTML-pre: 3: other wikitext
2062 ### Definition lists
2069 <dl><dt> name </dt><dd> Definition
2075 Definition list for indentation only
2079 <dl><dd> Indented text
2085 Definition list with no space
2089 <dl><dt>name</dt><dd>Definition
2095 Definition list with URL link
2097 ; http://example.com/ : definition
2099 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt><dd> definition
2105 Definition list with bracketed URL link
2107 ;[http://www.example.com/ Example]:Something about it
2109 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt><dd>Something about it
2115 Definition list with wikilink containing colon
2117 ; [[Help:FAQ]]: The least-read page on Wikipedia
2119 <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
2124 # At Brion's and JeLuF's insistence... :)
2126 Definition list with news link containing colon
2128 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
2130 <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!
2136 Malformed definition list with colon
2138 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
2140 <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
2146 Definition lists: colon in external link text
2148 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
2150 <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
2156 Definition lists: colon in HTML attribute
2158 ;<b style="display: inline">bold</b>
2160 <dl><dt><b style="display: inline">bold</b>
2166 Definition lists: self-closed tag
2168 ;one<br/>two : two-line fun
2170 <dl><dt>one<br />two </dt><dd> two-line fun
2176 Bug 11748: Literal closing tags
2180 <dd>test test test test test</dd>
2182 <dd>test test test test test</dd>
2187 <dd>test test test test test</dd>
2189 <dd>test test test test test</dd>
2195 Definition and unordered list using wiki syntax nested in unordered list using html tags.
2198 ; term : description
2204 <dl><dt> term </dt><dd> description
2215 Definition list with empty definition and following paragraph
2220 <dl><dt> term</dt><dd>
2227 Nested definition lists using html syntax
2244 Definition Lists: No nesting: Multiple dd's
2258 Definition Lists: Indentation: Regular
2274 Definition Lists: Indentation: Missing 1st level
2288 Definition Lists: Indentation: Multi-level indent
2292 <dl><dd><dl><dd><dl><dd>i3
2300 Definition Lists: Hacky use to indent tables
2307 should be left alone
2309 <dl><dd><dl><dd><table>
2314 </td></tr></table></dd></dl></dd></dl>
2316 should be left alone
2319 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
2320 ## as an empty dt item. It also ignores all but the last ";" when followed
2321 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
2322 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
2325 ## Ex: ";;t2 ::d2" is transformed into:
2337 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
2338 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
2349 ## All Parsoid only definition list tests have this difference.
2351 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
2352 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
2355 Table / list interaction: indented table with lists in table contents
2377 </td></tr></table></dd></dl>
2382 Table / list interaction: lists nested in tables nested in indented lists
2407 </td></tr></table></dd></dl>
2415 Definition Lists: Nesting: Multi-level (Parsoid only)
2445 Definition Lists: Nesting: Test 2 (Parsoid only)
2465 Definition Lists: Nesting: Test 3 (Parsoid only)
2493 Definition Lists: Nesting: Test 4
2498 <dl><dd><dl><dd><dl><dt>t3
2507 ## The Parsoid team believes the following three test exposes a
2508 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
2509 ## wrong to close the <dl> after the <dt> containing the <ul>.)
2511 Definition Lists: Mixed Lists: Test 1 (php)
2519 <dl><dd><dl><dt><ul><li> foo
2529 Definition Lists: Mixed Lists: Test 1 (parsoid)
2537 <dl><dd><dl><dt><ul><li> foo
2538 </li></ul></dt><dd><ul><li> bar
2539 </li></ul></dd><dt> baz</dt></dl></dd></dl>
2543 Definition Lists: Mixed Lists: Test 2
2557 Definition Lists: Mixed Lists: Test 3
2562 <ul><li><dl><dd><dl><dd><dl><dd> d1
2573 Definition Lists: Mixed Lists: Test 4
2578 <ul><li><dl><dt>d1 </dt><dd>d2
2579 </dd><dt>d3 </dt><dd>d4
2587 Definition Lists: Mixed Lists: Test 5
2602 Definition Lists: Mixed Lists: Test 6
2607 <ol><li><ul><li><dl><dd>d1
2619 Definition Lists: Mixed Lists: Test 7
2633 Definition Lists: Mixed Lists: Test 8
2649 Definition Lists: Mixed Lists: Test 9
2653 <ul><li><dl><dt>foo </dt><dd>bar
2661 Definition Lists: Mixed Lists: Test 10
2665 <ul><li><ol><li><dl><dt>foo </dt><dd>bar
2672 # The Parsoid team disagrees with the PHP parser's seemingly-random
2673 # rules regarding dd/dt on the next two tests. Parsoid is more
2674 # consistent, and recognizes the shared nesting and keeps the
2675 # still-open tags around until the nesting is complete.
2678 Definition Lists: Mixed Lists: Test 11 (php)
2685 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt><dd><ul><li><dl><dt><dl><dt>bar
2690 <dl><dt>boo </dt><dd>baz
2699 Definition Lists: Mixed Lists: Test 11 (parsoid)
2721 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2722 <dd data-parsoid='{"stx":"row"}'>bar</dd></dl></dt></dl></li></ul></dt>
2723 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2724 <dd data-parsoid='{"stx":"row"}'>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
2729 Definition Lists: Weird Ones: Test 1 (php)
2733 *#;*::;; foo : bar (who uses this?)
2735 <ul><li><ol><li><dl><dt> foo </dt><dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)
2747 Definition Lists: Weird Ones: Test 1 (parsoid)
2751 *#;*::;; foo : bar (who uses this?)
2768 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2769 <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>
2776 External links: non-bracketed
2778 Non-bracketed: http://example.com
2780 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2785 External links: numbered
2787 Numbered: [http://example.com]
2788 Numbered: [http://example.net]
2789 Numbered: [http://example.com]
2791 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
2792 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
2793 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
2798 External links: specified text
2800 Specified text: [http://example.com link]
2802 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
2807 External links: trail
2809 Linktrails should not work for external links: [http://example.com link]s
2811 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
2816 External links: dollar sign in URL
2818 http://example.com/1$2345
2820 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
2825 External links: dollar sign in URL (named)
2827 [http://example.com/1$2345]
2829 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
2834 External links: open square bracket forbidden in URL (bug 4377)
2836 http://example.com/1[2345
2838 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
2843 External links: open square bracket forbidden in URL (named) (bug 4377)
2845 [http://example.com/1[2345]
2847 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
2852 External links: nowiki in URL link text (bug 6230)
2854 [http://example.com/ <nowiki>''example site''</nowiki>]
2856 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
2861 External links: newline forbidden in text (bug 6230 regression check)
2863 [http://example.com/ first
2866 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
2872 External links: Pipe char between url and text
2874 [http://example.com | link]
2876 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
2881 External links: protocol-relative URL in brackets
2883 [//example.com/ Test]
2885 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
2890 External links: protocol-relative URL in brackets without text
2894 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
2899 External links: protocol-relative URL in free text is left alone
2903 <p>//example.com/Foo
2908 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
2910 foo//example.com/Foo
2912 <p>foo//example.com/Foo
2919 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2921 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2926 External image from https
2928 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2930 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2935 External image (when not allowed)
2937 wgAllowExternalImages=0
2939 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2941 <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>
2946 Link to non-http image, no img tag
2948 Link to non-http image, no img tag: ftp://example.com/test.jpg
2950 <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>
2955 External links: terminating separator
2957 Terminating separator: http://example.com/thing,
2959 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
2964 External links: intervening separator
2966 Intervening separator: http://example.com/1,2,3
2968 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
2973 External links: old bug with URL in query
2975 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
2977 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
2982 External links: old URL-in-URL bug, mixed protocols
2984 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
2986 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
2991 External links: URL in text
2993 URL in text: [http://example.com http://example.com]
2995 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3000 External links: Clickable images
3002 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
3004 <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>
3009 External links: raw ampersand
3011 Old & use: http://x&y
3013 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3018 External links: encoded ampersand
3020 Old & use: http://x&y
3022 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3027 External links: encoded equals (bug 6102)
3029 http://example.com/?foo=bar
3031 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
3036 External links: [raw ampersand]
3038 Old & use: [http://x&y]
3040 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3045 External links: [encoded ampersand]
3047 Old & use: [http://x&y]
3049 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3054 External links: [encoded equals] (bug 6102)
3056 [http://example.com/?foo=bar]
3058 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3063 External links: [IDN ignored character reference in hostname; strip it right off]
3065 [http://e‌xample.com/]
3067 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
3071 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
3072 # Where an external link could easily circumvent the sanitization of the text of
3073 # a link like this (where an IDN-ignore character is in the URL somewhere), this
3074 # test demands a higher standard. That's a bit strange.
3078 # http://example.com -> [http://example.com|http://example.com]
3079 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
3081 # The first example is sanitized, but the second is not. Any security benefits
3082 # from this production are trivial to circumvent. Either remove this test and
3083 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
3084 # the test accordingly.
3089 External links: IDN ignored character reference in hostname; strip it right off
3091 http://e‌xample.com/
3093 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
3098 External links: www.jpeg.org (bug 554)
3102 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
3107 External links: URL within URL (original bug 2)
3109 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
3111 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
3116 BUG 361: URL inside bracketed URL
3118 [http://www.example.com/foo http://www.example.com/bar]
3120 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
3125 BUG 361: URL within URL, not bracketed
3127 http://www.example.com/foo?=http://www.example.com/bar
3129 <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>
3134 BUG 289: ">"-token in URL-tail
3136 http://www.example.com/<hello>
3138 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
3143 BUG 289: literal ">"-token in URL-tail
3145 http://www.example.com/<b>html</b>
3147 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
3152 BUG 289: ">"-token in bracketed URL
3154 [http://www.example.com/<hello> stuff]
3156 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
3161 BUG 289: literal ">"-token in bracketed URL
3163 [http://www.example.com/<b>html</b> stuff]
3165 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
3170 BUG 289: literal double quote at end of URL
3172 http://www.example.com/"hello"
3174 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
3179 BUG 289: literal double quote in bracketed URL
3181 [http://www.example.com/"hello" stuff]
3183 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
3188 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
3190 [http://www.example.com test]
3192 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
3197 External links: link text with spaces
3199 [http://www.example.com a b c]
3200 [http://www.example.com ''a'' ''b'']
3202 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
3203 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
3208 External links: wiki links within external link (Bug 3695)
3210 [http://example.com [[wikilink]] embedded in ext link]
3212 <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>
3217 BUG 787: Links with one slash after the url protocol are invalid
3221 [http:/example.com title]
3223 <p>http:/example.com
3224 </p><p>[http:/example.com title]
3229 Bracketed external links with template-generated invalid target
3231 [{{echo|http:/example.com}} title]
3233 <p>[http:/example.com title]
3238 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
3240 ''[http://example.com text'']
3241 [http://example.com '''text]'''
3242 ''Something [http://example.com in italic'']
3243 ''Something [http://example.com mixed''''', even bold]'''
3244 '''''Now [http://example.com both''''']
3246 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
3247 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
3248 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
3249 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
3250 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
3256 Bug 4781: %26 in URL
3258 http://www.example.com/?title=AT%26T
3260 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
3264 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
3265 # % is actually legal in HTML5. Any change in output would need testing though.
3267 Bug 4781, 5267: %25 in URL
3269 http://www.example.com/?title=100%25_Bran
3271 <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>
3276 Bug 4781, 5267: %28, %29 in URL
3278 http://www.example.com/?title=Ben-Hur_%281959_film%29
3280 <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>
3286 Bug 4781: %26 in autonumber URL
3288 [http://www.example.com/?title=AT%26T]
3290 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
3295 Bug 4781, 5267: %26 in autonumber URL
3297 [http://www.example.com/?title=100%25_Bran]
3299 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
3304 Bug 4781, 5267: %28, %29 in autonumber URL
3306 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
3308 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
3314 Bug 4781: %26 in bracketed URL
3316 [http://www.example.com/?title=AT%26T link]
3318 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
3323 Bug 4781, 5267: %26 in bracketed URL
3325 [http://www.example.com/?title=100%25_Bran link]
3327 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
3332 Bug 4781, 5267: %28, %29 in bracketed URL
3334 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
3336 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
3341 External link containing double-single-quotes in text '' (bug 4598 sanity check)
3343 Some [http://example.com/ pretty ''italics'' and stuff]!
3345 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
3350 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
3352 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
3354 <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>
3359 External link containing double-single-quotes with no space separating the url from text in italics
3361 [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]].]
3363 <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>
3368 External link with comments in link text
3370 [http://www.google.com Google <!-- comment -->]
3372 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
3377 URL-encoding in URL functions (single parameter)
3379 {{localurl:Some page|amp=&}}
3381 <p>/index.php?title=Some_page&amp=&
3386 URL-encoding in URL functions (multiple parameters)
3388 {{localurl:Some page|q=?&=&}}
3390 <p>/index.php?title=Some_page&q=?&amp=&
3397 http://example.com/index.php?foozoid%5B%5D=bar
3399 http://example.com/index.php?foozoid[]=bar
3401 <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>
3402 </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>
3407 IPv6 urls (bug 21261)
3411 http://[2404:130:0:1000::187:2]/index.php
3413 <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>
3418 Non-extlinks in brackets
3427 [{{echo|foo}} ''bar'']
3428 [{{echo|foo}}l's] errand
3429 [{{echo|foo}}l's errand]
3431 [url=http://example.com]
3444 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
3449 Parsoid: Percent encoding in external links
3453 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
3455 <p><a rel="mw:ExtLink"
3456 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
3460 Parsoid: use url link syntax for links where the content is equal the link
3467 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
3477 Normal text. '''Bold text.''' Normal text. ''Italic text.''
3479 Normal text. '''''Bold italic text.''''' Normal text.
3481 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
3482 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
3488 Unclosed and unmatched quotes (php)
3492 '''''Bold italic text '''with bold deactivated''' in between.'''''
3494 '''''Bold italic text ''with italic deactivated'' in between.'''''
3498 ..spanning two paragraphs (should not work).'''
3500 '''Bold tag left open
3502 ''Italic tag left open
3506 <!-- Unmatching number of opening, closing tags: -->
3507 '''This year''''s election ''should'' beat '''last year''''s.
3509 ''Tom'''s car is bigger than ''Susan'''s.
3511 Plain ''italic'''s plain
3513 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3514 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
3515 </p><p><b>Bold text..</b>
3516 </p><p>..spanning two paragraphs (should not work).
3517 </p><p><b>Bold tag left open</b>
3518 </p><p><i>Italic tag left open</i>
3520 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3521 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3522 </p><p>Plain <i>italic'</i>s plain
3525 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
3526 # parser strips. The wikitext contains just the first half of the bold
3527 # quote pair. (There's also a case where Parsoid nests <b> and <i>
3528 # differently than the PHP parser.)
3530 Unclosed and unmatched quotes (parsoid)
3534 '''''Bold italic text '''with bold deactivated''' in between.'''''
3536 '''''Bold italic text ''with italic deactivated'' in between.'''''
3540 ..spanning two paragraphs (should not work).'''
3542 '''Bold tag left open
3544 ''Italic tag left open
3548 <!-- Unmatching number of opening, closing tags: -->
3549 '''This year''''s election ''should'' beat '''last year''''s.
3551 ''Tom'''s car is bigger than ''Susan'''s.
3553 Plain ''italic'''s plain
3555 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3556 </p><p><i><b>Bold italic text </b></i><b>with italic deactivated<i> in between.</i></b>
3557 </p><p><b>Bold text..</b>
3558 </p><p>..spanning two paragraphs (should not work).<b></b>
3559 </p><p><b>Bold tag left open</b>
3560 </p><p><i>Italic tag left open</i>
3562 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3563 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3564 </p><p>Plain <i>italic'</i>s plain
3571 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
3574 # This should not produce <table></table> as <table><tr><td></td></tr></table>
3575 # is the bare minimum required by the spec, see:
3576 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
3578 A table with no data. (php)
3585 # Parsoid team replies: empty table tags are legal in HTML5
3587 A table with no data. (parsoid)
3596 # A table with nothing but a caption is invalid XHTML, we might want to render
3597 # this as <p>caption</p>
3599 A table with nothing but a caption (php)
3609 </caption><tr><td></td></tr></table>
3612 # Parsoid team replies: table with only a caption is legal in HTML5
3614 A table with nothing but a caption (parsoid)
3622 <table><caption> caption</caption></table>
3626 A table with caption with default-spaced attributes and a table row
3629 |+ style="color: red;" | caption1
3635 <caption style="color: red;"> caption1
3644 A table with captions with non-default spaced attributes and a table row
3647 |+style="color: red;"|caption2
3648 |+ style="color: red;"| caption3
3654 <caption style="color: red;">caption2
3656 <caption style="color: red;"> caption3
3665 Table td-cell syntax variations
3669 | foo bar foo || baz
3670 | style='color:red;' | baz
3671 | style='color:red;' || baz
3678 <td> foo bar foo </td>
3681 <td style="color:red;"> baz
3683 <td> style='color:red;' </td>
3711 Simple table but with multiple dashes for row wikitext
3729 Multiplication table
3731 {| border="1" cellpadding="2"
3732 |+Multiplication table
3734 ! × !! 1 !! 2 !! 3
3752 <table border="1" cellpadding="2">
3753 <caption>Multiplication table
3800 Accept "||" in table headings
3815 Accept "||" in indented table headings
3825 </th></tr></table></dd></dl>
3830 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
3847 Accept "| !" at start of line in tables (ignore !-attribute)
3851 | !style="color:red" | bar
3863 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 +/-
3867 |style='color:red;'|+1
3868 |style='color:blue;'|-1
3880 <td style="color:red;">+1
3882 <td style="color:blue;">-1
3906 |rowspan=2| Cell 2, row 1 (and 2)
3917 <td rowspan="2"> Cell 2, row 1 (and 2)
3935 {| bgcolor=#ABCDEF border=2
3940 |the original table again
3948 <table bgcolor="#ABCDEF" border="2">
3956 <td>the original table again
3962 Invalid attributes in table cell (bug 1830)
3977 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
3980 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
3984 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
3985 <td>]" onmouseover="alert(document.cookie)">test
3994 Indented table markup mixed with indented pre content (proposed in bug 6200)
3999 Text that should be rendered preformatted
4007 <pre>Text that should be rendered preformatted
4016 Template-generated table cell attributes and cell content
4024 <td style="color: red"> Foo
4030 Template-generated table cell attributes and cell content (2)
4033 |align=center {{table_attribs}}
4038 <td align="center" style="color: red"> Foo
4044 Template-generated table cell attributes and cell content (3)
4047 |align=center {{table_cells}}
4052 <td align="center" style="color: red"> Foo </td>
4060 Table with row followed by newlines and table heading
4078 Table with empty line following the start tag
4095 # FIXME: Preserve the attribute properly (with an empty string as value) in
4096 # the PHP parser. Parsoid implements the behavior below.
4098 Table attributes with empty value
4110 </td></tr></tbody></table>
4115 Wikitext table with a lot of comments
4138 Wikitext table with double-line table cell
4155 Table cell with a single comment
4171 # The expected HTML structure in this test is debatable. The PHP parser does
4172 # not parse this kind of table at all. The main focus for Parsoid is on
4173 # round-tripping, so this output is ok for now. TODO: revisit!
4175 Wikitext table with html-syntax row (Parsoid)
4187 <td>foo</td></tr></tbody></table>
4191 Implicit <td> after a |-
4192 (PHP parser relies on Tidy to add the missing <td> tags)
4194 parsoid=wt2html,wt2wt
4207 Pres should be recognized in an explicit <td> context, but not in an implicit <td> context
4208 (PHP parser relies on Tidy to add the missing <td> tags)
4210 parsoid=wt2html,wt2wt
4222 <tr><td><pre>a</pre></td></tr>
4223 <tr><td> b</td></tr>
4229 Lists should be recognized in an implicit <td> context
4230 (PHP parser relies on Tidy to add the missing <td> tags)
4232 parsoid=wt2html,wt2wt
4241 <td><ul><li>a</li></ul></td>
4250 Plain link, capitalized
4254 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
4259 Plain link, uncapitalized
4263 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
4270 [[Main Page|The Main Page]]
4272 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
4277 Piped link with comment in link text
4279 [[Main Page|The Main<!--front--> Page]]
4281 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
4290 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
4295 Broken link with fragment
4297 [[Zigzagzogzagzig#zug]]
4299 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
4304 Special page link with fragment
4306 [[Special:Version#anchor]]
4308 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
4313 Nonexistent special page link with fragment
4315 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
4317 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
4324 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
4326 <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>
4333 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
4335 <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>!!!
4346 Bug 43661: Piped links with identical prefixes
4348 [[prefixed article|prefixed articles with spaces]]
4350 [[prefixed article|prefixed articlesaoeu]]
4352 [[Main Page|Main Page test]]
4354 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
4355 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
4356 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
4362 Link with HTML entity in suffix / tail
4364 [[Main Page]]", [[Main Page]]a
4366 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
4371 Link with 3 brackets
4380 Piped link with 3 brackets
4382 [[[main page|the main page]]]
4384 <p>[[[main page|the main page]]]
4389 Link with multiple pipes
4391 [[Main Page|The|Main|Page]]
4393 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
4400 [[Talk:Parser testing]], [[Meta:Disclaimers]]
4402 <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>
4407 Piped link to namespace
4409 [[Meta:Disclaimers|The disclaimers]]
4411 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
4418 [[Usually caused by a typo (oops}]]
4420 <p>[[Usually caused by a typo (oops}]]
4425 Link containing % (not as a hex sequence)
4429 <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>
4434 Link containing % as a single hex sequence interpreted to char
4438 <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>
4443 Link containing % as a double hex sequence interpreted to hex sequence
4447 <p>[[7%2525 Solution]]
4452 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
4453 Example for such a section: == < ==
4455 [[%23%3c]][[%23%3e]]
4457 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
4462 Link containing "<#" and ">#" as a hex sequences
4464 [[%3c%23]][[%3e%23]]
4466 <p>[[%3c%23]][[%3e%23]]
4471 Link containing an equals sign
4473 [[Special:BookSources/isbn=4-00-026157-6]]
4475 <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>
4482 Just a test of an article title containing a tilde.
4485 # note that links containing signatures, like [[Foo~~~~]], are
4486 # massaged by the pre-save transform (PST) and so the tildes are never
4487 # seen by the parser.
4489 Link containing a tilde
4493 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
4498 Link containing double-single-quotes '' (bug 4598)
4500 [[Lista d''e paise d''o munno]]
4502 <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>
4507 Link containing double-single-quotes '' in text (bug 4598 sanity check)
4509 Some [[Link|pretty ''italics'' and stuff]]!
4511 <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>!
4516 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
4518 ''Some [[Link|pretty ''italics'' and stuff]]!
4520 <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>
4525 Link with double quotes in title part (literal) and alternate part (interpreted)
4527 [[File:Denys Savchenko ''Pentecoste''.jpg]]
4531 [[''Pentecoste''|Pentecoste]]
4533 [[''Pentecoste''|''Pentecoste'']]
4535 <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>
4536 </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>
4537 </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>
4538 </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>
4543 Broken image links with HTML captions (bug 39700)
4545 [[File:Nonexistent|<script></script>]]
4546 [[File:Nonexistent|100px|<script></script>]]
4547 [[File:Nonexistent|<]]
4548 [[File:Nonexistent|a<i>b</i>c]]
4550 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
4551 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
4552 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
4553 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
4560 [[http://www.example.com]]
4562 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
4567 Plain link to URL with link text
4569 [[http://www.example.com Link text]]
4571 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
4576 Plain link to protocol-relative URL
4578 [[//www.example.com]]
4580 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
4585 Plain link to protocol-relative URL with link text
4587 [[//www.example.com Link text]]
4589 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
4594 Plain link to page with question mark in title
4600 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
4601 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
4606 # I'm fairly sure the expected result here is wrong.
4607 # We want these to be URL links, not pseudo-pages with URLs for titles....
4608 # However the current output is also pretty screwy.
4611 # I'm changing it to match the current output--it arguably makes more
4612 # sense in the light of the test above. Old expected result was:
4613 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
4615 # But I think this test is bordering on "garbage in, garbage out" anyway.
4620 Piped link to URL: [[http://www.example.com|an example URL]]
4622 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
4627 BUG 2: [[page|http://url/]] should link to page, not http://url/
4629 [[Main Page|http://url/]]
4631 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
4636 BUG 337: Escaped self-links should be bold
4640 [[Bug462]] [[Bug462]]
4642 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
4647 Self-link to section should not be bold
4651 [[Main Page#section]]
4653 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
4664 Self-link to numeric title
4670 <p><strong class="selflink">0</strong>
4675 Link to numeric-equivalent title
4681 <p><a href="/wiki/00" title="00">00</a>
4686 <nowiki> inside a link
4688 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
4690 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
4695 Non-breaking spaces in title
4697 [[ Main Page ]]
4699 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
4704 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
4710 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
4715 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
4721 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
4726 Internal link with en linktrail: no apostrophes (bug 27473)
4732 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
4737 Internal link with ca linktrail with apostrophes (bug 27473)
4743 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
4748 Internal link with kaa linktrail with apostrophes (bug 27473)
4754 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
4765 Internal link with is link prefix
4769 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
4771 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
4782 Internal link with is link trail and link prefix
4786 [[mótmælendatrú|xxx]]ar
4788 mótmælenda[[söfnuður]]
4789 mótmælenda[[söfnuður|söfnuðir]]
4790 mótmælenda[[söfnuður|söfnuðir]]xxx
4792 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
4793 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
4794 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
4795 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
4796 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
4801 Parsoid link trail escaping
4803 parsoid=html2wt,html2html
4807 <p><a rel="mw:WikiLink" href="Apple">apple</a>s</p>
4811 Parsoid link prefix escaping
4814 parsoid=html2wt,html2html
4816 Aðrir mótmælenda<nowiki/>[[söfnuður]]
4818 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður">söfnuður</a></p>
4822 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
4830 [http://wp.org ''foo'']
4832 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
4833 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
4834 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
4835 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
4840 ### Interwiki links (see maintenance/interwiki.sql)
4844 Inline interwiki link
4846 [[MeatBall:SoftSecurity]]
4848 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
4853 Inline interwiki link with empty title (bug 2372)
4857 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
4862 Interwiki link encoding conversion (bug 1636)
4864 *[[Wikipedia:ro:Olteniţa]]
4865 *[[Wikipedia:ro:Olteniţa]]
4867 <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>
4868 </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>
4874 Interwiki link with fragment (bug 2130)
4876 [[MeatBall:SoftSecurity#foo]]
4878 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
4893 Double interlanguage link
4904 Interlanguage link, with prefix links
4916 Double interlanguage link, with prefix links (bug 8897)
4929 Parsoid-specific test: Wikilinks with should RT properly
4935 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
4940 Parsoid: handle constructor well
4948 <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>
4951 <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>
4955 ## Redirects, Parsoid-only
4958 Simple redirect to page
4962 #REDIRECT [[Main Page]]
4964 <link rel="mw:PageProp/redirect" href="./Main_Page">
4968 Optional colon in #REDIRECT
4970 # the colon is archaic syntax. we support it for wt2html, but we
4971 # don't care that it roundtrips back to the modern syntax.
4972 parsoid=wt2html,html2html
4974 #REDIRECT:[[Main Page]]
4976 <link rel="mw:PageProp/redirect" href="./Main_Page">
4980 Whitespace in #REDIRECT with optional colon
4982 # the colon and gratuitous whitespace is archaic syntax. we support
4983 # it for wt2html, but we don't care that it roundtrips back to the
4984 # modern syntax (without extra whitespace)
4985 parsoid=wt2html,html2html
4992 <link rel="mw:PageProp/redirect" href="./Main_Page">
4996 Piped link in #REDIRECT
4998 # content after piped link is ignored. we support this syntax,
4999 # but don't care that the piped link is lost when we roundtrip this.
5002 #REDIRECT [[Main Page|bar]]
5004 <link rel="mw:PageProp/redirect" href="./Main_Page">
5008 Redirect to category
5012 #REDIRECT [[Category:Foo]]
5014 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:WikiLink/Category" href="./Category:Foo">
5018 Redirect to category with URL encoding
5022 #REDIRECT [[Category%3AFoo]]
5024 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:WikiLink/Category" href="./Category:Foo">
5028 Redirect to category page
5030 parsoid=wt2html,html2html
5032 #REDIRECT [[:Category:Foo]]
5034 <p><a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a></p>
5038 Redirect to image page (1)
5042 #REDIRECT [[File:Wiki.png]]
5044 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
5048 Redirect to image page (2)
5052 #REDIRECT [[Image:Wiki.png]]
5054 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
5058 Redirect to language
5062 #REDIRECT [[en:File:Wiki.png]]
5064 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
5068 Redirect to interwiki
5072 #REDIRECT [[meatball:File:Wiki.png]]
5074 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
5078 Non-English #REDIRECT
5083 #TILVÍSUN [[Main Page]]
5085 <link rel="mw:PageProp/redirect" href="./Main_Page">
5102 Broken br tag sanitization
5112 # TODO: Fix html2html mode (bug 51055)!
5114 Parsoid: Broken br tag recognition
5124 Incorrecly removing closing slashes from correctly formed XHTML
5126 <br style="clear:both;" />
5128 <p><br style="clear:both;" />
5133 Failing to transform badly formed HTML into correct XHTML
5135 <br style="clear: left;">
5136 <br style="clear: right;">
5137 <br style="clear: both;">
5139 <p><br style="clear: left;" />
5140 <br style="clear: right;" />
5141 <br style="clear: both;" />
5146 Handling html with a div self-closing tag
5155 <p><div title />
5159 <p><div title=bar />
5160 <div title=bar/>
5162 <div title="bar/"></div>
5168 Handling html with a br self-closing tag
5177 <p><br title="title" />
5178 <br title="title" />
5187 Horizontal ruler (should it add that extra space?)
5201 Horizontal ruler -- 4+ dashes render hr
5210 Horizontal ruler -- eats additional dashes on the same line
5219 Horizontal ruler -- does not collapse dashes on consecutive lines
5230 Horizontal ruler -- <4 dashes render as plain text
5239 Horizontal ruler -- Supports content following dashes on same line
5248 ### Block-level elements
5271 <ol><li>Numbered list
5288 ***#Number on level 4
5290 **#Number on level 3
5291 **#Number on level 3
5295 #** Level 3, but ordered
5298 <ol><li> with numbers
5300 <ul><li> and bullets
5302 <ol><li> and numbers
5304 </li><li>bullets again
5305 <ul><li>bullet level 2
5306 <ul><li>bullet level 3
5307 <ol><li>Number on level 4
5310 </li><li>bullet level 2
5311 <ol><li>Number on level 3
5312 </li><li>Number on level 3
5315 <ol><li>number level 2
5318 <ul><li><ul><li> Level 3
5322 <ol><li><ul><li><ul><li> Level 3, but ordered
5356 Nested lists 3 (first element empty)
5369 Nested lists 4 (first element empty)
5382 Nested lists 5 (both elements empty)
5395 Nested lists 6 (both elements empty)
5408 Nested lists 7 (skip initial nesting levels)
5412 <ul><li><ul><li><ul><li> foo
5420 Nested lists 8 (multiple nesting transitions)
5428 <ul><li><ul><li> bar
5438 1. Lists with start-of-line-transparent tokens before bullets: Comments
5452 2. Lists with start-of-line-transparent tokens before bullets: Template close
5464 List items are not parsed correctly following a <pre> block (bug 785)
5470 <ul><li> <pre>foo</pre>
5471 </li><li> <pre>bar</pre>
5478 List items from template
5489 * notSOL{{inner list}}
5508 List interrupted by empty line or heading
5518 <ul><li><ul><li> bar
5521 <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>
5522 <ul><li> Another list item
5528 Multiple list tags generated by templates
5543 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
5546 <!--This line will NOT split the list-->
5548 <!--This line will NOT split the list either-->
5550 <!--foo--> <!----> <!--This line NOT split the list either-->
5562 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
5565 <!--This line will NOT split the list-->
5567 <!--This line will NOT split the list either-->
5569 <!--foo--> <!----> <!--This line NOT split the list
5583 (Cannot test this with PHP parser since it relies on Tidy for the hack)
5585 parsoid=wt2html,wt2wt
5589 * {{echo|<li>templated li-hack}}
5590 * <!--foo--> <li> unsupported li-hack with preceding comments
5593 <li><li>not a li-hack
5599 <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>
5600 <li> <!--foo--> </li><li> li-hack with preceding comments</li></ul>
5603 <li></li><li>not a li-hack
5609 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
5620 <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>
5624 Parsoid: Test of whitespace serialization with Templated bullets
5631 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}'> Bar</li>
5635 # ------------------------------------------------------------------------
5636 # The next set of tests are about Parsoid's ability to handle badly nested
5637 # tags (parse, minimize scope of fixup, and roundtrip back)
5638 # ------------------------------------------------------------------------
5641 Unbalanced closing block tags break a list
5642 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5652 </li></ul></div><div>
5658 Unbalanced closing non-block tags don't break a list
5659 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5669 <ul><li>a<span></span>
5675 Unclosed formatting tags that straddle lists are closed and reopened
5676 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5684 </li><li> <s> b </s>
5689 List embedded in a non-block tag
5690 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
5698 <p><small></small></p>
5704 <p><small></small></p>
5711 # Note that the current date is hard-coded as
5712 # 1970-01-01T00:02:03Z (a Thursday)
5713 # when running parser tests. The timezone is also fixed to GMT, so
5714 # local date will be identical to current date.
5717 Magic Word: {{CURRENTDAY}}
5726 Magic Word: {{CURRENTDAY2}}
5735 Magic Word: {{CURRENTDAYNAME}}
5744 Magic Word: {{CURRENTDOW}}
5753 Magic Word: {{CURRENTMONTH}}
5762 Magic Word: {{CURRENTMONTH1}}
5771 Magic Word: {{CURRENTMONTHABBREV}}
5773 {{CURRENTMONTHABBREV}}
5780 Magic Word: {{CURRENTMONTHNAME}}
5782 {{CURRENTMONTHNAME}}
5789 Magic Word: {{CURRENTMONTHNAMEGEN}}
5791 {{CURRENTMONTHNAMEGEN}}
5798 Magic Word: {{CURRENTTIME}}
5807 Magic Word: {{CURRENTHOUR}}
5816 Magic Word: {{CURRENTWEEK}} (@bug 4594)
5825 Magic Word: {{CURRENTYEAR}}
5834 Magic Word: {{CURRENTTIMESTAMP}}
5836 {{CURRENTTIMESTAMP}}
5843 Magic Words LOCAL (UTC)
5847 * {{LOCALMONTHNAME}}
5848 * {{LOCALMONTHNAMEGEN}}
5849 * {{LOCALMONTHABBREV}}
5858 * {{LOCALTIMESTAMP}}
5873 </li><li> 19700101000203
5879 Magic Word: {{FULLPAGENAME}}
5881 title=[[User:Ævar Arnfjörð Bjarmason]]
5885 <p>User:Ævar Arnfjörð Bjarmason
5890 Magic Word: {{FULLPAGENAMEE}}
5892 title=[[User:Ævar Arnfjörð Bjarmason]]
5896 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
5901 Magic Word: {{TALKSPACE}}
5903 title=[[User:Ævar Arnfjörð Bjarmason]]
5912 Magic Word: {{TALKSPACE}}, same namespace
5914 title=[[User talk:Ævar Arnfjörð Bjarmason]]
5923 Magic Word: {{TALKSPACE}}, main namespace
5925 title=[[Parser Test]]
5934 Magic Word: {{TALKSPACEE}}
5936 title=[[User:Ævar Arnfjörð Bjarmason]]
5945 Magic Word: {{SUBJECTSPACE}}
5947 title=[[User talk:Ævar Arnfjörð Bjarmason]]
5956 Magic Word: {{SUBJECTSPACE}}, same namespace
5958 title=[[User:Ævar Arnfjörð Bjarmason]]
5967 Magic Word: {{SUBJECTSPACE}}, main namespace
5969 title=[[Parser Test]]
5977 Magic Word: {{SUBJECTSPACEE}}
5979 title=[[User talk:Ævar Arnfjörð Bjarmason]]
5988 Magic Word: {{NAMESPACE}}
5990 title=[[User:Ævar Arnfjörð Bjarmason]]
5999 Magic Word: {{NAMESPACEE}}
6001 title=[[User:Ævar Arnfjörð Bjarmason]]
6010 Magic Word: {{NAMESPACENUMBER}}
6012 title=[[User:Ævar Arnfjörð Bjarmason]]
6021 Magic Word: {{SUBPAGENAME}}
6023 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
6032 Magic Word: {{SUBPAGENAMEE}}
6034 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
6043 Magic Word: {{ROOTPAGENAME}}
6045 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
6049 <p>Ævar Arnfjörð Bjarmason
6054 Magic Word: {{ROOTPAGENAMEE}}
6056 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
6060 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6065 Magic Word: {{BASEPAGENAME}}
6067 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
6071 <p>Ævar Arnfjörð Bjarmason
6076 Magic Word: {{BASEPAGENAMEE}}
6078 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
6082 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6087 Magic Word: {{TALKPAGENAME}}
6089 title=[[User:Ævar Arnfjörð Bjarmason]]
6093 <p>User talk:Ævar Arnfjörð Bjarmason
6098 Magic Word: {{TALKPAGENAMEE}}
6100 title=[[User:Ævar Arnfjörð Bjarmason]]
6104 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6109 Magic Word: {{SUBJECTPAGENAME}}
6111 title=[[User talk:Ævar Arnfjörð Bjarmason]]
6115 <p>User:Ævar Arnfjörð Bjarmason
6120 Magic Word: {{SUBJECTPAGENAMEE}}
6122 title=[[User talk:Ævar Arnfjörð Bjarmason]]
6124 {{SUBJECTPAGENAMEE}}
6126 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6131 Magic Word: {{NUMBEROFFILES}}
6140 Magic Word: {{PAGENAME}}
6142 title=[[User:Ævar Arnfjörð Bjarmason]]
6146 <p>Ævar Arnfjörð Bjarmason
6151 Magic Word: {{PAGENAME}} with metacharacters
6153 title=[['foo & bar = baz']]
6157 <p><i>'foo & bar = baz'</i>
6162 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
6164 title=[[*RFC 1234 http://example.com/]]
6168 <p>*RFC 1234 http://example.com/
6173 Magic Word: {{PAGENAMEE}}
6175 title=[[User:Ævar Arnfjörð Bjarmason]]
6179 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6184 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
6186 title=[[*RFC 1234 http://example.com/]]
6190 <p>*RFC_1234_http://example.com/
6195 Magic Word: {{REVISIONID}}
6204 Magic Word: {{SCRIPTPATH}}
6213 Magic Word: {{STYLEPATH}}
6222 Magic Word: {{SERVER}}
6226 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
6231 Magic Word: {{SERVERNAME}}
6240 Magic Word: {{SITENAME}}
6249 Case-sensitive magic words, when cased differently, should just be template transclusions
6256 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
6257 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
6258 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
6259 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
6264 Case-insensitive magic words should still work with weird casing.
6274 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
6279 Namespace 1 {{ns:1}}
6288 Namespace 1 {{ns:01}}
6297 Namespace 0 {{ns:0}} (bug 4783)
6305 Namespace 0 {{ns:00}} (bug 4783)
6313 Namespace -1 {{ns:-1}}
6322 Namespace User {{ns:User}}
6331 Namespace User talk {{ns:User_talk}}
6340 Namespace User talk {{ns:uSeR tAlK}}
6349 Namespace File {{ns:File}}
6358 Namespace File {{ns:Image}}
6367 Namespace (lang=de) Benutzer {{ns:User}}
6378 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
6384 <p>Benutzer Diskussion
6392 {{urlencode:hi world?!}}
6393 {{urlencode:hi world?!|WIKI}}
6394 {{urlencode:hi world?!|PATH}}
6395 {{urlencode:hi world?!|QUERY}}
6408 Magic links: internal link to RFC (bug 479)
6412 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
6417 Magic links: RFC (bug 479)
6421 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
6426 Magic links: ISBN (bug 1937)
6430 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
6435 Magic links: PMID incorrectly converts space to underscore
6439 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
6448 Nonexistent template
6450 {{thistemplatedoesnotexist}}
6452 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
6457 Template with invalid target containing tags
6459 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
6461 <p>{{a<b>b</b>|foo|a=b|a = b}}
6466 Template with invalid target containing unclosed tag
6468 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
6470 <p>{{a<b>|foo|a=b|a = b}}</b>
6477 This is a test template
6485 <p>This is a test template
6490 Template with explicit namespace
6494 <p>This is a test template
6502 This is a test template with parameter {{{param}}}
6508 {{paramtest|param=foo}}
6510 <p>This is a test template with parameter foo
6515 Template:paramtestnum
6521 Template unnamed parameter
6523 {{paramtestnum|Main Page|the main page}}
6525 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
6530 Template:templatesimple
6536 Template:templateredirect
6538 #redirect [[Template:templatesimple]]
6542 Template:templateasargtestnum
6548 Template:templateasargtest
6550 {{template{{{templ}}}}}
6554 Template:templateasargtest2
6560 Template with template name as unnamed argument
6562 {{templateasargtestnum|templatesimple}}
6569 Template with template name as argument
6571 {{templateasargtest|templ=simple}}
6578 Template with template name as argument (2)
6580 {{templateasargtest2|templ=templatesimple}}
6587 Template:templateasargtestdefault
6589 {{{{{templ|templatesimple}}}}}
6599 Template with default value
6601 {{templateasargtestdefault}}
6608 Template with default value (value set)
6610 {{templateasargtestdefault|templ=templa}}
6619 {{templateredirect}}
6626 Template with argument in separate line
6628 {{ templateasargtest |
6636 Template with complex template as argument
6639 param ={{ templateasargtest |
6642 <p>This is a test template with parameter (test)
6647 Template with thumb image (with link in description)
6650 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
6652 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>
6657 Template:complextemplate
6659 {{{1}}} {{paramtest|
6660 param ={{{param}}}}}
6664 Template with complex arguments
6667 param ={{ templateasargtest |
6668 templ = simple }}|[[Template:complextemplate|link]]}}
6670 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
6675 BUG 553: link with two variables in a piped link
6678 |[[{{{1}}}|{{{2}}}]]
6683 <td>[[{{{1}}}|{{{2}}}]]
6689 Magic variable as template parameter
6691 {{paramtest|param={{SITENAME}}}}
6693 <p>This is a test template with parameter MediaWiki
6700 [[{{{param}}}|link]]
6704 Template parameter as link source
6706 {{linktest|param=Main Page}}
6708 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
6713 Template-generated attribute string (k='v')
6715 <span {{attr_str|id|v1}}>bar</span>
6717 <p><span id="v1">bar</span>
6724 including another template, {{paramtest|param={{{arg}}}}}
6728 Template passing argument to another template
6730 {{paramtest2|arg='hmm'}}
6732 <p>including another template, This is a test template with parameter 'hmm'
6743 Template as link source
6747 [[{{linktest2}}|Main Page]]
6749 [[{{linktest2}}]]Page
6751 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6752 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6753 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
6771 Template infinite loop
6775 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
6780 Template from main namespace
6799 BUG 529: Template with table, not included at beginning of line
6818 BUG 523: Template shouldn't eat newline (or add an extra one before table)
6838 BUG 41: Template parameters shown as broken links
6847 Template with targets containing wikilinks
6851 {{[[{{echo|foo}}]]}}
6853 {{{{echo|[[foo}}]]}}
6855 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
6856 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
6864 ''None'' of '''this''' should be
6866 but rather passed unmodified
6870 # hmm, fix this or just deprecate msgnw and document its behavior?
6876 {{msgnw:MSGNW test}}
6878 <p>''None'' of '''this''' should be
6880 but rather passed unmodified
6888 {{int:youhavenewmessages|lots of money|not!}}
6890 <p>You have lots of money (not!).
6897 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
6901 <includeonly> and <noinclude> being included
6912 <onlyinclude>Foo</onlyinclude>bar
6916 <onlyinclude> being included
6928 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
6932 <onlyinclude> and <includeonly> being included
6941 <includeonly> and <noinclude> on a page
6943 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
6950 Un-closed <noinclude>
6957 <onlyinclude> on a page
6959 <onlyinclude>Foo</onlyinclude>bar
6966 Un-closed <onlyinclude>
6973 Self-closed noinclude, includeonly, onlyinclude tags
6984 Unbalanced includeonly and noinclude tags
6988 |b</noinclude></noinclude>
6989 |c</noinclude></includeonly>
6990 |d</includeonly></includeonly>
6999 <td>c</includeonly>
7001 <td>d</includeonly></includeonly>
7007 Template:Includeonly section
7010 ==Includeonly section==
7016 Bug 6563: Edit link generation for section shown by <includeonly>
7018 {{includeonly section}}
7020 <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>
7021 <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>
7025 # Uses same input as the contents of [[Template:Includeonly section]]
7027 Bug 6563: Section extraction for section shown by <includeonly>
7032 ==Includeonly section==
7040 Bug 6563: Edit link generation for section suppressed by <includeonly>
7043 ==Includeonly section==
7047 <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>
7052 Bug 6563: Section extraction for section suppressed by <includeonly>
7057 ==Includeonly section==
7065 Un-closed <includeonly>
7071 # TODO: test with DOM fragment reuse!
7073 Parsoid: DOM fragment reuse
7075 parsoid=wt2wt,wt2html
7077 a{{echo|b<table></table>c}}d
7089 a<span typeof="mw:Transclusion">b</span>
7090 <table></table><span>c</span>d
7091 <p typeof="mw:Transclusion">ab</p>
7094 <p typeof="mw:Transclusion">a</p>
7100 ### <includeonly> and <noinclude> in attributes
7103 0. includeonly around the entire attribute
7105 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
7107 <p><span id="v2">bar</span>
7112 1. includeonly in html attr key
7114 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
7116 <p><span id="foo">bar</span>
7121 2. includeonly in html attr value
7123 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
7124 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
7126 <p><span id="v1">bar</span>
7127 <span id="v1">bar</span>
7132 3. includeonly in part of an attr value
7134 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
7136 <p><span style="color:red;">bar</span>
7141 ### Testing parsing of templates where a template arg
7142 ### has the same name as the template itself.
7152 Templates: Template Name/Arg clash: 1. Use of positional param
7161 Templates: Template Name/Arg clash: 2. Use of named param
7170 Templates: Template Name/Arg clash: 3. Use of named param with empty input
7179 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
7183 Templates: 1. Simple use
7192 Templates: 2. Inside a block tag
7194 <div>{{echo|Foo}}</div>
7201 Templates: P-wrapping: 1a. Templates on consecutive lines
7212 Templates: P-wrapping: 1b. Templates on consecutive lines
7226 Templates: P-wrapping: 1c. Templates on consecutive lines
7229 {{echo|bar}} <div>baz</div>
7238 Templates: P-wrapping: 1d. Template preceded by comment-only line
7240 parsoid=wt2html,wt2wt
7246 <p typeof="mw:Transclusion">Bar
7251 Templates: Inline Text: 1. Multiple tmeplate uses
7253 {{echo|Foo}}bar{{echo|baz}}
7260 Templates: Inline Text: 2. Back-to-back template uses
7262 {{echo|Foo}}{{echo|bar}}
7269 Templates: Block Tags: 1. Multiple template uses
7271 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
7273 <div>Foo</div><div>bar</div><div>baz</div>
7278 Templates: Block Tags: 2. Back-to-back template uses
7280 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
7282 <div>Foo</div><div>bar</div>
7287 Templates: Links: 1. Simple example
7289 {{echo|[[Foo|bar]]}}
7291 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7296 Templates: Links: 2. Generation of link href
7298 [[{{echo|Foo}}|bar]]
7300 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7305 Templates: Links: 3. Generation of part of a link href
7307 [[Fo{{echo|o}}|bar]]
7311 [[Foo{{echo|bar}}baz]]
7313 [[Foo{{echo|bar}}|bar]]
7315 [[:Foo{{echo|bar}}]]
7317 [[:Foo{{echo|bar}}|bar]]
7319 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7320 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
7321 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
7322 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
7323 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
7324 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
7329 Templates: Links: 4. Multiple templates generating link href
7331 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
7333 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
7338 Templates: Links: 5. Generation of link text
7340 [[Foo|{{echo|bar}}]]
7342 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7347 Templates: Links: 5. Nested templates (only outermost template should be marked)
7349 {{echo|[[{{echo|Foo}}|bar]]}}
7351 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7356 Templates: HTML Tag: 1. Generation of HTML attr. key
7358 <div {{echo|style}}="color:red;">foo</div>
7360 <div style="color:red;">foo</div>
7365 Templates: HTML Tag: 2. Generation of HTML attr. value
7367 <div style={{echo|'color:red;'}}>foo</div>
7369 <div style="color:red;">foo</div>
7374 Templates: HTML Tag: 3. Generation of HTML attr key and value
7376 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
7378 <div style="color:red;">foo</div>
7383 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
7385 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
7387 <div title="This is a long title with just one piece templated">foo</div>
7392 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
7394 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
7396 <div title="This is a long title with just one piece templated">foo</div>
7401 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
7403 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
7405 <div title="This is a long title with just one piece templated">foo</div>
7410 Templates: HTML Tag: 7. Generation of partial attribute key string
7412 <div st{{echo|yle}}="color:red;">foo</div>
7414 <div style="color:red;">foo</div>
7419 Templates: HTML Tables: 1. Generating start of a HTML table
7421 {{echo|<table><tr><td>foo</td>}}</tr></table>
7423 <table><tr><td>foo</td></tr></table>
7428 Templates: HTML Tables: 2a. Generating middle of a HTML table
7430 <table><tr>{{echo|<td>foo</td>}}</tr></table>
7432 <table><tr><td>foo</td></tr></table>
7437 Templates: HTML Tables: 2b. Generating middle of a HTML table
7439 <table>{{echo|<tr><td>foo</td></tr>}}</table>
7441 <table><tr><td>foo</td></tr></table>
7446 Templates: HTML Tables: 3. Generating end of a HTML table
7448 <table><tr>{{echo|<td>foo</td></tr></table>}}
7450 <table><tr><td>foo</td></tr></table>
7455 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
7457 {{echo|<table>}}<tr><td>foo</td></tr></table>
7459 <table><tr><td>foo</td></tr></table>
7464 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
7466 <table>{{echo|<tr>}}<td>foo</td></tr></table>
7468 <table><tr><td>foo</td></tr></table>
7473 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
7475 <table><tr>{{echo|<td>}}foo</td></tr></table>
7477 <table><tr><td>foo</td></tr></table>
7482 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
7484 <table><tr><td>foo{{echo|</td>}}</tr></table>
7486 <table><tr><td>foo</td></tr></table>
7491 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
7493 <table><tr><td>foo</td>{{echo|</tr>}}</table>
7495 <table><tr><td>foo</td></tr></table>
7500 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
7502 <table><tr><td>foo</td></tr>{{echo|</table>}}
7504 <table><tr><td>foo</td></tr></table>
7509 Templates: HTML Tables: 5. Proper fostering of categories from inside
7511 parsoid=wt2html,wt2wt
7513 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
7514 <!--Two categories (Bug 50330)-->
7515 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
7517 <link rel="mw:WikiLink/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
7518 <!--Two categories (Bug 50330)-->
7519 <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>
7523 Templates: Wiki Tables: 1a. Fostering of entire template content
7531 <tr><td></td></tr></table>
7536 Templates: Wiki Tables: 1b. Fostering of entire template content
7549 <tr><td></td></tr></table>
7554 Templates: Wiki Tables: 2. Fostering of partial template content
7564 <tr><td></td></tr></table>
7569 Templates: Wiki Tables: 3. td-content via multiple templates
7572 {{echo|{{pipe}}a}}{{echo|b}}
7583 Templates: Wiki Tables: 4. Templated tags, no content
7589 <tr><td></td></tr></table>
7594 Templates: Wiki Tables: 5. Templated tags, regular td-tags
7608 Templates: Wiki Tables: 6. Templated tags, templated td-tags
7622 Templates: Lists: Multi-line list-items via templates
7624 *{{echo|a {{nonexistent|
7626 *{{echo|b {{nonexistent|
7629 <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>
7630 </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>
7636 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
7638 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
7640 <p><i>ab</i>c<i>d</i>e
7645 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
7646 (PHP parser generates misnested html)
7648 parsoid=wt2html,wt2wt
7650 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
7652 <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>
7656 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
7657 (PHP parser generates misnested html)
7659 parsoid=wt2html,wt2wt
7661 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
7663 <div typeof="mw:Transclusion"><i>a</i></div>
7664 <div typeof="mw:Transclusion"><i>b</i>c<i>d</i></div>
7665 <div typeof="mw:Transclusion">e</div>
7669 Templates: Ugly nesting: 4. Divs opened/closed across templates
7671 a<div>b{{echo|c</div>d}}e
7678 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
7684 |{{echo|foo</table>}}
7688 <table typeof="mw:Transclusion">
7691 <td>foo</td></tr></tbody></table><span>bar</span>
7695 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
7705 <td>1. {{echo|foo </table>}}</td>
7707 <td>2. {{echo|baz </table>}}</td>
7720 <table about="#mwt1" typeof="mw:Transclusion">
7725 <td >1. foo </td></tr></tbody></table></td>
7727 <td >2. baz </td></tr></tbody></table><span about="#mwt1">
7728 </span><span about="#mwt1">
7730 abc</span><span about="#mwt1">
7731 </span><span about="#mwt1">
7732 </span><span about="#mwt1">
7733 </span><span about="#mwt1">
7734 </span><span about="#mwt1">
7736 xyz</span><span about="#mwt1">
7737 </span><span about="#mwt1">
7742 Templates: Ugly templates: 3. newline-only template parameter
7751 # This looks like a bug: a single newline triggers p/br for some reason.
7753 Templates: Ugly templates: 4. newline-only template parameter inconsistency
7764 Parser Functions: 1. Simple example
7773 Parser Functions: 2. Nested use (only outermost should be marked up)
7782 ### Pre-save transform tests
7785 pre-save transform: subst:
7791 This is a test template
7795 pre-save transform: normal template
7805 pre-save transform: nonexistent template
7809 {{thistemplatedoesnotexist}}
7811 {{thistemplatedoesnotexist}}
7816 pre-save transform: subst magic variables
7825 # This is bug 89, which I fixed. -- wtm
7827 pre-save transform: subst: templates with parameters
7831 {{subst:paramtest|param="something else"}}
7833 This is a test template with parameter "something else"
7839 <nowiki>'''not wiki'''</nowiki>
7843 pre-save transform: nowiki in subst (bug 1188)
7847 {{subst:nowikitest}}
7849 <nowiki>'''not wiki'''</nowiki>
7854 Template:commenttest
7856 This template has <!-- a comment --> in it.
7860 pre-save transform: comment in subst (bug 1936)
7864 {{subst:commenttest}}
7866 This template has <!-- a comment --> in it.
7870 pre-save transform: unclosed tag
7874 <nowiki>'''not wiki'''
7876 <nowiki>'''not wiki'''
7880 pre-save transform: mixed tag case
7884 <NOwiki>'''not wiki'''</noWIKI>
7886 <NOwiki>'''not wiki'''</noWIKI>
7890 pre-save transform: unclosed comment in <nowiki>
7894 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
7896 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
7899 # Leading @ in this template definition works around a limitation
7900 # in parsoid's parserTests which otherwise strips the <span> from the
7901 # result (confusing it for a template wrapper)
7905 @<span onmouseover="alert('crap')">Oh no</span>
7909 (confirming safety of fix for subst bug 1936)
7911 {{Template:dangerous}}
7913 <p>@<span>Oh no</span>
7918 pre-save transform: comment containing gallery (bug 5024)
7922 <!-- <gallery>data</gallery> -->
7924 <!-- <gallery>data</gallery> -->
7928 pre-save transform: comment containing extension
7932 <!-- <tag>data</tag> -->
7934 <!-- <tag>data</tag> -->
7938 pre-save transform: comment containing nowiki
7942 <!-- <nowiki>data</nowiki> -->
7944 <!-- <nowiki>data</nowiki> -->
7948 pre-save transform: <noinclude> in subst (bug 3298)
7958 pre-save transform: <onlyinclude> in subst (bug 3298)
7970 {{<includeonly>subst:</includeonly>Includes}}
7974 Template:SafeSubstTest
7976 {{<includeonly>safesubst:</includeonly>Includes}}
7980 bug 22297: safesubst: works during PST
7984 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
7990 bug 22297: safesubst: works during normal parse
7999 subst: does not work during normal parse
8003 <p>{{subst:Includes}}
8008 pre-save transform: context links ("pipe trick")
8012 [[Article (context)|]]
8015 [[Bar:Article (context)|]]
8016 [[:Bar:Article (context)|]]
8018 [[|Article (context)]]
8022 [[Article (context)|Article]]
8023 [[Bar:Article|Article]]
8024 [[:Bar:Article|Article]]
8025 [[Bar:Article (context)|Article]]
8026 [[:Bar:Article (context)|Article]]
8028 [[Article (context)]]
8029 [[Bar:X (Y) Z|X (Y) Z]]
8030 [[:Bar:X (Y) Z|X (Y) Z]]
8034 pre-save transform: context links ("pipe trick") with interwiki prefix
8038 [[interwiki:Article|]]
8039 [[:interwiki:Article|]]
8040 [[interwiki:Bar:Article|]]
8041 [[:interwiki:Bar:Article|]]
8043 [[interwiki:Article|Article]]
8044 [[:interwiki:Article|Article]]
8045 [[interwiki:Bar:Article|Bar:Article]]
8046 [[:interwiki:Bar:Article|Bar:Article]]
8050 pre-save transform: context links ("pipe trick") with parens in title
8052 pst title=[[Somearticle (context)]]
8056 [[Article (context)|Article]]
8060 pre-save transform: context links ("pipe trick") with comma in title
8062 pst title=[[Someplace, Somewhere]]
8065 [[Otherplace, Elsewhere|]]
8066 [[Otherplace, Elsewhere, Anywhere|]]
8068 [[Otherplace, Somewhere|Otherplace]]
8069 [[Otherplace, Elsewhere|Otherplace]]
8070 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
8074 pre-save transform: context links ("pipe trick") with parens and comma
8076 pst title=[[Someplace (IGNORED), Somewhere]]
8079 [[Otherplace (place), Elsewhere|]]
8081 [[Otherplace, Somewhere|Otherplace]]
8082 [[Otherplace (place), Elsewhere|Otherplace]]
8086 pre-save transform: context links ("pipe trick") with comma and parens
8088 pst title=[[Who, me? (context)]]
8091 [[Me, Myself, and I (1937 song)|]]
8093 [[Yes, you. (context)|Yes, you.]]
8094 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
8098 pre-save transform: context links ("pipe trick") with namespace
8100 pst title=[[Ns:Somearticle]]
8104 [[Ns:Article|Article]]
8108 pre-save transform: context links ("pipe trick") with namespace and parens
8110 pst title=[[Ns:Somearticle (context)]]
8114 [[Ns:Article (context)|Article]]
8118 pre-save transform: context links ("pipe trick") with namespace and comma
8120 pst title=[[Ns:Somearticle, Context, Whatever]]
8124 [[Ns:Article, Context, Whatever|Article]]
8128 pre-save transform: context links ("pipe trick") with namespace, comma and parens
8130 pst title=[[Ns:Somearticle, Context (context)]]
8134 [[Ns:Article (context)|Article]]
8138 pre-save transform: context links ("pipe trick") with namespace, parens and comma
8140 pst title=[[Ns:Somearticle (IGNORED), Context]]
8144 [[Ns:Article, Context|Article]]
8148 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
8152 [[Article(context)|]]
8153 [[Bar:Article(context)|]]
8154 [[:Bar:Article(context)|]]
8155 [[|Article(context)]]
8159 [[Article(context)|Article]]
8160 [[Bar:Article(context)|Article]]
8161 [[:Bar:Article(context)|Article]]
8162 [[Article(context)]]
8164 [[:Bar:X(Y)Z|X(Y)Z]]
8168 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
8172 [[Article (context)|]]
8173 [[Bar:Article (context)|]]
8174 [[:Bar:Article (context)|]]
8175 [[|Article (context)]]
8179 [[Article (context)|Article]]
8180 [[Bar:Article (context)|Article]]
8181 [[:Bar:Article (context)|Article]]
8182 [[Article (context)]]
8183 [[Bar:X (Y) Z|X (Y) Z]]
8184 [[:Bar:X (Y) Z|X (Y) Z]]
8188 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
8192 [[Article(context)|]]
8193 [[Bar:Article(context)|]]
8194 [[:Bar:Article(context)|]]
8195 [[|Article(context)]]
8199 [[Article(context)|Article]]
8200 [[Bar:Article(context)|Article]]
8201 [[:Bar:Article(context)|Article]]
8202 [[Article(context)]]
8204 [[:Bar:X(Y)Z|X(Y)Z]]
8208 pre-save transform: context links ("pipe trick") with commas (bug 21660)
8212 [[Article (context), context|]]
8213 [[Article (context),context|]]
8214 [[Bar:Article (context), context|]]
8215 [[Bar:Article (context),context|]]
8216 [[:Bar:Article (context), context|]]
8217 [[:Bar:Article (context),context|]]
8219 [[Article (context), context|Article]]
8220 [[Article (context),context|Article]]
8221 [[Bar:Article (context), context|Article]]
8222 [[Bar:Article (context),context|Article]]
8223 [[:Bar:Article (context), context|Article]]
8224 [[:Bar:Article (context),context|Article]]
8228 pre-save transform: trim trailing empty lines
8232 Empty lines are trimmed
8238 Empty lines are trimmed
8242 pre-save transform: Signature expansion
8247 * <noinclude>~~~</noinclude>
8248 * <includeonly>~~~</includeonly>
8249 * <onlyinclude>~~~</onlyinclude>
8251 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
8252 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
8253 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
8254 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
8259 pre-save transform: Signature expansion in nowiki tags (bug 93)
8265 <nowiki>~~~~</nowiki>
8267 <includeonly><nowiki>~~~~</nowiki></includeonly>
8269 <noinclude><nowiki>~~~~</nowiki></noinclude>
8271 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
8273 {{subst:Foo}} shall be converted to FOO
8275 As well as inside noinclude/onlyinclude
8276 <noinclude>{{subst:Foo}}</noinclude>
8277 <onlyinclude>{{subst:Foo}}</onlyinclude>
8279 But not inside includeonly
8280 <includeonly>{{subst:Foo}}</includeonly>
8284 <nowiki>~~~~</nowiki>
8286 <includeonly><nowiki>~~~~</nowiki></includeonly>
8288 <noinclude><nowiki>~~~~</nowiki></noinclude>
8290 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
8292 FOO shall be converted to FOO
8294 As well as inside noinclude/onlyinclude
8295 <noinclude>FOO</noinclude>
8296 <onlyinclude>FOO</onlyinclude>
8298 But not inside includeonly
8299 <includeonly>{{subst:Foo}}</includeonly>
8303 Parsoid: Recognize nowiki with trailing space in tags
8307 <nowiki ><div>[[foo]]</nowiki >
8315 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
8322 Parsoid: Recognize nowiki with odd capitalization
8326 <noWikI ><div>[[foo]]</Nowiki >
8328 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
8333 Parsoid: Escape nowiki with trailing space in tags
8337 <nowiki > foo </nowiki >
8343 <p><nowiki > foo </nowiki ></p>
8344 <p>a<nowiki />b</p>
8345 <p>c<nowiki/ >d</p>
8349 Parsoid: Escape weird noWikI capitalizations
8353 <noWikI > foo </NoWikI >
8355 <p><noWikI > foo </NoWikI ></p>
8359 ### Message transform tests
8362 message transform: magic variables
8372 message transform: should not transform wiki markup
8382 message transform: <noinclude> in transcluded template (bug 4926)
8392 message transform: <onlyinclude> in transcluded template (bug 4926)
8402 {{#special:}} page name, known
8406 {{#special:Recentchanges}}
8408 Special:RecentChanges
8412 {{#special:}} page name with subpage, known
8416 {{#special:Recentchanges/param}}
8418 Special:RecentChanges/param
8422 {{#special:}} page name, unknown
8426 {{#special:foobar nonexistent}}
8428 Special:Foobar nonexistent
8432 {{#speciale:}} page name, known
8436 {{#speciale:Recentchanges}}
8438 Special:RecentChanges
8442 {{#speciale:}} page name with subpage, known
8446 {{#speciale:Recentchanges/param}}
8448 Special:RecentChanges/param
8452 {{#speciale:}} page name, unknown
8456 {{#speciale:foobar nonexistent}}
8458 Special:Foobar_nonexistent
8464 ### For Parsoid-specific tests, see
8465 #### http://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
8472 [[Image:foobar.jpg]]
8474 <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>
8479 Simple image (parsoid)
8483 [[Image:foobar.jpg]]
8485 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>
8490 Simple image (using File: namespace, now canonical) (php)
8496 <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>
8501 Simple image (using File: namespace, now canonical) (parsoid)
8507 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>
8512 Right-aligned image (php)
8516 [[Image:foobar.jpg|right]]
8518 <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>
8523 Right-aligned image (parsoid)
8527 [[File:Foobar.jpg|right]]
8529 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>
8533 Image with caption (php)
8537 [[File:Foobar.jpg|right|Caption text]]
8539 <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>
8544 Image with caption (parsoid)
8548 [[File:Foobar.jpg|right|Caption text]]
8550 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
8554 Image with empty attribute (php)
8558 [[File:Foobar.jpg|right||Caption text]]
8560 <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>
8565 Image with empty attribute (parsoid)
8569 [[File:Foobar.jpg|right||Caption text]]
8571 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
8575 Image with attributes from template (php)
8579 [[File:Foobar.jpg|{{image_attribs}}]]
8581 <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>
8586 Image with attributes from template (parsoid)
8590 [[File:Foobar.jpg|{{image_attribs}}]]
8592 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
8596 Image with link tails (php)
8600 123[[File:Foobar.jpg]]456
8601 123[[File:Foobar.jpg|right]]456
8602 123[[File:Foobar.jpg|thumb]]456
8604 <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
8606 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
8607 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
8612 Image with link tails (parsoid)
8616 123[[File:Foobar.jpg]]456
8617 123[[File:Foobar.jpg|right]]456
8618 123[[File:Foobar.jpg|thumb]]456
8620 <p>123<span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>456</p>
8621 123<figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>456
8622 123<figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="20" width="180"></a></figure>456
8626 Image with multiple captions -- only last one is accepted (php)
8630 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
8632 <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>
8637 Image with multiple captions -- only last one is accepted (parsoid)
8641 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
8643 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption3 - accepted</figcaption></figure>
8647 Image with width attribute at different positions (php)
8651 [[File:Foobar.jpg|200px|right|Caption]]
8652 [[File:Foobar.jpg|right|200px|Caption]]
8653 [[File:Foobar.jpg|right|Caption|200px]]
8655 <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>
8656 <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>
8657 <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>
8662 Image with width attribute at different positions (parsoid)
8666 [[File:Foobar.jpg|200px|right|Caption]]
8667 [[File:Foobar.jpg|right|200px|Caption]]
8668 [[File:Foobar.jpg|right|Caption|200px]]
8670 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
8671 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
8672 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
8676 Image with link parameter, wiki target (php)
8680 [[File:Foobar.jpg|link=Main Page]]
8682 <p><a href="/wiki/Main_Page" title="Main Page"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8687 Image with link parameter, wiki target (parsoid)
8691 [[File:Foobar.jpg|link=Main Page]]
8693 <p><span class="mw-default-size" typeof="mw:Image"><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
8697 Image with link parameter, URL target (php)
8701 [[File:Foobar.jpg|link=http://example.com/]]
8703 <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>
8707 # parsoid bug 49293 (part 1)
8709 Image with link parameter, URL target (parsoid)
8713 [[File:Foobar.jpg|link=http://example.com/]]
8715 <p><span class="mw-default-size" typeof="mw:Image"><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
8719 Image with link parameter, protocol-less URL target (php)
8723 [[File:Foobar.jpg|link=//example.com/]]
8725 <p><a href="//example.com/" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8729 # parsoid bug 49293 (part 2)
8731 Image with link parameter, protocol-less URL target (parsoid)
8735 [[File:Foobar.jpg|link=//example.com/]]
8737 <p><span class="mw-default-size" typeof="mw:Image"><a href="//example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
8741 Image with link parameter, wgExternalLinkTarget
8743 [[Image:foobar.jpg|link=http://example.com/]]
8745 wgExternalLinkTarget='foobar'
8747 <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>
8752 Image with link parameter, wgNoFollowLinks set to false
8754 [[Image:foobar.jpg|link=http://example.com/]]
8756 wgNoFollowLinks=false
8758 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8763 Image with link parameter, wgNoFollowDomainExceptions
8765 [[Image:foobar.jpg|link=http://example.com/]]
8767 wgNoFollowDomainExceptions='example.com'
8769 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8774 Image with link parameter, wgExternalLinkTarget, unnamed parameter
8776 [[Image:foobar.jpg|link=http://example.com/|Title]]
8778 wgExternalLinkTarget='foobar'
8780 <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>
8785 Image with empty link parameter (php)
8789 [[File:Foobar.jpg|link=]]
8791 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
8796 Image with empty link parameter (parsoid)
8800 [[File:Foobar.jpg|link=]]
8802 <p><span class="mw-default-size" typeof="mw:Image"><span><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></span></span></p>
8806 Image with link parameter (wiki target) and unnamed parameter (php)
8810 [[File:Foobar.jpg|link=Main Page|Title]]
8812 <p><a href="/wiki/Main_Page" title="Title"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8817 Image with link parameter (wiki target) and unnamed parameter (parsoid)
8821 [[File:Foobar.jpg|link=Main Page|Title]]
8823 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
8827 Image with link parameter (URL target) and unnamed parameter (php)
8831 [[File:Foobar.jpg|link=http://example.com/|Title]]
8833 <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>
8838 Image with link parameter (URL target) and unnamed parameter (parsoid)
8842 [[File:Foobar.jpg|link=http://example.com/|Title]]
8844 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
8848 Thumbnail image with link parameter
8852 [[Image:foobar.jpg|thumb|link=http://example.com/|Title]]
8854 <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>
8859 Manually-specified thumbnail image
8863 [[Image:Foobar.jpg|thumb=Thumb.png|Title]]
8865 <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>
8870 Manually-specified thumbnail image with explicit link to wiki page
8874 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|Title]]
8876 <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>
8881 Manually-specified thumbnail image with explicit link to url
8885 [[Image:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
8887 <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>
8892 Manually-specified thumbnail image with explicit no link
8896 [[Image:Foobar.jpg|thumb=Thumb.png|link=|Title]]
8898 <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>
8903 Manually-specified thumbnail image with explicit link and alt text
8907 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|alt=alttext|Title]]
8909 <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>
8914 Image with frame and link
8916 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
8918 <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>
8923 Image with frame and link and explicit alt
8925 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
8927 <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>
8932 Image with wiki markup in implicit alt
8934 [[Image:Foobar.jpg|testing '''bold''' in alt]]
8936 <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>
8941 Image with wiki markup in explicit alt
8943 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
8945 <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>
8950 Link to image page- image page normally doesn't exists, hence edit link
8951 Add test with existing image page
8952 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
8956 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
8961 bug 18784 Link to non-existent image page with caption should use caption as link text
8963 [[:Image:test|caption]]
8965 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
8970 Frameless image caption with a free URL
8972 [[Image:foobar.jpg|http://example.com]]
8974 <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>
8979 Thumbnail image caption with a free URL
8981 [[Image:foobar.jpg|thumb|http://example.com]]
8983 <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>
8988 Thumbnail image caption with a free URL and explicit alt
8990 [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]]
8992 <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>
8997 SVG thumbnails with no language set
9000 [[File:Foobar.svg|thumb|width=200]]
9002 <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>
9007 SVG thumbnails with language de
9010 [[File:Foobar.svg|thumb|width=200|lang=de]]
9012 <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>
9017 SVG thumbnails with invalid language code
9020 [[File:Foobar.svg|thumb|width=200|lang=invalid.language.code]]
9022 <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>
9027 BUG 1887: A ISBN with a thumbnail
9029 [[Image:foobar.jpg|thumb|ISBN 1235467890]]
9031 <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>
9036 BUG 1887: A RFC with a thumbnail
9038 [[Image:foobar.jpg|thumb|This is RFC 12354]]
9040 <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>
9045 BUG 1887: A mailto link with a thumbnail
9047 [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]]
9049 <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>
9053 # Pending resolution to bug 368
9055 BUG 648: Frameless image caption with a link
9057 [[Image:foobar.jpg|text with a [[link]] in it]]
9059 <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>
9064 BUG 648: Frameless image caption with a link (suffix)
9066 [[Image:foobar.jpg|text with a [[link]]foo in it]]
9068 <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>
9073 BUG 648: Frameless image caption with an interwiki link
9075 [[Image:foobar.jpg|text with a [[MeatBall:Link]] in it]]
9077 <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>
9082 BUG 648: Frameless image caption with a piped interwiki link
9084 [[Image:foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
9086 <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>
9091 Escape HTML special chars in image alt text
9093 [[Image:foobar.jpg|& < > "]]
9095 <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>
9100 BUG 499: Alt text should have Ӓ, not &1234;
9102 [[Image:foobar.jpg|♀]]
9104 <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>
9109 Broken image caption with link
9111 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
9113 <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.
9118 Image caption containing another image
9120 [[Image:Foobar.jpg|thumb|This is a caption with another [[Image:icon.png|image]] inside it!]]
9122 <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>
9127 Image caption containing a newline
9129 [[Image:Foobar.jpg|This
9132 <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>
9137 Parsoid: Image caption containing leading space
9138 (The leading space should not trigger nowiki escaping in wt2wt mode)
9140 [[Image:Foobar.jpg|thumb| bar]]
9142 <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>
9147 Bug 3090: External links other than http: in image captions
9149 [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
9151 <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>
9158 [[Image:foobar.jpg|a|class=b]]
9160 <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>
9165 Localized image handling (1).
9169 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
9171 <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>
9176 Localized image handling (2).
9180 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
9182 <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>
9187 "border", "frameless" and "class" attributes on an image.
9189 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
9191 <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>
9198 #REDIRECT [[File:Barfoo.jpg]]
9204 [[Image:Barfoo.jpg]]
9206 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
9211 Missing image with uploads disabled
9215 [[Image:Foobaz.jpg]]
9217 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
9221 # Parsoid-specific testing for images
9222 # http://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
9223 # Currently imperfect due to a flaw in the Parsoid testrunner
9225 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
9229 Parsoid-specific image handling - simple image with size and middle alignment
9233 [[Image:Foobar.jpg|50px|middle]]
9236 <span class="mw-valign-middle" typeof="mw:Image">
9237 <a href="File:Foobar.jpg">
9238 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
9245 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
9249 [[Image:Foobar.jpg|500x10px|baseline|caption]]
9252 <span class="mw-valign-baseline" typeof="mw:Image" data-mw="{"caption":"caption"}">
9253 <a href="File:Foobar.jpg">
9254 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/89px-Foobar.jpg" height="10" width="89">
9261 Parsoid-specific image handling - simple image with border and size spec
9265 [[Image:Foobar.jpg|50px|border|caption]]
9268 <span class="mw-image-border" typeof="mw:Image" data-mw="{"caption":"caption"}">
9269 <a href="File:Foobar.jpg">
9270 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
9277 Parsoid-specific image handling - thumbnail with halign, valign, and caption
9281 [[Image:Foobar.jpg|thumb|left|baseline|caption content]]
9283 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb">
9284 <a href="File:Foobar.jpg">
9285 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="21" width="180" />
9287 <figcaption>caption content</figcaption>
9292 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
9296 [[Image:Foobar.jpg|thumb|50x50px|right|middle|caption]]
9298 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb">
9299 <a href="File:Foobar.jpg">
9300 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" />
9302 <figcaption>caption</figcaption>
9307 Parsoid-specific image handling - framed image with specific size and caption
9311 [[Image:Foobar.jpg|500x50px|frame|caption]]
9313 <figure typeof="mw:Image/Frame">
9314 <a href="File:Foobar.jpg">
9315 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
9317 <figcaption>caption</figcaption>
9322 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
9326 [[Image:Foobar.jpg|500x50px|frame|left|baseline|caption]]
9328 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame">
9329 <a href="File:Foobar.jpg">
9330 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
9332 <figcaption>caption</figcaption>
9337 Parsoid-specific image handling - frameless image with specific size, border, and caption
9341 [[Image:Foobar.jpg|frameless|500x50px|border|caption]]
9344 <span class="mw-image-border" typeof="mw:Image/Frameless" data-mw="{"caption":"caption"}">
9345 <a href="File:Foobar.jpg">
9346 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
9352 #Parsoid-specific image handling - simple image with a formatted caption
9356 #[[Image:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
9359 #<span typeof="mw:Image">
9360 #<a class="mw-default-size" href="Image:Foobar.jpg">
9361 #<img alt="Foobar.jpg" class="mw-default-size" src="http://example.com/images/3/3a/Foobar.jpg" height="220" width="1941">
9372 Subpage test/subpage
9380 subpage title=[[Subpage test]]
9384 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
9389 Subpage noslash link
9391 subpage title=[[Subpage test]]
9395 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
9399 # TODO: make this PHP-parser compatible!
9401 Relative subpage noslash link
9403 parsoid=wt2wt,wt2html,html2html
9404 subpage title=[[Subpage test/1/2/3/4]]
9410 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage/">subpage</a></p>
9411 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
9414 # TODO: make this PHP-parser compatible!
9416 Parsoid: dot-slash prefixed wikilinks
9418 parsoid=wt2wt,wt2html,html2html
9426 <p><a rel="mw:WikiLink" href="./Foo">foo</a></p>
9427 <p><a rel="mw:WikiLink" href="./Bar">bar</a></p>
9428 <p><a rel="mw:WikiLink" href="./Baz/">baz/</a></p>
9436 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
9441 BUG 561: {{/Subpage}}
9443 subpage title=[[Page]]
9447 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
9455 Category:MediaWiki User's Guide
9463 [[:Category:MediaWiki User's Guide]]
9465 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
9474 [[Category:MediaWiki User's Guide]]
9476 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
9480 PAGESINCATEGORY invalid title fatal (r33546 fix)
9482 {{PAGESINCATEGORY:<bogus>}}
9489 Category with different sort key
9493 [[Category:MediaWiki User's Guide|Foo]]
9495 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
9499 Category with identical sort key
9503 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
9505 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
9509 Category with empty sort key
9514 [[Category:MediaWiki User's Guide|]]
9516 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
9520 Category with empty sort key and parentheses
9525 [[Category:Foo (bar)|]]
9527 [[Category:Foo (bar)|Foo]]
9531 Category with link tail
9536 123[[Category:Foo]]456
9538 123[[Category:Foo]]456
9542 Category with template
9547 [[Category:{{echo|Foo}}]]
9549 [[Category:{{echo|Foo}}]]
9553 Category with template in sort key
9558 [[Category:Foo|{{echo|Bar}}]]
9560 [[Category:Foo|{{echo|Bar}}]]
9564 Category with template in sort key and title
9569 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
9571 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
9575 Category / paragraph interactions
9577 Foo [[Category:Baz]] Bar
9579 Foo [[Category:Baz]]
9587 [[Category:Baz]] Bar
9600 {{echo|[[Category:Baz]]}}
9615 Parsoid: Serialize link to category page with colon escape
9621 [[:Category:Foo|Bar]]
9624 <a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a>
9625 <a rel="mw:WikiLink" href="Category:Foo">Bar</a>
9630 Parsoid: Link prefix/suffixes aren't applied to category links
9632 parsoid=wt2html,wt2wt,html2html
9637 <p>x<link rel="mw:WikiLink/Category" href="Category:Foo">y</p>
9641 Parsoid: Serialize link to file page with colon escape
9647 [[:File:Foo.png|Bar]]
9650 <a rel="mw:WikiLink" href="File:Foo.png">File:Foo.png</a>
9651 <a rel="mw:WikiLink" href="File:Foo.png">Bar</a>
9656 Parsoid: Serialize a genuine category link without colon escape
9661 [[Category:Foo|Bar]]
9663 <link rel="mw:WikiLink/Category" href="Category:Foo">
9664 <link rel="mw:WikiLink/Category" href="Category:Foo#Bar">
9668 ### Inter-language links
9671 Inter-language links
9677 [[zh:食品]]
9679 es:Alimento fr:Nourriture zh:食品
9683 Duplicate interlanguage links (bug 24502)
9699 Basic section headings
9706 ===Smaller headline===
9709 <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>
9712 <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>
9715 <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>
9721 Section headings with TOC
9724 === Subheadline 1 ===
9725 ===== Skipping a level =====
9726 ====== Skipping a level ======
9730 ===Another headline===
9732 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9734 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
9736 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
9738 <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>
9740 <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>
9747 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
9749 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
9754 <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>
9755 <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>
9756 <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>
9757 <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>
9758 <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>
9761 <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>
9765 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
9767 Handling of sections up to level 6 and beyond
9770 == Level 2 Heading==
9771 === Level 3 Heading===
9772 ==== Level 4 Heading====
9773 ===== Level 5 Heading=====
9774 ====== Level 6 Heading======
9775 ======= Level 7 Heading=======
9776 ======== Level 8 Heading========
9777 ========= Level 9 Heading=========
9778 ========== Level 10 Heading==========
9780 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9782 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
9784 <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>
9786 <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>
9788 <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>
9790 <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>
9792 <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>
9793 <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>
9794 <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>
9795 <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>
9796 <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>
9809 <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>
9810 <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>
9811 <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>
9812 <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>
9813 <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>
9814 <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>
9815 <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>
9816 <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>
9817 <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>
9818 <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>
9823 TOC regression (bug 9764)
9827 ==== title 1.1.1 ====
9832 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9834 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9836 <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>
9838 <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>
9841 <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>
9844 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
9846 <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>
9851 <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>
9852 <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>
9853 <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>
9854 <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>
9855 <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>
9856 <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>
9861 TOC with wgMaxTocLevel=3 (bug 6204)
9867 ==== title 1.1.1 ====
9872 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9874 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9876 <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>
9877 <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>
9880 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
9882 <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>
9887 <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>
9888 <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>
9889 <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>
9890 <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>
9891 <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>
9892 <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>
9897 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
9903 ====Section 1.1.1====
9904 ====Section 1.1.1.1====
9907 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9909 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
9911 <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>
9914 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
9917 <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>
9918 <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>
9919 <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>
9920 <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>
9921 <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>
9927 Resolving duplicate section names
9932 <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>
9933 <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>
9938 Resolving duplicate section names with differing case (bug 10721)
9943 <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>
9944 <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>
9956 Template with sections, __NOTOC__
9963 <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>
9964 <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>
9965 <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>
9966 <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>
9971 __NOEDITSECTION__ keyword
9977 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
9978 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
9983 Link inside a section heading
9985 ==Section with a [[Main Page|link]] in it==
9987 <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>
9992 TOC regression (bug 12077)
9999 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10001 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
10003 <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>
10006 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
10009 <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>
10010 <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>
10011 <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>
10016 BUG 1219 URL next to image (good)
10018 http://example.com [[Image:foobar.jpg]]
10020 <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>
10025 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
10028 The line above must have a trailing space!
10031 But just in case it doesn't...
10033 <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>
10034 <p>The line above must have a trailing space!
10036 <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>
10037 <p>But just in case it doesn't...
10042 Header with special characters (bug 25462)
10044 The tooltips shall not show entities to the user (ie. be double escaped)
10061 <p>The tooltips shall not show entities to the user (ie. be double escaped)
10063 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10065 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
10066 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
10067 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
10068 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
10069 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
10072 <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>
10075 <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>
10078 <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>
10081 <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>
10084 <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>
10090 Headers with excess '=' characters
10091 (Are similar tests necessary beyond the 1st level?)
10095 =''italic'' heading==
10096 ==''italic'' heading=
10098 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10100 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
10101 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
10102 <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>
10103 <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>
10106 <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>
10107 <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>
10108 <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>
10109 <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>
10114 HTML headers vs TOC (bug 23393)
10115 (__NOEDITSECTION__ for clearer output, doesn't matter here)
10127 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10129 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
10131 <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>
10132 <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>
10135 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
10137 <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>
10138 <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>
10143 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
10144 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
10145 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
10146 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
10147 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
10148 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
10153 BUG 1219 URL next to image (broken)
10155 http://example.com[[Image:foobar.jpg]]
10157 <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>
10162 Bug 1186 news: in the middle of text
10164 http://en.wikinews.org/wiki/Wikinews:Workplace
10166 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
10172 Namespaced link must have a title
10181 Namespaced link must have a title (bad fragment version)
10183 [[Project:#fragment]]
10185 <p>[[Project:#fragment]]
10191 ### HTML tags and HTML attributes
10195 div with no attributes
10197 <div>HTML rocks</div>
10199 <div>HTML rocks</div>
10204 div with double-quoted attribute
10206 <div id="rock">HTML rocks</div>
10208 <div id="rock">HTML rocks</div>
10213 div with single-quoted attribute
10215 <div id='rock'>HTML rocks</div>
10217 <div id="rock">HTML rocks</div>
10222 div with unquoted attribute
10224 <div id=rock>HTML rocks</div>
10226 <div id="rock">HTML rocks</div>
10231 div with illegal double attributes
10233 <div id="a" id="b">HTML rocks</div>
10235 <div id="b">HTML rocks</div>
10239 # FIXME: produce empty string instead of "class" in the PHP parser, following
10242 div with empty attribute value, space before equals
10246 <div class =>HTML rocks</div>
10248 <div class="">HTML rocks</div>
10252 # The PHP parser escapes the opening brace to { for some reason, so
10253 # disabled this test for it.
10255 div with braces in attribute value
10259 <div title="{}">Foo</div>
10261 <div title="{}">Foo</div>
10264 # This it very inconsistent in the PHP parser: it returns
10265 # class="class" if there is a space between the name and the equal sign (see
10266 # 'div with empty attribute value, space before equals'), but strips the
10267 # attribute completely if the space is missing. We hope that not much content
10268 # depends on this, so are implementing the behavior below in Parsoid for
10269 # consistencies' sake. Disabled for the PHP parser.
10270 # FIXME: fix this behavior in the PHP parser?
10272 div with empty attribute value, no space before equals
10276 <div class=>HTML rocks</div>
10278 <div class="">HTML rocks</div>
10283 HTML multiple attributes correction
10285 <p class="error" class="awesome">Awesome!</p>
10287 <p class="awesome">Awesome!</p>
10292 Table multiple attributes correction
10295 !+ class="error" class="awesome"| status
10300 <th class="awesome"> status
10308 <DIV ID="x">HTML ROCKS</DIV>
10310 <div id="x">HTML ROCKS</div>
10315 Non-ASCII pseudo-tags are rendered as text
10324 Pseudo-tag with URL 'name' renders as url link
10326 <http://example.com/>
10328 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
10333 text with amp in the middle of nowhere
10337 <p>Remember AT&T?
10342 text with character entity: eacute
10344 I always thought é was a cute letter.
10346 <p>I always thought é was a cute letter.
10351 text with entity-escaped character entity-like string: eacute
10353 I always thought &eacute; was a cute letter.
10355 <p>I always thought &eacute; was a cute letter.
10360 text with undefined character entity: xacute
10362 I always thought &xacute; was a cute letter.
10364 <p>I always thought &xacute; was a cute letter.
10370 ### Nesting tests (see bug 41545, 50604, 51081)
10373 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
10374 # Note that html2wt is considerably more difficult if we use <b> in
10375 # the test case, instead of <big>
10377 Ensure that HTML adoption agency algorithm is properly implemented.
10379 <big>X<big>Y</big>Z</big>
10381 <p><big>X<big>Y</big>Z</big>
10385 # This was bug 41545 in the PHP parser.
10389 <kbd>X<kbd>Y</kbd>Z</kbd>
10391 <p><kbd>X<kbd>Y</kbd>Z</kbd>
10395 # The following cases were bug 51081 in the PHP parser.
10396 # Note that there are some other nestable tags (b, i, etc) which are
10397 # not covered; see bug 51081 for discussion.
10401 <em>X<em>Y</em>Z</em>
10403 <p><em>X<em>Y</em>Z</em>
10408 Nesting of <strong>
10410 <strong>X<strong>Y</strong>Z</strong>
10412 <p><strong>X<strong>Y</strong>Z</strong>
10421 <p><q>X<q>Y</q>Z</q>
10428 <ruby>X<ruby>Y</ruby>Z</ruby>
10430 <p><ruby>X<ruby>Y</ruby>Z</ruby>
10437 <bdo>X<bdo>Y</bdo>Z</bdo>
10439 <p><bdo>X<bdo>Y</bdo>Z</bdo>
10451 [[Media:Foobar.jpg]]
10453 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
10458 Media link with text
10460 [[Media:Foobar.jpg|A neat file to look at]]
10462 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
10466 # FIXME: this is still bad HTML tag nesting
10468 Media link with nasty text
10469 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
10471 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
10473 <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>
10478 Media link to nonexistent file (bug 1702)
10480 [[Media:No such.jpg]]
10482 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
10487 Image link to nonexistent file (bug 1850 - good)
10489 [[Image:No such.jpg]]
10491 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
10496 :Image link to nonexistent file (bug 1850 - bad)
10498 [[:Image:No such.jpg]]
10500 <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>
10507 Character reference normalization in link text (bug 1938)
10509 [[Main Page|this&that]]
10511 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
10518 Test for unicode normalization
10520 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
10524 (bug 19451) Links should refer to the normalized form.
10532 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10533 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10534 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10535 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10536 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10541 Empty attribute crash test (bug 2067)
10543 <font color="">foo</font>
10545 <p><font color="">foo</font>
10550 Empty attribute crash test single-quotes (bug 2067)
10552 <font color=''>foo</font>
10554 <p><font color="">foo</font>
10559 Attribute test: equals, then nothing
10561 <font color=>foo</font>
10563 <p><font>foo</font>
10568 Attribute test: unquoted value
10570 <font color=x>foo</font>
10572 <p><font color="x">foo</font>
10577 Attribute test: unquoted but illegal value (hash)
10579 <font color=#x>foo</font>
10581 <p><font color="#x">foo</font>
10586 Attribute test: no value
10588 <font color>foo</font>
10590 <p><font color="color">foo</font>
10595 Bug 2095: link with three closing brackets
10599 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
10604 Bug 2095: link with pipe and three closing brackets
10606 [[Main Page|link]]]
10608 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
10613 Bug 2095: link with pipe and three closing brackets, version 2
10615 [[Main Page|[http://example.com/]]]
10617 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
10627 Template:Dangerous attribute
10629 " onmouseover="alert(document.cookie)
10633 Template:Dangerous style attribute
10635 border-size: expression(alert(document.cookie))
10641 <div style="float: right; {{{1}}}">Magic div</div>
10645 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
10647 <div title="{{test}}"></div>
10649 <div title="This is a test template"></div>
10654 Bug 2304: HTML attribute safety (dangerous template; 2309)
10656 <div title="{{dangerous attribute}}"></div>
10658 <div title=""></div>
10663 Bug 2304: HTML attribute safety (dangerous style template; 2309)
10665 <div style="{{dangerous style attribute}}"></div>
10667 <div style="/* insecure input */"></div>
10672 Bug 2304: HTML attribute safety (safe parameter; 2309)
10674 {{div style|width: 200px}}
10676 <div style="float: right; width: 200px">Magic div</div>
10681 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
10683 {{div style|width: expression(alert(document.cookie))}}
10685 <div style="/* insecure input */">Magic div</div>
10690 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
10692 {{div style|"><script>alert(document.cookie)</script>}}
10694 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
10699 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
10701 {{div style|" ><script>alert(document.cookie)</script>}}
10703 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
10708 Bug 2304: HTML attribute safety (link)
10710 <div title="[[Main Page]]"></div>
10712 <div title="[[Main Page]]"></div>
10717 Bug 2304: HTML attribute safety (italics)
10719 <div title="''foobar''"></div>
10721 <div title="''foobar''"></div>
10726 Bug 2304: HTML attribute safety (bold)
10728 <div title="'''foobar'''"></div>
10730 <div title="'''foobar'''"></div>
10736 Bug 2304: HTML attribute safety (ISBN)
10738 <div title="ISBN 1234567890"></div>
10740 <div title="ISBN 1234567890"></div>
10745 Bug 2304: HTML attribute safety (RFC)
10747 <div title="RFC 1234"></div>
10749 <div title="RFC 1234"></div>
10754 Bug 2304: HTML attribute safety (PMID)
10756 <div title="PMID 1234567890"></div>
10758 <div title="PMID 1234567890"></div>
10763 Bug 2304: HTML attribute safety (web link)
10765 <div title="http://example.com/"></div>
10767 <div title="http://example.com/"></div>
10772 Bug 2304: HTML attribute safety (named web link)
10774 <div title="[http://example.com/ link]"></div>
10776 <div title="[http://example.com/ link]"></div>
10781 Bug 3244: HTML attribute safety (extension; safe)
10783 <div style="<nowiki>background:blue</nowiki>"></div>
10785 <div style="background:blue"></div>
10790 Bug 3244: HTML attribute safety (extension; unsafe)
10792 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
10794 <div style="/* insecure input */"></div>
10798 # More MSIE fun discovered by Tom Gilder
10801 MSIE CSS safety test: spurious slash
10803 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
10805 <div style="/* insecure input */">evil</div>
10810 MSIE CSS safety test: hex code
10812 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
10814 <div style="/* insecure input */">evil</div>
10819 MSIE CSS safety test: comment in url
10821 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
10823 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
10828 MSIE CSS safety test: comment in expression
10830 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
10832 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
10838 Table attribute legitimate extension
10841 !+ style="<nowiki>color:blue</nowiki>"| status
10846 <th style="color:blue"> status
10852 Table attribute safety
10855 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
10860 <th style="/* insecure input */"> status
10866 CSS line continuation 1
10868 <div style="background-image: u\ rl(test.jpg);"></div>
10870 <div style="/* insecure input */"></div>
10875 CSS line continuation 2
10877 <div style="background-image: u\ rl(test.jpg); "></div>
10879 <div style="/* insecure input */"></div>
10890 Expansion of multi-line templates in attribute values (bug 6255)
10892 <div style="background: {{identity|#00FF00}}">-</div>
10894 <div style="background: #00FF00">-</div>
10900 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
10902 <div style="background:
10905 <div style="background: #00FF00">-</div>
10910 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
10912 <div style="background: #00FF00">-</div>
10914 <div style="background: #00FF00">-</div>
10919 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
10922 Parser hook: empty input
10935 Parser hook: empty input using terminated empty elements
10948 Parser hook: empty input using terminated empty elements (space before)
10961 Parser hook: basic input
10975 Parser hook: case insensitive
10989 Parser hook: case insensitive, redux
11002 Parser hook: nested tags
11006 <tag><tag></tag></tag>
11017 Parser hook: basic arguments
11019 <tag width=200 height = "100" depth = '50' square></tag>
11027 'square' => 'square',
11034 Parser hook: argument containing a forward slash (bug 5344)
11036 <tag filename='/tmp/bla'></tag>
11041 'filename' => '/tmp/bla',
11048 Parser hook: empty input using terminated empty elements (bug 2374)
11061 # </tag> should be output literally since there is no matching tag that begins it
11063 Parser hook: basic arguments using terminated empty elements (bug 2374)
11065 <tag width=200 height = "100" depth = '50' square/>
11075 'square' => 'square',
11084 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
11088 Parser hook: static parser hook not inside a comment
11090 <statictag>hello, world</statictag>
11091 <statictag action=flush/>
11099 Parser hook: static parser hook inside a comment
11101 <!-- <statictag>hello, world</statictag> -->
11102 <statictag action=flush/>
11108 # Nested template calls; this case was broken by Parser.php rev 1.506,
11112 Template:One-parameter
11114 (My parameter is: {{{1}}})
11118 Template:Map-one-parameter
11120 {{{{{1}}}|{{{2}}}}}
11124 Nested template calls
11126 {{Map-one-parameter|One-parameter|param}}
11128 <p>(My parameter is: param)
11137 Sanitizer: Closing of open tags
11139 <s></s><table></table>
11141 <s></s><table></table>
11146 Sanitizer: Closing of open but not closed tags
11155 Sanitizer: Closing of closed but not open tags
11164 Sanitizer: Closing of closed but not open table tags
11166 Table not started</td></tr></table>
11168 <p>Table not started</td></tr></table>
11173 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
11175 <span id="æ: v">byte</span>[[#æ: v|backlink]]
11177 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
11182 Sanitizer: Validating the contents of the id attribute (bug 4515)
11188 Something, but definitely not <br id="9" />...
11192 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
11196 <br id="foo" /><br id="foo" />
11198 Something need to be done. foo-2 ?
11202 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
11205 <meta itemprop="hello" content="world">
11206 <meta http-equiv="refresh" content="5">
11207 <meta itemprop="hello" http-equiv="refresh" content="5">
11208 <link itemprop="hello" href="{{SERVER}}">
11209 <link rel="stylesheet" href="{{SERVER}}">
11210 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
11213 <div itemscope="itemscope">
11214 <p> <meta itemprop="hello" content="world" />
11215 <meta http-equiv="refresh" content="5">
11216 <meta itemprop="hello" content="5" />
11218 <link itemprop="hello" href="http://example.org" />
11219 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
11220 <link itemprop="hello" href="http://example.org" />
11226 Language converter: output gets cut off unexpectedly (bug 5757)
11230 this bit is safe: }-
11232 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
11234 then we get cut off here: }-
11236 all additional text is vanished
11238 <p>this bit is safe: }-
11239 </p><p>but if we add a conversion instance: xxx
11240 </p><p>then we get cut off here: }-
11241 </p><p>all additional text is vanished
11246 Self closed html pairs (bug 5487)
11249 <center><font id="bug" />Centered text</center>
11250 <div><font id="bug2" />In div text</div>
11252 <center><font id="bug" />Centered text</center>
11253 <div><font id="bug2" />In div text</div>
11262 Punctuation: nbsp before exclamation
11266 <p>C'est grave !
11271 Punctuation: CSS !important (bug 11874)
11273 <div style="width:50% !important">important</div>
11275 <div style="width:50% !important">important</div>
11280 Punctuation: CSS ! important (bug 11874; with space after)
11282 <div style="width:50% ! important">important</div>
11284 <div style="width:50% ! important">important</div>
11290 HTML bullet list, closed tags (bug 5497)
11305 HTML bullet list, unclosed tags (bug 5497)
11322 HTML ordered list, closed tags (bug 5497)
11337 HTML ordered list, unclosed tags (bug 5497)
11354 HTML nested bullet list, closed tags (bug 5497)
11379 HTML nested bullet list, open tags (bug 5497)
11404 HTML nested ordered list, closed tags (bug 5497)
11429 HTML nested ordered list, open tags (bug 5497)
11454 HTML ordered list item with parameters oddity
11456 <ol><li id="fragment">One</li></ol>
11458 <ol><li id="fragment">One</li></ol>
11463 bug 5918: autonumbering
11465 [http://first/] [http://second] [ftp://ftp]
11469 [mailto:enclosed@mail.tld With target]
11471 [mailto:enclosed@mail.tld]
11473 mailto:inline@mail.tld
11475 <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>
11476 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
11477 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
11478 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
11479 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
11485 # Security and HTML correctness
11486 # From Nick Jenkins' fuzz testing
11490 Fuzz testing: Parser13
11505 Fuzz testing: Parser14
11510 <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>
11511 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11513 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
11520 Fuzz testing: Parser14-table
11525 <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>
11526 <table style="__TOC__">
11532 # Known to produce bogus xml (extra </td>)
11534 Fuzz testing: Parser16
11554 Fuzz testing: Parser21
11557 ! irc://{{ftp://a" onmouseover="alert('hello world');"
11562 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
11572 Fuzz testing: Parser22
11574 http://===r:::https://b
11578 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
11586 # Known to produce bad XML for now
11588 Fuzz testing: Parser24
11595 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
11596 <br style="onmouseover='alert(document.cookie);' " />
11598 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
11603 <u class="|">}}}} >
11604 <br style="onmouseover='alert(document.cookie);'" />
11606 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
11615 # Note: the current result listed for this is not what the original one was,
11616 # but the original bug was JavaScript injection, which is fixed in any case.
11617 # It's not clear that the original result listed was any more correct than the
11618 # current one. Original result:
11621 # <li class="||">
11622 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
11624 Fuzz testing: Parser25 (bug 6055)
11630 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
11632 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
11637 Fuzz testing: URL adjacent extension (with space, clean)
11640 http://example.com <nowiki>junk</nowiki>
11642 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
11647 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
11650 http://example.com<nowiki>junk</nowiki>
11652 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
11657 Fuzz testing: URL adjacent extension (no space, dirty; pre)
11660 http://example.com<pre>junk</pre>
11662 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
11667 Fuzz testing: image with bogus manual thumbnail
11669 [[Image:foobar.jpg|thumbnail= ]]
11671 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
11676 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
11678 <pre dir=" "></pre>
11680 <pre dir=" "></pre>
11685 Parsing optional HTML elements (Bug 6171)
11690 <td> Some tabular data</td>
11691 <td> More tabular data ...
11692 <td> And yet som tabular data</td>
11698 <td> Some tabular data</td>
11699 <td> More tabular data ...
11700 </td><td> And yet som tabular data</td>
11707 Correct handling of <td>, <tr> (Bug 6171)
11712 <td> Some tabular data</td>
11713 <td> More tabular data ...</td>
11714 <td> And yet som tabular data</td>
11720 <td> Some tabular data</td>
11721 <td> More tabular data ...</td>
11722 <td> And yet som tabular data</td>
11730 Parsing crashing regression (fr:JavaScript)
11734 <p></body></x>
11739 Inline wiki vs wiki block nesting
11745 <p><b>Bold paragraph</b>
11746 </p><p>New wiki paragraph
11751 Inline HTML vs wiki block nesting
11759 <p><b>Bold paragraph</b>
11760 </p><p>New wiki paragraph
11764 # Original result was this:
11765 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
11767 # While that might be marginally more intuitive, maybe, the six-apostrophe
11768 # construct is clearly pathological and the result stated here (which is what
11769 # the parser actually does) is about as reasonable as anything.
11771 Mixing markup for italics and bold
11774 '''bold''''''bold''bolditalics'''''
11776 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
11784 Article for special page transclusion test
11788 Special page transclusion
11791 {{Special:Prefixindex/Xyzzyx}}
11793 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11798 Special page transclusion twice (bug 5021)
11801 {{Special:Prefixindex/Xyzzyx}}
11802 {{Special:Prefixindex/Xyzzyx}}
11804 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11805 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11810 Transclusion of default MediaWiki message
11812 {{MediaWiki:Mainpage}}
11819 Transclusion of nonexistent MediaWiki message
11821 {{MediaWiki:Mainpagexxx}}
11823 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
11828 Transclusion of MediaWiki message with underscore
11830 {{MediaWiki:history_short}}
11837 Transclusion of MediaWiki message with space
11839 {{MediaWiki:history short}}
11846 Invalid header with following text
11856 Section extraction test (section 0)
11876 Section extraction test (section 1)
11898 Section extraction test (section 2)
11919 Section extraction test (section 3)
11939 Section extraction test (section 4)
11963 Section extraction test (section 5)
11983 Section extraction test (section 6)
12004 Section extraction test (section 7)
12024 Section extraction test (section 8)
12044 Section extraction test (section 9)
12065 Section extraction test (section 10)
12085 Section extraction test (nonexistent section 11)
12104 Section extraction test with bogus heading (section 1)
12109 ==bogus== not a legal section
12113 ==bogus== not a legal section
12117 Section extraction test with bogus heading (section 2)
12122 ==bogus== not a legal section
12129 Section extraction test with comment after heading (section 1)
12141 Section extraction test with comment after heading (section 2)
12153 Section extraction test with bogus <nowiki> heading (section 1)
12158 ==bogus== <nowiki>not a legal section</nowiki>
12162 ==bogus== <nowiki>not a legal section</nowiki>
12166 Section extraction test with bogus <nowiki> heading (section 2)
12171 ==bogus== <nowiki>not a legal section</nowiki>
12178 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
12179 # instead of respecting commented sections
12181 Section extraction prefixed by comment (section 1)
12192 Section extraction prefixed by comment (section 2)
12203 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
12204 # instead of respecting HTML-style headings
12206 Section extraction, mixed wiki and html (section 1)
12222 Section extraction, mixed wiki and html (section 2)
12238 # Formerly testing for bug 3342
12240 Section extraction, heading surrounded by <noinclude>
12244 <noinclude>==unmarked==</noinclude>
12250 # Test behavior of bug 19910
12252 Sectiion with all-equals
12257 The line above must have a trailing space
12260 But just in case it doesn't...
12264 But just in case it doesn't...
12268 Section replacement test (section 0)
12299 Section replacement test (section 1)
12328 Section replacement test (section 2)
12358 Section replacement test (section 3)
12389 Section replacement test (section 4)
12416 Section replacement test (section 5)
12447 Section replacement test (section 6)
12477 Section replacement test (section 7)
12508 Section replacement test (section 8)
12539 Section replacement test (section 9)
12568 Section replacement test (section 10)
12598 Section replacement test with initial whitespace (bug 13728)
12602 Preformatted initial line
12606 Preformatted initial line
12613 Section extraction, heading followed by pre with 20 spaces (bug 6398)
12625 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
12638 Section extraction, <pre> around bogus header (bug 10309)
12655 Section replacement, <pre> around bogus header (bug 10309)
12657 noxml replace=2,"xxx"
12678 Handling of 
 in URLs
12682 <ul><li><ul><li><a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a>
12689 5 quotes, code coverage +1 line (php)
12696 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
12698 5 quotes, code coverage +1 line (parsoid)
12704 <p><i><b></b></i></p>
12708 Special:Search page linking.
12712 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
12719 title=[[Parser test]]
12724 * {{FULLPAGENAMEE}}
12726 * {{BASEPAGENAMEE}}
12730 * {{ROOTPAGENAMEE}}
12732 * {{TALKPAGENAMEE}}
12733 * {{SUBJECTPAGENAME}}
12734 * {{SUBJECTPAGENAMEE}}
12737 * {{NAMESPACENUMBER}}
12741 * {{SUBJECTSPACEE}}
12742 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
12744 <ul><li> Parser test
12745 </li><li> Parser_test
12746 </li><li> Parser test
12747 </li><li> Parser_test
12748 </li><li> Parser test
12749 </li><li> Parser_test
12750 </li><li> Parser test
12751 </li><li> Parser_test
12752 </li><li> Parser test
12753 </li><li> Parser_test
12754 </li><li> Talk:Parser test
12755 </li><li> Talk:Parser_test
12756 </li><li> Parser test
12757 </li><li> Parser_test
12765 </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>
12769 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
12779 image4 |300px| centre
12780 image5.svg| http://///////
12785 <ul class="gallery mw-gallery-traditional">
12786 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12787 <div class="thumb" style="height: 150px;">Image1.png</div>
12788 <div class="gallerytext">
12791 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12792 <div class="thumb" style="height: 150px;">Image2.gif</div>
12793 <div class="gallerytext">
12798 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12799 <div class="thumb" style="height: 150px;">Image3</div>
12800 <div class="gallerytext">
12803 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12804 <div class="thumb" style="height: 150px;">Image4</div>
12805 <div class="gallerytext">
12810 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12811 <div class="thumb" style="height: 150px;">Image5.svg</div>
12812 <div class="gallerytext">
12813 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
12817 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12818 <div class="thumb" style="height: 150px;">* image6</div>
12819 <div class="gallerytext">
12827 Gallery (with options)
12829 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
12830 File:Nonexistant.jpg|caption
12831 File:Nonexistant.jpg
12832 image:foobar.jpg|some '''caption''' [[Main Page]]
12834 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
12837 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
12838 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
12839 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12840 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
12841 <div class="gallerytext">
12846 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12847 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
12848 <div class="gallerytext">
12851 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12852 <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>
12853 <div class="gallerytext">
12854 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
12858 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12859 <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>
12860 <div class="gallerytext">
12863 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12864 <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>
12865 <div class="gallerytext">
12875 Gallery with wikitext inside caption
12878 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
12879 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
12882 <ul class="gallery mw-gallery-traditional">
12883 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12884 <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>
12885 <div class="gallerytext">
12886 <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>
12890 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12891 <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>
12892 <div class="gallerytext">
12893 <p>This is a test template
12902 gallery (with showfilename option)
12904 <gallery showfilename>
12905 File:Nonexistant.jpg|caption
12906 File:Nonexistant.jpg
12907 image:foobar.jpg|some '''caption''' [[Main Page]]
12911 <ul class="gallery mw-gallery-traditional">
12912 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12913 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
12914 <div class="gallerytext">
12915 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
12920 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12921 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
12922 <div class="gallerytext">
12923 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
12927 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12928 <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>
12929 <div class="gallerytext">
12930 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
12931 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
12935 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12936 <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>
12937 <div class="gallerytext">
12938 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
12947 Gallery (with namespace-less filenames)
12950 File:Nonexistant.jpg
12956 <ul class="gallery mw-gallery-traditional">
12957 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12958 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
12959 <div class="gallerytext">
12962 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12963 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
12964 <div class="gallerytext">
12967 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12968 <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>
12969 <div class="gallerytext">
12972 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12973 <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>
12974 <div class="gallerytext">
12982 HTML Hex character encoding (spells the word "JavaScript")
12984 JavaScript
12986 <p>JavaScript
12991 HTML Hex character encoding bogus encoding (bug 26437 regression check)
12995 <p>&#xsee;&#XSEE;
13000 HTML Hex character encoding mixed case
13009 __FORCETOC__ override
13021 ISBN 978-0-1234-56 789
13023 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
13028 ISBN followed by 5 spaces
13039 ISBN ISBN 1234567890
13041 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
13046 Bug 22905: <abbr> followed by ISBN followed by </a>
13048 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
13050 <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>
13059 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
13064 Double RFC with a wiki link
13068 <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>
13077 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
13082 Centre-aligned image
13084 [[Image:foobar.jpg|centre]]
13086 <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>
13093 [[Image:foobar.jpg|none]]
13095 <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>
13100 Width + Height sized image (using px) (height is ignored)
13102 [[Image:foobar.jpg|640x480px]]
13104 <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>
13109 Width-sized image (using px, no following whitespace)
13111 [[Image:foobar.jpg|640px]]
13113 <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>
13118 Width-sized image (using px, with following whitespace - test regression from r39467)
13120 [[Image:foobar.jpg|640px ]]
13122 <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>
13127 Width-sized image (using px, with preceding whitespace - test regression from r39467)
13129 [[Image:foobar.jpg| 640px]]
13131 <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>
13136 Another italics / bold test
13144 # Note the results may be incorrect, as parserTest output included this:
13145 # XML error: Mismatched tag at byte 6120:
13146 # ...<dd> </dt></dl> </dd...
13154 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd>
13165 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
13167 Images with the "|" character in the comment
13169 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
13171 <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>
13176 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
13178 <html><script>alert(1);</script></html>
13180 <p><html><script>alert(1);</script></html>
13185 HTML with raw HTML ($wgRawHtml==true)
13189 <html><script>alert(1);</script></html>
13191 <p><script>alert(1);</script>
13196 Parents of subpages, one level up
13198 subpage title=[[Subpage test/L1/L2/L3]]
13202 <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>
13208 Parents of subpages, one level up, not named
13210 subpage title=[[Subpage test/L1/L2/L3]]
13214 <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>
13221 Parents of subpages, two levels up
13223 subpage title=[[Subpage test/L1/L2/L3]]
13229 <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
13230 </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>
13235 Parents of subpages, two levels up, without trailing slash or name.
13237 subpage title=[[Subpage test/L1/L2/L3]]
13246 Parents of subpages, two levels up, with lots of extra trailing slashes.
13248 subpage title=[[Subpage test/L1/L2/L3]]
13252 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
13257 Subpage test/L1/L2/L3Sibling
13263 Transclusion of a sibling page (one level up)
13265 subpage title=[[Subpage test/L1/L2/L3]]
13274 Transclusion of a child page
13276 subpage title=[[Subpage test/L1/L2]]
13285 Non-transclusion because of too many up levels
13287 subpage title=[[Subpage test/L1/L2/L3]]
13289 {{../../../../More than parent}}
13291 <p>{{../../../../More than parent}}
13296 Definition list code coverage
13302 <dl><dt> title  </dt><dd> def
13303 </dd><dt> title </dt><dd> def
13304 </dd><dt>title</dt><dd> def
13310 Don't fall for the self-closing div
13312 <div>hello world</div/>
13314 <div>hello world</div>
13323 <p>[[:Template:Msg]]
13332 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
13336 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
13338 Always escape literal '>' in output, not just after '<'
13352 <p>This is a test template
13353 This is a test template
13365 Inclusion of !userCanEdit() content
13369 <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>
13375 Out-of-order TOC heading levels
13384 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13386 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
13388 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
13389 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
13392 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
13394 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
13395 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
13400 <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>
13401 <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>
13402 <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>
13403 <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>
13404 <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>
13405 <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>
13411 ISBN with a dummy number
13421 ISBN with space-delimited number
13425 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
13431 ISBN with multiple spaces, no number
13450 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
13451 </p><p>ISBN 12345678901
13457 ISBN with trailing year (bug 8110)
13459 ISBN 1-234-56789-0 - 2006
13461 ISBN 1 234 56789 0 - 2006
13463 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
13464 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
13472 {{anchorencode:foo bar©#%n}}
13474 <p>foo_bar.C2.A9.23.25n
13479 anchorencode trims spaces
13481 {{anchorencode: __pretty__please__}}
13488 anchorencode deals with links
13490 {{anchorencode: [[hello|world]] [[hi]]}}
13497 anchorencode deals with templates
13499 {{anchorencode: {{Foo}} }}
13506 anchorencode encodes like the TOC generator: (bug 18431)
13508 === _ +:.3A%3A&&]] ===
13509 {{anchorencode: _ +:.3A%3A&&]] }}
13512 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
13513 <p>.2B:.3A.253A.26.26.5D.5D
13517 # Expected output in the following test is not necessarily expected (there
13518 # should probably be <p> tags inside the <blockquote> in the output) -- it's
13519 # only testing for well-formedness.
13521 Bug 6200: blockquotes and paragraph formatting
13541 Bug 8293: Use of center tag ruins paragraph formatting
13562 Parsing of overlapping (improperly nested) inline html tags (PHP parser)
13566 <span><s>x</span></s>
13568 <p><span><s>x</span></s></span>
13573 Parsing of overlapping (improperly nested) inline html tags (Parsoid)
13577 <span><s>x</span></s>
13579 <p><span><s>x</s></span><s></s>
13584 ### Language variants related tests
13587 Self-link in language variants
13589 title=[[Dunav]] language=sr
13591 Both [[Dunav]] and [[Дунав]] are names for this river.
13593 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
13604 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
13606 title=[[Duna]] language=sr
13608 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
13610 <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.
13615 Link to pages in language variants
13619 Main Page can be written as [[Маин Паге]]
13621 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
13627 Multiple links to pages in language variants
13631 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
13633 <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>.
13639 Simple template in language variants
13645 <p>This is a test template
13651 Template with explicit namespace in language variants
13657 <p>This is a test template
13663 Basic test for template parameter in language variants
13667 {{парамтест|param=foo}}
13669 <p>This is a test template with parameter foo
13675 Simple category in language variants
13679 [[Category:МедиаWики Усер'с Гуиде]]
13681 <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>
13698 Don't convert blue categorylinks to another variant (bug 33210)
13702 [[A]][[Category:分类]]
13704 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
13709 Stripping -{}- tags (language variants)
13713 Latin proverb: -{Ne nuntium necare}-
13715 <p>Latin proverb: Ne nuntium necare
13721 Prevent conversion with -{}- tags (language variants)
13723 language=sr variant=sr-ec
13725 Latinski: -{Ne nuntium necare}-
13727 <p>Латински: Ne nuntium necare
13733 Prevent conversion of text with -{}- tags (language variants)
13735 language=sr variant=sr-ec
13737 Latinski: -{Ne nuntium necare}-
13739 <p>Латински: Ne nuntium necare
13745 Prevent conversion of links with -{}- tags (language variants)
13747 language=sr variant=sr-ec
13751 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
13757 -{}- tags within headlines (within html for parserConvert())
13759 language=sr variant=sr-ec
13763 <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>
13769 Explicit definition of language variant alternatives
13771 language=zh variant=zh-tw
13773 -{zh:China;zh-tw:Taiwan}-, not China
13775 <p>Taiwan, not China
13781 Conversion around HTML tags
13783 language=sr variant=sr-ec
13785 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
13786 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
13789 <span title="ЛаCтин">ски</span>
13795 Explicit session-wise language variant mapping (A flag and - flag)
13797 language=zh variant=zh-tw
13799 Taiwan is not China.
13800 But -{A|zh:China;zh-tw:Taiwan}- is China,
13801 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
13802 and -{China}- is China.
13804 <p>Taiwan is not China.
13805 But Taiwan is Taiwan,
13806 (This should be stripped!)
13807 and China is China.
13812 Explicit session-wise language variant mapping (H flag for hide)
13814 language=zh variant=zh-tw
13816 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
13819 <p>(This should be stripped!)
13825 Adding explicit conversion rule for title (T flag)
13827 language=zh variant=zh-tw showtitle
13829 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13832 <p>Should be stripped!
13837 Testing that changing the language variant here in the tests actually works
13839 language=zh variant=zh showtitle
13841 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13844 <p>Should be stripped!
13849 Recursive conversion of alt and title attrs shouldn't clear converter state
13851 language=zh variant=zh-cn showtitle
13853 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
13854 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
13858 Should be stripped<span title="Exclamation">!</span>
13863 Bug 24072: more test on conversion rule for title
13865 language=zh variant=zh-tw showtitle
13867 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13868 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
13871 <p>This should be stripped!
13872 This won't take interferes with the title rule.
13877 Partly disable title conversion if variant == main language code
13879 language=zh variant=zh title=[[ZH]] showtitle
13881 -{T|zh-cn:CN;zh-tw:TW}-
13889 Partly disable title conversion if variant == main language code, more
13891 language=zh variant=zh title=[[ZH]] showtitle
13901 Raw output of variant escape tags (R flag)
13903 language=zh variant=zh-tw
13905 Raw: -{R|zh:China;zh-tw:Taiwan}-
13907 <p>Raw: zh:China;zh-tw:Taiwan
13912 Nested using of manual convert syntax
13914 language=zh variant=zh-hk
13916 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
13918 <p>Nested: Hello Hong Kong!
13923 Proper conversion of text in external links
13925 language=sr variant=sr-ec
13927 http://www.google.com
13928 gopher://www.google.com
13929 [http://www.google.com http://www.google.com]
13930 [gopher://www.google.com gopher://www.google.com]
13931 [https://www.google.com irc://www.google.com]
13932 [ftp://www.google.com www.google.com/ftp://dir]
13933 [//www.google.com www.google.com]
13935 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
13936 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
13937 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
13938 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
13939 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
13940 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
13941 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
13946 Do not convert roman numbers to language variants
13948 language=sr variant=sr-ec
13952 <p>Фридрих IV је цар.
13957 Unclosed language converter markup "-{"
13968 Don't convert raw rule "-{R|=>}-" to "=>"
13979 Bug 529: Uncovered bullet
13989 # Plain MediaWiki does not remove empty lists, but tidy actually does.
13990 # Templates in Wikipedia rely on this behavior, as tidy has always been
13991 # enabled there. These tests are normally run *without* tidy, so specify the
13992 # full output here.
13993 # To test realistic parsing behavior, apply a tidy-like transformation to both
13994 # the expected output and your parser's output.
13996 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
13998 ******* Foo {{bullet}}
14000 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo
14013 Bug 529: Uncovered table already at line-start
14036 Bug 529: Uncovered bullet in parser function result
14038 * Foo {{lc:{{bullet}} }}
14047 Bug 5678: Double-parsed template argument
14049 {{lc:{{{1}}}|hello}}
14056 Bug 5678: Double-parsed template invocation
14058 {{lc:{{paramtest {{!}} param = hello }} }}
14060 <p>{{paramtest | param = hello }}
14065 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
14068 title=[[Main Page]]
14070 {{PRVNÍVELKÉ:ěščř}}
14071 {{prvnívelké:ěščř}}
14091 Morwen/13: Unclosed link followed by heading
14098 <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>
14103 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
14110 <h1><span class="mw-headline" id="heading">heading</span></h1>
14115 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
14122 <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>
14137 Paragraphs inside divs (no extra line breaks)
14149 Paragraphs inside divs (extra line break on open)
14164 Paragraphs inside divs (extra line break on close)
14179 Paragraphs inside divs (extra line break on open and close)
14196 Nesting tags, paragraphs on lines which begin with <div>
14200 <div></div><strong>A
14209 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
14211 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
14215 <blockquote>Line one
14217 Line two</blockquote>
14219 <blockquote>Line one
14220 Line two</blockquote>
14225 Bug 6200: paragraphs inside blockquotes (extra line break on open)
14232 Line two</blockquote>
14237 Line two</blockquote>
14242 Bug 6200: paragraphs inside blockquotes (extra line break on close)
14246 <blockquote>Line one
14251 <blockquote>Line one
14259 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
14278 Paragraphs inside blockquotes/divs (no extra line breaks)
14280 <blockquote><div>Line one
14282 Line two</div></blockquote>
14284 <blockquote><div>Line one
14285 Line two</div></blockquote>
14290 Paragraphs inside blockquotes/divs (extra line break on open)
14295 Line two</div></blockquote>
14300 Line two</div></blockquote>
14305 Paragraphs inside blockquotes/divs (extra line break on close)
14307 <blockquote><div>Line one
14310 </div></blockquote>
14312 <blockquote><div>Line one
14315 </div></blockquote>
14320 Paragraphs inside blockquotes/divs (extra line break on open and close)
14326 </div></blockquote>
14332 </div></blockquote>
14337 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
14339 wgLinkHolderBatchSize=0
14345 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
14346 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
14347 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
14352 Free external link invading image caption
14354 [[Image:Foobar.jpg|thumb|http://x|hello]]
14356 <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>
14361 Bug 15196: localised external link numbers
14365 [http://en.wikipedia.org/]
14367 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
14372 Multibyte character in padleft
14374 {{padleft:-Hello|7|Æ}}
14381 Multibyte character in padright
14383 {{padright:Hello-|7|Æ}}
14390 formatdate parser function
14392 {{#formatdate:2009-03-24}}
14394 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
14399 formatdate parser function, with default format
14401 {{#formatdate:2009-03-24|mdy}}
14403 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
14408 Spacing of numbers in formatted dates
14410 {{#formatdate:January 15}}
14412 <p><span class="mw-formatted-date" title="01-15">January 15</span>
14417 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
14419 language=nl title=[[MediaWiki:Common.css]]
14421 {{#formatdate:2009-03-24|dmy}}
14423 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
14436 Edit comment with link
14440 I like the [[Main Page]] a lot
14442 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
14446 Edit comment with link and link text
14450 I like the [[Main Page|best pages]] a lot
14452 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
14456 Edit comment with link and link text with suffix
14460 I like the [[Main Page|best page]]s a lot
14462 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
14466 Edit comment with section link (non-local, eg in history list)
14468 comment title=[[Main Page]]
14470 /* External links */ removed bogus entries
14472 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
14476 Edit comment with section link and text before it (non-local, eg in history list)
14478 comment title=[[Main Page]]
14480 pre-comment text /* External links */ removed bogus entries
14482 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>
14486 Edit comment with section link (local, eg in diff view)
14488 comment local title=[[Main Page]]
14490 /* External links */ removed bogus entries
14492 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
14496 Edit comment with subpage link (bug 14080)
14500 title=[[Subpage test]]
14502 Poked at a [[/subpage]] here...
14504 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
14508 Edit comment with subpage link and link text (bug 14080)
14512 title=[[Subpage test]]
14514 Poked at a [[/subpage|neat little page]] here...
14516 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
14520 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
14523 title=[[Subpage test]]
14525 Poked at a [[/subpage]] here...
14527 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
14531 Edit comment with bare anchor link (local, as on diff)
14535 title=[[Main Page]]
14539 <a href="#section">#section</a>
14543 Edit comment with bare anchor link (non-local, as on history)
14546 title=[[Main Page]]
14550 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
14554 Anchor starting with underscore
14558 <p><a href="#_ref">One</a>
14563 Id starting with underscore
14565 <div id="_ref"></div>
14567 <div id="_ref"></div>
14572 Space normalisation on autocomment (bug 22784)
14575 title=[[Main Page]]
14577 /* __hello__world__ */
14579 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
14583 percent-encoding and + signs in comments (Bug 26410)
14587 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
14589 <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>
14593 Bad images - basic functionality
14602 Bad images - bug 16039: text after bad image disappears
14616 Verify that displaytitle works (bug #22501) no displaytitle
14620 wgAllowDisplayTitle=true
14621 wgRestrictDisplayTitle=false
14623 this is not the the title
14626 <p>this is not the the title
14631 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
14636 wgAllowDisplayTitle=true
14637 wgRestrictDisplayTitle=false
14639 this is not the the title
14640 {{DISPLAYTITLE:whatever}}
14643 <p>this is not the the title
14648 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
14653 wgAllowDisplayTitle=true
14654 wgRestrictDisplayTitle=true
14656 this is not the the title
14657 {{DISPLAYTITLE:whatever}}
14660 <p>this is not the the title
14665 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
14670 wgAllowDisplayTitle=true
14671 wgRestrictDisplayTitle=true
14673 this is not the the title
14674 {{DISPLAYTITLE:screen}}
14677 <p>this is not the the title
14682 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
14687 wgAllowDisplayTitle=false
14689 this is not the the title
14690 {{DISPLAYTITLE:screen}}
14693 <p>this is not the the title
14694 <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>
14699 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
14704 wgAllowDisplayTitle=false
14706 this is not the the title
14709 <p>this is not the the title
14714 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
14719 wgAllowDisplayTitle=true
14720 wgRestrictDisplayTitle=true
14722 this is not the the title
14723 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
14725 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
14726 <p>this is not the the title
14731 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
14736 wgAllowDisplayTitle=true
14737 wgRestrictDisplayTitle=true
14739 this is not the the title
14740 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
14742 <span style="color: red;">s</span>creen
14743 <p>this is not the the title
14748 preload: check <noinclude> and <includeonly>
14752 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
14758 preload: check <onlyinclude>
14762 Goodbye <onlyinclude>Hello world</onlyinclude>
14768 preload: can pass tags through if we want to
14772 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
14774 <includeonly>Hello world</includeonly>
14778 preload: check that it doesn't try to do tricks
14782 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
14784 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
14788 Play a bit with r67090 and bug 3158
14792 <div style="width:50% !important"> </div>
14793 <div style="width:50% !important"> </div>
14794 <div style="width:50% !important"> </div>
14795 <div style="border : solid;"> </div>
14797 <div style="width:50% !important"> </div>
14798 <div style="width:50% !important"> </div>
14799 <div style="width:50% !important"> </div>
14800 <div style="border : solid;"> </div>
14805 HTML5 data attributes
14807 <span data-foo="bar">Baz</span>
14808 <p data-abc-def_hij="">Quuz</p>
14810 <p><span data-foo="bar">Baz</span>
14812 <p data-abc-def_hij="">Quuz</p>
14817 percent-encoding and + signs in internal links (Bug 26410)
14819 [[User:+%]] [[Page+title%]]
14820 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
14821 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
14822 [[%33%45]] [[%33%45+]]
14824 <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>
14825 <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>
14826 <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>
14827 <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>
14832 Special characters in embedded file links (bug 27679)
14834 [[File:Contains & ampersand.jpg]]
14835 [[File:Does not exist.jpg|Title with & ampersand]]
14837 <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>
14838 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
14844 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
14846 Text's been normalized?
14848 <p>Text's been normalized?
14853 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
14855 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
14857 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
14862 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
14864 [http://www.example.org/ ideograms]
14866 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
14871 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
14873 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
14875 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
14899 Bug 31098 Template which includes system messages which includes the template
14903 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
14904 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
14909 Bug31490 Turkish: ucfirst 'blah'
14920 Bug31490 Turkish: ucfirst 'ix'
14931 Bug31490 Turkish: lcfirst 'BLAH'
14942 Bug31490 Turkish: ucfırst (with a dotless i)
14948 <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>
14953 Bug31490 ucfırst (with a dotless i) with English language
14959 <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>
14964 Bug 26375: TOC with italics
14966 title=[[Main Page]]
14969 == ''Lost'' episodes ==
14971 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14973 <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>
14976 <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>
14981 Bug 26375: TOC with bold
14983 title=[[Main Page]]
14986 == '''should be bold''' then normal text ==
14988 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14990 <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>
14993 <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>
14998 Bug 33845: Headings become cursive in TOC when they contain an image
15000 title=[[Main Page]]
15003 == Image [[Image:foobar.jpg]] ==
15005 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15007 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
15010 <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>
15015 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
15017 title=[[Main Page]]
15020 == <blockquote>Quote</blockquote> ==
15022 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15024 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
15027 <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>
15032 Unclosed tags in TOC
15034 title=[[Main Page]]
15038 <small>Hanc marginis exiguitas non caperet.</small>
15041 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15043 <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>
15046 <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>
15047 <p><small>Hanc marginis exiguitas non caperet.</small>
15053 Multiple tags in TOC
15056 == <i>Foo</i> <b>Bar</b> ==
15058 == <i>Foo</i> <blockquote>Bar</blockquote> ==
15060 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15062 <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>
15063 <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>
15066 <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>
15067 <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>
15072 Tags with parameters in TOC
15075 == <sup class="in-h2">Hello</sup> ==
15077 == <sup class="a > b">Evilbye</sup> ==
15079 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15081 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
15082 <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>
15085 <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>
15086 <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>
15091 span tags with directionality in TOC
15094 == <span dir="ltr">C++</span> ==
15096 == <span dir="rtl">זבנג!</span> ==
15098 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
15100 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
15102 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
15104 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15106 <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>
15107 <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>
15108 <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>
15109 <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>
15110 <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>
15113 <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>
15114 <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>
15115 <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>
15116 <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>
15117 <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>
15124 == {{int:headline_sample}} ==
15128 Bug 32057: Title needed when expanding <h> nodes.
15130 title=[[Main Page]]
15134 <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>
15139 Strip marker in urlencode
15141 {{urlencode:x<nowiki/>y}}
15142 {{urlencode:x<nowiki/>y|wiki}}
15143 {{urlencode:x<nowiki/>y|path}}
15170 Strip marker in formatNum
15172 {{formatnum:1<nowiki/>2}}
15173 {{formatnum:1<nowiki/>2|R}}
15181 Check noCommafy in formatNum
15185 {{formatnum:123456.78}}
15186 {{formatnum:123456.78|NOSEP}}
15194 Strip marker in grammar
15198 {{grammar:elative|foo<nowiki/>bar}}
15205 Strip marker in padleft
15207 {{padleft:|2|x<nowiki/>y}}
15214 Strip marker in padright
15216 {{padright:|2|x<nowiki/>y}}
15223 Strip marker in anchorencode
15225 {{anchorencode:x<nowiki/>y}}
15232 nowiki inside link inside heading (bug 18295)
15234 ==[[foo|x<nowiki>y</nowiki>z]]==
15236 <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>
15241 new support for bdi element (bug 31817)
15243 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
15245 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
15250 Ignore pipe between table row attributes
15254 |- id=foo | style='color: red'
15262 <tr id="foo" style="color: red">
15269 Gallery override link with WikiLink (bug 34852)
15272 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
15275 <ul class="gallery mw-gallery-traditional">
15276 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15277 <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>
15278 <div class="gallerytext">
15288 Gallery override link with absolute external link (bug 34852)
15291 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
15294 <ul class="gallery mw-gallery-traditional">
15295 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15296 <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>
15297 <div class="gallerytext">
15307 Gallery override link with malicious javascript (bug 34852)
15310 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
15313 <ul class="gallery mw-gallery-traditional">
15314 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15315 <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>
15316 <div class="gallerytext">
15326 Gallery with invalid title as link (bug 43964)
15329 File:foobar.jpg|link=<
15332 <ul class="gallery mw-gallery-traditional">
15333 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15334 <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>
15335 <div class="gallerytext">
15343 Language parser function
15352 Padleft and padright as substr
15354 {{padleft:|3|abcde}}
15355 {{padright:|3|abcde}}
15363 Special parser function
15365 {{#special:RandomPage}}
15366 {{#special:BaDtItLe}}
15367 {{#special:Foobar}}
15376 Bug 34939 - Case insensitive link parsing ([HttP://])
15378 [HttP://MediaWiki.Org/]
15380 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
15385 Bug 34939 - Case insensitive link parsing ([HttP:// title])
15387 [HttP://MediaWiki.Org/ MediaWiki]
15389 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
15394 Bug 34939 - Case insensitive link parsing (HttP://)
15396 HttP://MediaWiki.Org/
15398 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
15404 ### Parsoids-specific tests
15405 ### Parsoid-PHP parser incompatibilities
15408 1. SOL-sensitive wikitext tokens as template-args
15410 parsoid=wt2html,wt2wt
15416 <span about="#mwt1" typeof="mw:Transclusion">
15417 </span><ul about="#mwt1"><li>a</li></ul>
15418 <span about="#mwt2" typeof="mw:Transclusion">
15419 </span><ol about="#mwt2"><li>a</li></ol>
15420 <span about="#mwt3" typeof="mw:Transclusion">
15421 </span><dl about="#mwt3"><dd>a</dd></dl>
15424 #### ----------------------------------------------------------------
15425 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
15426 #### tags. Parsoid's output for these tags differs from that of the
15428 #### ----------------------------------------------------------------
15431 Ref: 1. ref-location should be replaced with an index span
15436 B <ref name="x">foo</ref>
15439 <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>
15440 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>
15441 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>
15445 Ref: 2. ref-tags with identical names should all get the same index
15449 A <ref name="x">foo</ref>
15452 <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>
15453 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>
15457 Ref: 3. spaces in ref-names should be ignored
15461 A <ref name="x">foo</ref>
15462 B <ref name=" x " />
15465 <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>
15466 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>
15467 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>
15471 Ref: 4. 'constructor' should be accepted as a valid ref-name
15472 (NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
15476 A <ref name="constructor">foo</ref>
15478 <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>
15482 Ref: 5. body should accept generic wikitext
15487 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
15492 <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>
15494 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15495 <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>
15500 Ref: 6. indent-pres should not be output in ref-body
15512 <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>
15514 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15515 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
15522 Ref: 6. No p-wrapping in ref-body
15541 <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>
15543 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15544 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
15558 Ref: 8. transclusion wikitext has lower precedence
15562 A <ref> foo {{echo|</ref> B C}}
15566 <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>
15568 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15569 <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>
15573 Ref: 9. unclosed comments should not leak out of ref-body
15577 A <ref> foo <!--</ref> B C
15581 <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>
15583 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15584 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <!----></li></ol>
15588 Ref: 10. Unclosed HTML tags should not leak out of ref-body
15592 A <ref> <b> foo </ref> B C
15596 <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>
15598 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15599 <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>
15603 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
15610 <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
15611 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>
15615 Ref: 12. ref-tags act as trailing newline migration barrier
15619 <!--the newline at the end of this line moves out of the p-tag-->a
15621 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
15626 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
15629 <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>
15630 <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>
15637 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
15645 <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
15646 <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>
15650 Ref: 14. A nested ref-tag should be emitted as plain text
15654 <ref>foo <ref>bar</ref> baz</ref>
15658 <p><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></p>
15660 <ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw="{"name":"references","attrs":{}}">
15661 <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>
15665 Ref: 15. ref-tags with identical names should get identical indexes
15669 A1 <ref name="a">foo</ref> A2 <ref name="a" />
15670 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
15674 <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>
15675 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>
15677 <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>
15681 References: 1. references tag without any refs should be handled properly
15687 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"></ol>
15691 References: 2. references tag with group only outputs references from that group
15695 A <ref group="a">foo</ref>
15696 B <ref group="b">bar</ref>
15698 <references group='a' />
15700 <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>
15701 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>
15703 <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>
15707 References: 3. ref list should be cleared after processing references
15719 <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>
15721 <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>
15723 <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>
15725 <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>
15729 References: 4. only referenced group should be cleared after processing references
15733 A <ref group="a">afoo</ref>
15736 <references group="a"/>
15742 <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>
15743 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>
15745 <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>
15747 <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>
15749 <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>
15753 References: 5. ref tags in references should be processed while ignoring all other content
15758 B <ref name="b">bar</ref>
15761 <ref name="a">foo</ref>
15762 This should just get lost.
15765 <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>
15766 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>
15768 <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>
15772 References: 6. <references /> from a transclusion
15776 {{echo|<references />}}
15778 <ol class="references" about="#mwt2" typeof="mw:Transclusion" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references />"}},"i":0}'></ol>
15782 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
15786 A <ref>foo bar for a</ref>
15792 <ref name="b">foo</ref>
15795 <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>
15796 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>
15798 <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>
15800 <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>
15804 #### ----------------------------------------------------------------
15805 #### The following section of tests are primarily to test
15806 #### wikitext escaping capabilities of Parsoid. Given that
15807 #### escaping can be done any number of ways, the wikitext (input)
15808 #### is always adjusted to reflect how Parsoid adds nowiki
15811 #### We are marking several tests as parsoid-only since the
15812 #### HTML in the result section is different from what the
15813 #### PHP parser generates for it.
15814 #### ----------------------------------------------------------------
15817 #### --------------- Headings ---------------
15819 #### 1. Nested inside html <h1>=foo=</h1>
15820 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
15821 #### 3. Nested inside html with wikitext split by html tags
15822 #### 4. No escape needed
15823 #### 5. Empty headings <h1></h1>
15824 #### 6. Heading chars in SOL context
15825 #### ----------------------------------------
15827 Headings: 0. Unnested
15831 <nowiki>=foo=</nowiki>
15833 <nowiki> =foo= </nowiki>
15835 <nowiki>=foo=</nowiki>
15837 =foo''a''<nowiki>=</nowiki>
15839 <p><span typeof="mw:Nowiki">=foo=</span></p>
15841 <p><span typeof="mw:Nowiki"> =foo= </span>
15843 <span typeof="mw:Nowiki">=foo=</span></p>
15845 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
15849 Headings: 1. Nested inside html
15853 =<nowiki>=foo=</nowiki>=
15855 ==<nowiki>=foo=</nowiki>==
15857 ===<nowiki>=foo=</nowiki>===
15859 ====<nowiki>=foo=</nowiki>====
15861 =====<nowiki>=foo=</nowiki>=====
15863 ======<nowiki>=foo=</nowiki>======
15865 <h1><span typeof="mw:Nowiki">=foo=</span></h1>
15866 <h2><span typeof="mw:Nowiki">=foo=</span></h2>
15867 <h3><span typeof="mw:Nowiki">=foo=</span></h3>
15868 <h4><span typeof="mw:Nowiki">=foo=</span></h4>
15869 <h5><span typeof="mw:Nowiki">=foo=</span></h5>
15870 <h6><span typeof="mw:Nowiki">=foo=</span></h6>
15874 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
15879 <nowiki>*</nowiki>bar
15885 <nowiki>=bar=</nowiki>
15893 Headings: 3. Nested inside html with wikitext split by html tags
15897 =='''bold'''<nowiki>foo=</nowiki>=
15899 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
15903 Headings: 4a. No escaping needed (testing just h1 and h2)
15921 =<nowiki>=</nowiki>=
15929 <h1><i>=</i>foo=</h1>
15930 <h1><span typeof="mw:Nowiki">=</span></h1>
15934 Headings: 4b. No escaping needed (inside p-tags)
15949 Headings: 5. Empty headings
15961 =====<nowiki/>=====
15963 ======<nowiki/>======
15974 Headings: 6a. Heading chars in SOL context (with trailing spaces)
15978 <nowiki>=a=</nowiki>
15980 <nowiki>=a=</nowiki>
15982 <nowiki>=a=</nowiki>
15984 <nowiki>=a=</nowiki>
15993 Headings: 6b. Heading chars in SOL context (with trailing newlines)
16021 Headings: 6c. Heading chars in SOL context (leading newline break)
16026 <nowiki>=b=</nowiki>
16033 Headings: 6d. Heading chars in SOL context (with interspersed comments)
16037 <!--c0--><nowiki>=a=</nowiki>
16039 <nowiki>=a=</nowiki> <!--c2--> <!--c3-->
16041 <p><!--c0-->=a=</p>
16042 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
16046 Headings: 6d. Heading chars in SOL context (No escaping needed)
16055 #### --------------- Lists ---------------
16056 #### 0. Outside nests (*foo, etc.)
16057 #### 1. Nested inside html <ul><li>*foo</li></ul>
16058 #### 2. Inside definition lists
16059 #### 3. Only bullets at start should be escaped
16060 #### 4. No escapes needed
16061 #### 5. No unnecessary escapes
16062 #### 6. Escape bullets in SOL position
16063 #### 7. Escape bullets in a multi-line context
16064 #### ----------------------------------------
16067 Lists: 0. Outside nests
16069 <nowiki>*</nowiki>foo
16071 <nowiki>#</nowiki>foo
16079 Lists: 1. Nested inside html
16081 *<nowiki>*foo</nowiki>
16083 *<nowiki>#foo</nowiki>
16085 *<nowiki>:foo</nowiki>
16087 *<nowiki>;foo</nowiki>
16089 #<nowiki>*foo</nowiki>
16091 #<nowiki>#foo</nowiki>
16093 #<nowiki>:foo</nowiki>
16095 #<nowiki>;foo</nowiki>
16117 Lists: 2. Inside definition lists
16119 ;<nowiki>;foo</nowiki>
16121 ;<nowiki>:foo</nowiki>
16123 ;<nowiki>:foo</nowiki>
16126 :<nowiki>:foo</nowiki>
16141 Lists: 3. Only bullets at start of text should be escaped
16143 *<nowiki>*foo*bar</nowiki>
16145 *<nowiki>*foo</nowiki>''it''*bar
16149 <ul><li>*foo<i>it</i>*bar
16155 Lists: 4. No escapes needed
16167 <ul><li><i>foo</i>*bar
16169 <ul><li><a rel="mw:WikiLink" href="Foo">Foo</a>: bar
16174 Lists: 5. No unnecessary escapes
16176 * bar <span><nowiki>[[foo]]</nowiki></span>
16178 *=bar <span><nowiki>[[foo]]</nowiki></span>
16180 *[[bar <span><nowiki>[[foo]]</nowiki></span>
16182 *]]bar <span><nowiki>[[foo]]</nowiki></span>
16184 *=bar <span>foo]]</span>=
16188 <ul><li> bar <span>[[foo]]</span>
16190 <ul><li>=bar <span>[[foo]]</span>
16192 <ul><li>[[bar <span>[[foo]]</span>
16194 <ul><li>]]bar <span>[[foo]]</span>
16196 <ul><li>=bar <span>foo]]</span>=
16198 <ul><li> <s></s>: a
16204 Lists: 6. Escape bullets in SOL position
16208 <!--cmt--><nowiki>*foo</nowiki>
16210 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
16214 Lists: 7. Escape bullets in a multi-line context
16217 <nowiki>*</nowiki>b
16224 #### --------------- HRs ---------------
16225 #### 1. Single line
16226 #### -----------------------------------
16229 HRs: 1. Single line
16233 ----<nowiki>----</nowiki>
16237 <hr><span typeof="mw:Nowiki">----</span>
16242 #### --------------- Tables ---------------
16243 #### 1a. Simple example
16244 #### 1b. No escaping needed (!foo)
16245 #### 1c. No escaping needed (|foo)
16246 #### 1d. No escaping needed (|}foo)
16248 #### 2a. Nested in td (<td>foo|bar</td>)
16249 #### 2b. Nested in td (<td>foo||bar</td>)
16250 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
16252 #### 3a. Nested in th (<th>foo!bar</th>)
16253 #### 3b. Nested in th (<th>foo!!bar</th>)
16254 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
16258 #### 4c. No escaping needed
16259 #### --------------------------------------
16262 Tables: 1a. Simple example
16273 Tables: 1b. No escaping needed
16282 Tables: 1c. No escaping needed
16291 Tables: 1d. No escaping needed
16300 Tables: 2a. Nested in td
16305 |<nowiki>foo|bar</nowiki>
16309 <td><span typeof="mw:Nowiki">foo|bar</span></td></tr></tbody></table>
16313 Tables: 2b. Nested in td
16318 |<nowiki>foo||bar</nowiki>
16319 |''it''<nowiki>foo||bar</nowiki>
16323 <td><span typeof="mw:Nowiki">foo||bar</span></td>
16324 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
16328 Tables: 2c. Nested in td -- no escaping needed
16336 <table><tbody><tr><td>foo!!bar
16337 </td></tr></tbody></table>
16342 Tables: 3a. Nested in th
16350 <table><tbody><tr><th>foo!bar
16351 </th></tr></tbody></table>
16356 Tables: 3b. Nested in th
16361 !<nowiki>foo!!bar</nowiki>
16365 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
16370 Tables: 3c. Nested in th -- no escaping needed
16375 !<nowiki>foo||bar</nowiki>
16379 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
16383 Tables: 4a. Escape -
16391 |<nowiki>-bar</nowiki>
16395 <tr><th>-bar</th></tr>
16397 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
16401 Tables: 4b. Escape +
16409 |<nowiki>+bar</nowiki>
16413 <tr><th>+bar</th></tr>
16415 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
16419 Tables: 4c. No escaping needed
16438 <tr><td>foo-bar</td><td>foo+bar</td></tr>
16439 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
16447 ### SSS FIXME: Disabled right now because accurate html2wt
16448 ### on this snippet requires data-parsoid flags that we've
16449 ### stripped out of these tests. We should scheme how we
16450 ### we want to handle these kind of tests that require
16451 ### data-parsoid flags for accurate html2wt serialization
16454 Tables: 4d. No escaping needed
16472 #### --------------- Links ----------------
16473 #### 1. Quote marks in link text
16474 #### 2. Wikilinks: Escapes needed
16475 #### 3. Wikilinks: No escapes needed
16476 #### 4. Extlinks: Escapes needed
16477 #### 5. Extlinks: No escapes needed
16478 #### --------------------------------------
16480 Links 1. Quote marks in link text
16484 [[Foo|Foo<nowiki>''boo''</nowiki>]]
16486 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
16490 Links 2. WikiLinks: Escapes needed
16494 [[Foo|<nowiki>[Foobar]</nowiki>]]
16495 [[Foo|<nowiki>Foobar]</nowiki>]]
16496 [[Foo|x [Foobar] x]]
16497 [[Foo|<nowiki>x [http://google.com g] x</nowiki>]]
16498 [[Foo|<nowiki>[[Bar]]</nowiki>]]
16499 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
16500 [[Foo|<nowiki>|Bar</nowiki>]]
16501 [[Foo|<nowiki>]]bar</nowiki>]]
16502 [[Foo|<nowiki>[[bar</nowiki>]]
16503 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
16505 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
16506 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
16507 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
16508 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
16509 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
16510 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
16511 <a href="Foo" rel="mw:WikiLink">|Bar</a>
16512 <a href="Foo" rel="mw:WikiLink">]]bar</a>
16513 <a href="Foo" rel="mw:WikiLink">[[bar</a>
16514 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
16518 Links 3. WikiLinks: No escapes needed
16525 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
16526 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
16530 Links 4. ExtLinks: Escapes needed
16534 [http://google.com <nowiki>[google]</nowiki>]
16535 [http://google.com <nowiki>google]</nowiki>]
16537 <a href="http://google.com" rel="mw:ExtLink">[google]</a>
16538 <a href="http://google.com" rel="mw:ExtLink">google]</a>
16542 Links 5. ExtLinks: No escapes needed
16546 [http://google.com [google]
16548 <a href="http://google.com" rel="mw:ExtLink">[google</a>
16551 #### --------------- Quotes ---------------
16552 #### 1. Quotes inside <b> and <i>
16553 #### 2. Link fragments separated by <i> and <b> tags
16554 #### 3. Link fragments inside <i> and <b>
16555 #### 4. No escaping needed
16556 #### --------------------------------------
16558 1. Quotes inside <b> and <i>
16560 parsoid=html2wt,wt2wt
16562 ''<nowiki>'foo'</nowiki>''
16563 ''<nowiki>''foo''</nowiki>''
16564 ''<nowiki>'''foo'''</nowiki>''
16566 '''<nowiki>'foo'</nowiki>'''
16567 '''<nowiki>''foo''</nowiki>'''
16568 '''<nowiki>'''foo'''</nowiki>'''
16569 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
16570 '''foo'''<nowiki/>'s
16573 '<nowiki/>''foo''<nowiki/>'
16575 '''foo'''<nowiki/>'
16576 '<nowiki/>'''foo'''<nowiki/>'
16585 <b>foo'<i>bar'</i>baz</b>
16596 2. Link fragments separated by <i> and <b> tags
16598 [[''foo''<nowiki>hello]]</nowiki>
16600 [['''foo'''<nowiki>hello]]</nowiki>
16602 <p>[[<i>foo</i>hello]]
16603 </p><p>[[<b>foo</b>hello]]
16608 3. Link fragments inside <i> and <b>
16609 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
16610 this is one of the shortcomings of this format)
16612 ''[[foo''<nowiki>]]</nowiki>
16614 '''[[foo'''<nowiki>]]</nowiki>
16617 </p><p><b>[[foo</b>]]
16622 4. No escaping needed
16624 '<span>''bar''</span>'
16625 '<span>'''bar'''</span>'
16627 <p>'<span><i>bar</i></span>'
16628 '<span><b>bar</b></span>'
16632 #### ----------- Paragraphs ---------------
16633 #### 1. No unnecessary escapes
16634 #### --------------------------------------
16637 1. No unnecessary escapes
16639 bar <span><nowiki>[[foo]]</nowiki></span>
16641 =bar <span><nowiki>[[foo]]</nowiki></span>
16643 [[bar <span><nowiki>[[foo]]</nowiki></span>
16645 ]]bar <span><nowiki>[[foo]]</nowiki></span>
16647 =bar <span>foo]]</span><nowiki>=</nowiki>
16649 <p>bar <span>[[foo]]</span>
16650 </p><p>=bar <span>[[foo]]</span>
16651 </p><p>[[bar <span>[[foo]]</span>
16652 </p><p>]]bar <span>[[foo]]</span>
16653 </p><p>=bar <span>foo]]</span>=
16657 #### ----------------------- PRE --------------------------
16658 #### 1. Leading whitespace in SOL context should be escaped
16659 #### ------------------------------------------------------
16661 1. Leading whitespace in SOL context should be escaped
16665 <nowiki> </nowiki>a
16667 <nowiki> </nowiki> a
16669 <nowiki> </nowiki>a(tab)
16671 <nowiki> </nowiki> a
16673 <nowiki> </nowiki> a
16676 <nowiki> </nowiki>b
16679 <nowiki> </nowiki>b
16682 <nowiki> </nowiki> b
16688 <p><!--cmt--> a</p>
16697 #### --------------- HTML tags ---------------
16700 #### 3. multi-line html tag
16701 #### -----------------------------------------
16707 <a href="http://google.com">google</a>
16709 <a href="http://google.com">google</a>
16715 <nowiki><div>foo</div>
16716 <div style="color:red">foo</div></nowiki>
16718 <p><div>foo</div>
16719 <div style="color:red">foo</div>
16724 3. multi-line html tag
16739 <nowiki><ref>foo</ref></nowiki>
16741 <p><ref>foo</ref>
16745 #### --------------- Others ---------------
16749 <nowiki>foo</nowiki>
16751 <p><nowiki>foo</nowiki>
16755 ## The quote-char in the input is necessary for triggering the bug
16757 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
16759 parsoid=wt2wt,html2wt
16768 Tag-like HTML structures are passed through as text
16790 </p><p>1<d e>f
16795 # This was a bug in the PHP parser (see bug 17663 and its dups,
16796 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
16798 Tag names followed by punctuation should not be recognized as tags
16802 <p><s.ome> text
16807 HTML tag with necessary entities in attributes
16809 <span title="&amp;">foo</span>
16811 <p><span title="&amp;">foo</span>
16816 HTML tag with 'unnecessary' entity encoding in attributes
16818 <span title="&">foo</span>
16820 <p><span title="&">foo</span>
16825 HTML tag with broken attribute value quoting
16827 <span title="Hello world>Foo</span>
16829 <p><span>Foo</span>
16834 Parsoid-only: HTML tag with broken attribute value quoting
16838 <span title="Hello world>Foo</span>
16840 <p><span title="Hello world">Foo</span>
16845 Table with broken attribute value quoting
16848 | title="Hello world|Foo
16859 Table with broken attribute value quoting on consecutive lines
16862 | title="Hello world|Foo
16863 | style="color:red|Bar
16876 Parsoid-only: Table with broken attribute value quoting on consecutive lines
16881 | title="Hello world|Foo
16882 | style="color:red|Bar
16887 <td title="Hello world">Foo
16888 </td><td style="color: red">Bar
16889 </td></tr></tbody></table>
16894 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
16904 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
16914 Accept empty td cell attribute
16917 | align="center" | foo || |
16922 <td align="center"> foo </td>
16929 Non-empty attributes in th-cells
16932 ! Foo !! style="color: red" | Bar
16938 <th style="color: red"> Bar
16944 Accept empty attributes in th-cells
16959 Empty table rows go away
16980 ### Parsoid-centric tests for testing RTing of inter-element separators
16981 ### Edge cases not tested by existing parser tests and specific to
16982 ### Parsoid-specific serialization strategies.
16986 RT-ed inter-element separators should be valid separators
16999 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
17000 (Parsoid-only since PHP parser relies on Tidy for correct output)
17016 Empty TD followed by TD with tpl-generated attribute
17021 |{{echo|style='color:red'}}|foo
17035 Indented table with an empty td
17054 Empty TR followed by a template-generated TR
17055 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
17057 parsoid=wt2html,wt2wt
17061 {{echo|<tr><td>foo</td></tr>}}
17067 <tr typeof="mw:Transclusion">
17068 <td>foo</td></tr></tbody></table>
17071 ## PHP and parsoid output differ for this, and since this is primarily
17072 ## for testing Parsoid's serializer, marking this Parsoid only
17074 Empty TR followed by mixed-ws-comment line should RT correctly
17088 <td> <!--c--></td></tr>
17090 <td><!--c--> <!--d--></td></tr>
17096 Multi-line image caption generated by templates with/without trailing newlines
17100 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
17101 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
17103 <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>
17104 <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>
17108 ## PHP emits broken html for this, and since this is primarily
17109 ## a Parsoid serializer test, marking this Parsoid only
17111 Improperly nested inline or quotes tags with whitespace in between
17115 <span> <s>x</span> </s>
17118 <p><span> <s>x</s></span><s> </s>
17119 <b> <i>x</i></b><i> </i>
17124 Encapsulate protected attributes from wt
17128 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
17130 <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>
17134 # -----------------------------------------------------------------
17135 # The following section of tests are primarily to spec requirements
17136 # around serialization of new/edited content.
17138 # All these tests are marked Parsoid html2wt and html2html only
17139 # ----------------------------------------------------------------
17142 Image: Modifying size of an image
17146 [[Image:Wiki.png|230x230px]]
17148 <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>
17152 Image: New block level image should have \n before and after
17157 [[File:Wiki.png|right|thumb|150x150px]]
17160 <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>
17163 # Wacky -- the leading newline in input is required because
17164 # that is what the serializer emits. To be fixed. Not fixing
17165 # the test because this test is required to test serialization of
17166 # new content and preferred whitespace style.
17168 Lists: Add space after bullets
17175 * <span> baz</span>
17180 <li><span> baz</span></li>
17185 Parsoid: Serialize positional parameters with = in them as named parameter
17191 <p about="#mwt1" typeof="mw:Transclusion"
17192 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}'
17196 # -----------------------------------------------------------------
17197 # End of section for Parsoid-only html2wt tests for serialization
17199 # -----------------------------------------------------------------
17206 Try for 100% code coverage