1<?xml version="1.0" encoding="utf-8" ?>
2<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Publishing DTD v1.0 20120330//EN"
3 "JATS-journalpublishing1.dtd">
4<article xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink" dtd-version="1.0" article-type="other">
10<publisher-name></publisher-name>
15<article-title>Pandoc Test Suite</article-title>
18<contrib contrib-type="author">
20<string-name>John MacFarlane</string-name>
23<contrib contrib-type="author">
25<string-name>Anonymous</string-name>
29<pub-date pub-type="epub">
30<string-date>July 17, 2006</string-date>
35<p>This is a set of tests for pandoc. Most of them are adapted from John
36Gruber’s markdown test suite.</p>
38 <title>Headers</title>
39 <sec id="level-2-with-an-embedded-link">
40 <title>Level 2 with an
41 <ext-link ext-link-type="uri" xlink:href="/url">embedded
42 link</ext-link></title>
43 <sec id="level-3-with-emphasis">
44 <title>Level 3 with <italic>emphasis</italic></title>
46 <title>Level 4</title>
48 <title>Level 5</title>
55 <title>Level 1</title>
56 <sec id="level-2-with-emphasis">
57 <title>Level 2 with <italic>emphasis</italic></title>
59 <title>Level 3</title>
60 <p>with no blank line</p>
64 <title>Level 2</title>
65 <p>with no blank line</p>
69 <title>Paragraphs</title>
70 <p>Here’s a regular paragraph.</p>
71 <p>In Markdown 1.0.0 and earlier. Version 8. This line turns into a list
72 item. Because a hard-wrapped line in the middle of a paragraph looked like a
74 <p>Here’s one with a bullet. * criminey.</p>
75 <p>There should be a hard line break<break />here.</p>
77<sec id="block-quotes">
78 <title>Block Quotes</title>
81 <p>This is a block quote. It is pretty short.</p>
84 <p>Code in a block quote:</p>
85 <preformat>sub status {
86 print "working";
89 <list list-type="order">
97 <p>Nested block quotes:</p>
105 <p>This should not be a block quote: 2 > 1.</p>
106 <p>And a following paragraph.</p>
108<sec id="code-blocks">
109 <title>Code Blocks</title>
111 <preformat>---- (should be four hyphens)
114 print "working";
117this code block is indented by one tab</preformat>
119 <preformat> this code block is indented by two tabs
121These should not be escaped: \$ \\ \> \[ \{</preformat>
126 <title>Unordered</title>
127 <p>Asterisks tight:</p>
128 <list list-type="bullet">
139 <p>Asterisks loose:</p>
140 <list list-type="bullet">
152 <list list-type="bullet">
164 <list list-type="bullet">
175 <p>Minuses tight:</p>
176 <list list-type="bullet">
187 <p>Minuses loose:</p>
188 <list list-type="bullet">
201 <title>Ordered</title>
203 <list list-type="order">
215 <list list-type="order">
226 <p>Loose using tabs:</p>
227 <list list-type="order">
238 <p>and using spaces:</p>
239 <list list-type="order">
250 <p>Multiple paragraphs:</p>
251 <list list-type="order">
253 <p>Item 1, graf one.</p>
254 <p>Item 1. graf two. The quick brown fox jumped over the lazy dog’s
266 <title>Nested</title>
267 <list list-type="bullet">
270 <list list-type="bullet">
273 <list list-type="bullet">
282 <p>Here’s another:</p>
283 <list list-type="order">
289 <list list-type="bullet">
305 <p>Same thing but with paragraphs:</p>
306 <list list-type="order">
312 <list list-type="bullet">
329 <sec id="tabs-and-spaces">
330 <title>Tabs and spaces</title>
331 <list list-type="bullet">
333 <p>this is a list item indented with tabs</p>
336 <p>this is a list item indented with spaces</p>
337 <list list-type="bullet">
339 <p>this is an example list item indented with tabs</p>
342 <p>this is an example list item indented with spaces</p>
348 <sec id="fancy-list-markers">
349 <title>Fancy list markers</title>
350 <list list-type="order">
358 <p>with a continuation</p>
359 <list list-type="roman-lower">
362 <p>sublist with roman numerals, starting with 4</p>
367 <list list-type="alpha-upper">
382 <list list-type="alpha-upper">
385 <list list-type="roman-upper">
388 <list list-type="order">
391 <p>Decimal start with 6</p>
392 <list list-type="alpha-lower">
395 <p>Lower alpha with paren</p>
404 <p>Autonumbering:</p>
405 <list list-type="order">
411 <list list-type="order">
418 <p>Should not be a list item:</p>
423<sec id="definition-lists">
424 <title>Definition Lists</title>
425 <p>Tight using spaces:</p>
446 <p>Tight using tabs:</p>
488 <p>Multiple blocks with italics:</p>
491 <term><italic>apple</italic></term>
494 <p>contains seeds, crisp, pleasant to taste</p>
498 <term><italic>orange</italic></term>
501 <preformat>{ orange code block }</preformat>
503 <p>orange block quote</p>
508 <p>Multiple definitions, tight:</p>
525 <p>Multiple definitions, loose:</p>
542 <p>Blank line after term, indented marker, alternate markers:</p>
555 <list list-type="order">
567<sec id="html-blocks">
568 <title>HTML Blocks</title>
569 <p>Simple block on one line:</p>
573 <p>And nested without indentation:</p>
584 <p>Interpreted markdown in a table:</p>
585 <p>This is <italic>emphasized</italic></p>
586 <p>And this is <bold>strong</bold></p>
587 <p>Here’s a simple block:</p>
591 <p>This should be a code block, though:</p>
592 <preformat><div>
594</div></preformat>
595 <p>As should this:</p>
596 <preformat><div>foo</div></preformat>
605 <p>This should just be an HTML comment:</p>
608 <preformat><!-- Comment --></preformat>
609 <p>Just plain comment, with trailing spaces on the line:</p>
611 <preformat><hr /></preformat>
614<sec id="inline-markup">
615 <title>Inline Markup</title>
616 <p>This is <italic>emphasized</italic>, and so <italic>is this</italic>.</p>
617 <p>This is <bold>strong</bold>, and so <bold>is this</bold>.</p>
618 <p>An <italic><ext-link ext-link-type="uri" xlink:href="/url">emphasized
619 link</ext-link></italic>.</p>
620 <p><bold><italic>This is strong and em.</italic></bold></p>
621 <p>So is <bold><italic>this</italic></bold> word.</p>
622 <p><bold><italic>This is strong and em.</italic></bold></p>
623 <p>So is <bold><italic>this</italic></bold> word.</p>
624 <p>This is code: <monospace>></monospace>, <monospace>$</monospace>,
625 <monospace>\</monospace>, <monospace>\$</monospace>,
626 <monospace><html></monospace>.</p>
627 <p><strike>This is <italic>strikeout</italic>.</strike></p>
628 <p>Superscripts: a<sup>bc</sup>d a<sup><italic>hello</italic></sup>
629 a<sup>hello there</sup>.</p>
630 <p>Subscripts: H<sub>2</sub>O, H<sub>23</sub>O,
631 H<sub>many of them</sub>O.</p>
632 <p>These should not be superscripts or subscripts, because of the unescaped
633 spaces: a^b c^d, a~b c~d.</p>
635<sec id="smart-quotes-ellipses-dashes">
636 <title>Smart quotes, ellipses, dashes</title>
637 <p>“Hello,” said the spider. “‘Shelob’ is my name.”</p>
638 <p>‘A’, ‘B’, and ‘C’ are letters.</p>
639 <p>‘Oak,’ ‘elm,’ and ‘beech’ are names of trees. So is ‘pine.’</p>
640 <p>‘He said, “I want to go.”’ Were you alive in the 70’s?</p>
641 <p>Here is some quoted ‘<monospace>code</monospace>’ and a
642 “<ext-link ext-link-type="uri" xlink:href="http://example.com/?foo=1&bar=2">quoted
643 link</ext-link>”.</p>
644 <p>Some dashes: one—two — three—four — five.</p>
645 <p>Dashes between numbers: 5–7, 255–66, 1987–1999.</p>
646 <p>Ellipses…and…and….</p>
650 <list list-type="bullet">
655 <p><inline-formula><alternatives>
656 <tex-math><![CDATA[2+2=4]]></tex-math>
657 <mml:math display="inline" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow><mml:mn>2</mml:mn><mml:mo>+</mml:mo><mml:mn>2</mml:mn><mml:mo>=</mml:mo><mml:mn>4</mml:mn></mml:mrow></mml:math></alternatives></inline-formula></p>
660 <p><inline-formula><alternatives>
661 <tex-math><![CDATA[x \in y]]></tex-math>
662 <mml:math display="inline" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow><mml:mi>x</mml:mi><mml:mo>∈</mml:mo><mml:mi>y</mml:mi></mml:mrow></mml:math></alternatives></inline-formula></p>
665 <p><inline-formula><alternatives>
666 <tex-math><![CDATA[\alpha \wedge \omega]]></tex-math>
667 <mml:math display="inline" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow><mml:mi>α</mml:mi><mml:mo>∧</mml:mo><mml:mi>ω</mml:mi></mml:mrow></mml:math></alternatives></inline-formula></p>
670 <p><inline-formula><alternatives>
671 <tex-math><![CDATA[223]]></tex-math>
672 <mml:math display="inline" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mn>223</mml:mn></mml:math></alternatives></inline-formula></p>
675 <p><inline-formula><alternatives>
676 <tex-math><![CDATA[p]]></tex-math>
677 <mml:math display="inline" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>p</mml:mi></mml:math></alternatives></inline-formula>-Tree</p>
680 <p>Here’s some display math: <disp-formula><alternatives>
681 <tex-math><![CDATA[\frac{d}{dx}f(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}]]></tex-math>
682 <mml:math display="block" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow><mml:mfrac><mml:mi>d</mml:mi><mml:mrow><mml:mi>d</mml:mi><mml:mi>x</mml:mi></mml:mrow></mml:mfrac><mml:mi>f</mml:mi><mml:mo stretchy="false" form="prefix">(</mml:mo><mml:mi>x</mml:mi><mml:mo stretchy="false" form="postfix">)</mml:mo><mml:mo>=</mml:mo><mml:munder><mml:mo>lim</mml:mo><mml:mrow><mml:mi>h</mml:mi><mml:mo>→</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:munder><mml:mfrac><mml:mrow><mml:mi>f</mml:mi><mml:mo stretchy="false" form="prefix">(</mml:mo><mml:mi>x</mml:mi><mml:mo>+</mml:mo><mml:mi>h</mml:mi><mml:mo stretchy="false" form="postfix">)</mml:mo><mml:mo>−</mml:mo><mml:mi>f</mml:mi><mml:mo stretchy="false" form="prefix">(</mml:mo><mml:mi>x</mml:mi><mml:mo stretchy="false" form="postfix">)</mml:mo></mml:mrow><mml:mi>h</mml:mi></mml:mfrac></mml:mrow></mml:math></alternatives></disp-formula></p>
685 <p>Here’s one that has a line break in it:
686 <inline-formula><alternatives>
687 <tex-math><![CDATA[\alpha + \omega \times x^2]]></tex-math>
688 <mml:math display="inline" xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mrow><mml:mi>α</mml:mi><mml:mo>+</mml:mo><mml:mi>ω</mml:mi><mml:mo>×</mml:mo><mml:msup><mml:mi>x</mml:mi><mml:mn>2</mml:mn></mml:msup></mml:mrow></mml:math></alternatives></inline-formula>.</p>
691 <p>These shouldn’t be math:</p>
692 <list list-type="bullet">
694 <p>To get the famous equation, write
695 <monospace>$e = mc^2$</monospace>.</p>
698 <p>$22,000 is a <italic>lot</italic> of money. So is $34,000. (It worked
699 if “lot” is emphasized.)</p>
702 <p>Shoes ($20) and socks ($5).</p>
705 <p>Escaped <monospace>$</monospace>: $73 <italic>this should be
706 emphasized</italic> 23$.</p>
709 <p>Here’s a LaTeX table:</p>
711<sec id="special-characters">
712 <title>Special Characters</title>
713 <p>Here is some unicode:</p>
714 <list list-type="bullet">
725 <p>set membership: ∈</p>
731 <p>AT&T has an ampersand in their name.</p>
732 <p>AT&T is another way to write it.</p>
733 <p>This & that.</p>
741 <p>Right brace: }</p>
742 <p>Left bracket: [</p>
743 <p>Right bracket: ]</p>
745 <p>Right paren: )</p>
746 <p>Greater-than: ></p>
756 <title>Explicit</title>
758 <ext-link ext-link-type="uri" xlink:href="/url/">URL</ext-link>.</p>
759 <p><ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="title">URL
760 and title</ext-link>.</p>
761 <p><ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="title preceded by two spaces">URL
762 and title</ext-link>.</p>
763 <p><ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="title preceded by a tab">URL
764 and title</ext-link>.</p>
765 <p><ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="title with "quotes" in it">URL
766 and title</ext-link></p>
767 <p><ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="title with single quotes">URL
768 and title</ext-link></p>
769 <p><ext-link ext-link-type="uri" xlink:href="/url/with_underscore">with_underscore</ext-link></p>
770 <p><ext-link ext-link-type="uri" xlink:href="mailto:nobody@nowhere.net">Email
772 <p><ext-link ext-link-type="uri" xlink:href="">Empty</ext-link>.</p>
775 <title>Reference</title>
777 <ext-link ext-link-type="uri" xlink:href="/url/">bar</ext-link>.</p>
778 <p>With <ext-link ext-link-type="uri" xlink:href="/url/">embedded
779 [brackets]</ext-link>.</p>
780 <p><ext-link ext-link-type="uri" xlink:href="/url/">b</ext-link> by itself
781 should be a link.</p>
783 <ext-link ext-link-type="uri" xlink:href="/url">once</ext-link>.</p>
785 <ext-link ext-link-type="uri" xlink:href="/url">twice</ext-link>.</p>
787 <ext-link ext-link-type="uri" xlink:href="/url">thrice</ext-link>.</p>
788 <p>This should [not][] be a link.</p>
789 <preformat>[not]: /url</preformat>
791 <ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="Title with "quotes" inside">bar</ext-link>.</p>
793 <ext-link ext-link-type="uri" xlink:href="/url/" xlink:title="Title with "quote" inside">biz</ext-link>.</p>
795 <sec id="with-ampersands">
796 <title>With ampersands</title>
798 <ext-link ext-link-type="uri" xlink:href="http://example.com/?foo=1&bar=2">link
799 with an ampersand in the URL</ext-link>.</p>
800 <p>Here’s a link with an amersand in the link text:
801 <ext-link ext-link-type="uri" xlink:href="http://att.com/" xlink:title="AT&T">AT&T</ext-link>.</p>
803 <ext-link ext-link-type="uri" xlink:href="/script?foo=1&bar=2">inline
806 <ext-link ext-link-type="uri" xlink:href="/script?foo=1&bar=2">inline
807 link in pointy braces</ext-link>.</p>
810 <title>Autolinks</title>
811 <p>With an ampersand:
812 <ext-link ext-link-type="uri" xlink:href="http://example.com/?foo=1&bar=2">http://example.com/?foo=1&bar=2</ext-link></p>
813 <list list-type="bullet">
818 <p><ext-link ext-link-type="uri" xlink:href="http://example.com/">http://example.com/</ext-link></p>
824 <p>An e-mail address: <email>nobody@nowhere.net</email></p>
827 <ext-link ext-link-type="uri" xlink:href="http://example.com/">http://example.com/</ext-link></p>
829 <p>Auto-links should not occur here:
830 <monospace><http://example.com/></monospace></p>
831 <preformat>or here: <http://example.com/></preformat>
835 <title>Images</title>
836 <p>From “Voyage dans la Lune” by Georges Melies (1902):</p>
838 <caption>lalune</caption>
839 <graphic mimetype="image" mime-subtype="jpeg" xlink:href="lalune.jpg" xlink:title="Voyage dans la Lune" />
842 <inline-graphic mimetype="image" mime-subtype="jpeg" xlink:href="movie.jpg" />
846 <title>Footnotes</title>
847 <p>Here is a footnote reference,<fn>
848 <p>Here is the footnote. It can go anywhere after the footnote reference.
849 It need not be placed at the end of the document.</p>
850 </fn> and another.<fn>
851 <p>Here’s the long note. This one contains multiple blocks.</p>
852 <p>Subsequent blocks are indented to show that they belong to the footnote
853 (as with list items).</p>
854 <preformat> { <code> }</preformat>
855 <p>If you want, you can indent every line, but you can also be lazy and
856 just indent the first line of each block.</p>
857 </fn> This should <italic>not</italic> be a footnote reference, because it
858 contains a space.[^my note] Here is an inline note.<fn>
859 <p>This is <italic>easier</italic> to type. Inline notes may contain
860 <ext-link ext-link-type="uri" xlink:href="http://google.com">links</ext-link>
861 and <monospace>]</monospace> verbatim characters, as well as [bracketed
865 <p>Notes can go in quotes.<fn>
869 <list list-type="order">
871 <p>And in list items.<fn>
876 <p>This paragraph should not be part of the note, as it is not indented.</p>
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list