git.iko.soy/typeable/pandoc
on 1.9.0.5 help sign in
792 lines 11 kB history raw
1.TH Pandoc "" "July 17, 2006" "Test Suite"
2.PP
3This is a set of tests for pandoc.
4Most of them are adapted from John Gruber's markdown test suite.
5.PP
6 * * * * *
7.SH Headers
8.SS Level 2 with an embedded link (/url)
9.SS Level 3 with \f[I]emphasis\f[]
10.SS Level 4
11.SS Level 5
12.SH Level 1
13.SS Level 2 with \f[I]emphasis\f[]
14.SS Level 3
15.PP
16with no blank line
17.SS Level 2
18.PP
19with no blank line
20.PP
21 * * * * *
22.SH Paragraphs
23.PP
24Here's a regular paragraph.
25.PP
26In Markdown 1.0.0 and earlier.
27Version 8.
28This line turns into a list item.
29Because a hard-wrapped line in the middle of a paragraph looked like a list
30item.
31.PP
32Here's one with a bullet.
33* criminey.
34.PP
35There should be a hard line break
36.PD 0
37.P
38.PD
39here.
40.PP
41 * * * * *
42.SH Block Quotes
43.PP
44E-mail style:
45.RS
46.PP
47This is a block quote.
48It is pretty short.
49.RE
50.RS
51.PP
52Code in a block quote:
53.IP
54.nf
55\f[C]
56sub\ status\ {
57\ \ \ \ print\ "working";
59\f[]
60.fi
61.PP
62A list:
63.IP "1." 3
64item one
65.IP "2." 3
66item two
67.PP
68Nested block quotes:
69.RS
70.PP
71nested
72.RE
73.RS
74.PP
75nested
76.RE
77.RE
78.PP
79This should not be a block quote: 2 > 1.
80.PP
81And a following paragraph.
82.PP
83 * * * * *
84.SH Code Blocks
85.PP
86Code:
87.IP
88.nf
89\f[C]
90----\ (should\ be\ four\ hyphens)
92sub\ status\ {
93\ \ \ \ print\ "working";
96this\ code\ block\ is\ indented\ by\ one\ tab
97\f[]
98.fi
99.PP
100And:
101.IP
102.nf
103\f[C]
104\ \ \ \ this\ code\ block\ is\ indented\ by\ two\ tabs
106These\ should\ not\ be\ escaped:\ \ \\$\ \\\\\ \\>\ \\[\ \\{
107\f[]
108.fi
109.PP
110 * * * * *
111.SH Lists
112.SS Unordered
113.PP
114Asterisks tight:
115.IP \[bu] 2
116asterisk 1
117.IP \[bu] 2
118asterisk 2
119.IP \[bu] 2
120asterisk 3
121.PP
122Asterisks loose:
123.IP \[bu] 2
124asterisk 1
125.IP \[bu] 2
126asterisk 2
127.IP \[bu] 2
128asterisk 3
129.PP
130Pluses tight:
131.IP \[bu] 2
132Plus 1
133.IP \[bu] 2
134Plus 2
135.IP \[bu] 2
136Plus 3
137.PP
138Pluses loose:
139.IP \[bu] 2
140Plus 1
141.IP \[bu] 2
142Plus 2
143.IP \[bu] 2
144Plus 3
145.PP
146Minuses tight:
147.IP \[bu] 2
148Minus 1
149.IP \[bu] 2
150Minus 2
151.IP \[bu] 2
152Minus 3
153.PP
154Minuses loose:
155.IP \[bu] 2
156Minus 1
157.IP \[bu] 2
158Minus 2
159.IP \[bu] 2
160Minus 3
161.SS Ordered
162.PP
163Tight:
164.IP "1." 3
165First
166.IP "2." 3
167Second
168.IP "3." 3
169Third
170.PP
171and:
172.IP "1." 3
173One
174.IP "2." 3
175Two
176.IP "3." 3
177Three
178.PP
179Loose using tabs:
180.IP "1." 3
181First
182.IP "2." 3
183Second
184.IP "3." 3
185Third
186.PP
187and using spaces:
188.IP "1." 3
189One
190.IP "2." 3
191Two
192.IP "3." 3
193Three
194.PP
195Multiple paragraphs:
196.IP "1." 3
197Item 1, graf one.
198.RS 4
199.PP
200Item 1.
201graf two.
202The quick brown fox jumped over the lazy dog's back.
203.RE
204.IP "2." 3
205Item 2.
206.IP "3." 3
207Item 3.
208.SS Nested
209.IP \[bu] 2
210Tab
211.RS 2
212.IP \[bu] 2
213Tab
214.RS 2
215.IP \[bu] 2
216Tab
217.RE
218.RE
219.PP
220Here's another:
221.IP "1." 3
222First
223.IP "2." 3
224Second:
225.RS 4
226.IP \[bu] 2
227Fee
228.IP \[bu] 2
229Fie
230.IP \[bu] 2
231Foe
232.RE
233.IP "3." 3
234Third
235.PP
236Same thing but with paragraphs:
237.IP "1." 3
238First
239.IP "2." 3
240Second:
241.RS 4
242.IP \[bu] 2
243Fee
244.IP \[bu] 2
245Fie
246.IP \[bu] 2
247Foe
248.RE
249.IP "3." 3
250Third
251.SS Tabs and spaces
252.IP \[bu] 2
253this is a list item indented with tabs
254.IP \[bu] 2
255this is a list item indented with spaces
256.RS 2
257.IP \[bu] 2
258this is an example list item indented with tabs
259.IP \[bu] 2
260this is an example list item indented with spaces
261.RE
262.SS Fancy list markers
263.IP "(2)" 4
264begins with 2
265.IP "(3)" 4
266and now 3
267.RS 4
268.PP
269with a continuation
270.IP "iv." 4
271sublist with roman numerals, starting with 4
272.IP " v." 4
273more items
274.RS 4
275.IP "(A)" 4
276a subsublist
277.IP "(B)" 4
278a subsublist
279.RE
280.RE
281.PP
282Nesting:
283.IP "A." 3
284Upper Alpha
285.RS 4
286.IP "I." 3
287Upper Roman.
288.RS 4
289.IP "(6)" 4
290Decimal start with 6
291.RS 4
292.IP "c)" 3
293Lower alpha with paren
294.RE
295.RE
296.RE
297.PP
298Autonumbering:
299.IP "1." 3
300Autonumber.
301.IP "2." 3
302More.
303.RS 4
304.IP "1." 3
305Nested.
306.RE
307.PP
308Should not be a list item:
309.PP
310M.A.\ 2007
311.PP
312B.
313Williams
314.PP
315 * * * * *
316.SH Definition Lists
317.PP
318Tight using spaces:
319.TP
320.B apple
321red fruit
322.RS
323.RE
324.TP
325.B orange
326orange fruit
327.RS
328.RE
329.TP
330.B banana
331yellow fruit
332.RS
333.RE
334.PP
335Tight using tabs:
336.TP
337.B apple
338red fruit
339.RS
340.RE
341.TP
342.B orange
343orange fruit
344.RS
345.RE
346.TP
347.B banana
348yellow fruit
349.RS
350.RE
351.PP
352Loose:
353.TP
354.B apple
355red fruit
356.RS
357.RE
358.TP
359.B orange
360orange fruit
361.RS
362.RE
363.TP
364.B banana
365yellow fruit
366.RS
367.RE
368.PP
369Multiple blocks with italics:
370.TP
371.B \f[I]apple\f[]
372red fruit
373.RS
374.PP
375contains seeds, crisp, pleasant to taste
376.RE
377.TP
378.B \f[I]orange\f[]
379orange fruit
380.RS
381.IP
382.nf
383\f[C]
384{\ orange\ code\ block\ }
385\f[]
386.fi
387.RS
388.PP
389orange block quote
390.RE
391.RE
392.PP
393Multiple definitions, tight:
394.TP
395.B apple
396red fruit
397.RS
398.RE
399computer
400.RS
401.RE
402.TP
403.B orange
404orange fruit
405.RS
406.RE
407bank
408.RS
409.RE
410.PP
411Multiple definitions, loose:
412.TP
413.B apple
414red fruit
415.RS
416.RE
417computer
418.RS
419.RE
420.TP
421.B orange
422orange fruit
423.RS
424.RE
425bank
426.RS
427.RE
428.PP
429Blank line after term, indented marker, alternate markers:
430.TP
431.B apple
432red fruit
433.RS
434.RE
435computer
436.RS
437.RE
438.TP
439.B orange
440orange fruit
441.RS
442.IP "1." 3
443sublist
444.IP "2." 3
445sublist
446.RE
447.SH HTML Blocks
448.PP
449Simple block on one line:
450foo
451.PP
452And nested without indentation:
453foo
454bar
455.PP
456Interpreted markdown in a table:
457This is \f[I]emphasized\f[]
458And this is \f[B]strong\f[]
459.PP
460Here's a simple block:
461foo
462.PP
463This should be a code block, though:
464.IP
465.nf
466\f[C]
467<div>
468\ \ \ \ foo
469</div>
470\f[]
471.fi
472.PP
473As should this:
474.IP
475.nf
476\f[C]
477<div>foo</div>
478\f[]
479.fi
480.PP
481Now, nested:
482foo
483.PP
484This should just be an HTML comment:
485.PP
486Multiline:
487.PP
488Code block:
489.IP
490.nf
491\f[C]
492<!--\ Comment\ -->
493\f[]
494.fi
495.PP
496Just plain comment, with trailing spaces on the line:
497.PP
498Code:
499.IP
500.nf
501\f[C]
502<hr\ />
503\f[]
504.fi
505.PP
506Hr's:
507.PP
508 * * * * *
509.SH Inline Markup
510.PP
511This is \f[I]emphasized\f[], and so \f[I]is this\f[].
512.PP
513This is \f[B]strong\f[], and so \f[B]is this\f[].
514.PP
515An \f[I]emphasized link (/url)\f[].
516.PP
517\f[B]\f[I]This is strong and em.\f[]\f[]
518.PP
519So is \f[B]\f[I]this\f[]\f[] word.
520.PP
521\f[B]\f[I]This is strong and em.\f[]\f[]
522.PP
523So is \f[B]\f[I]this\f[]\f[] word.
524.PP
525This is code: \f[C]>\f[], \f[C]$\f[], \f[C]\\\f[], \f[C]\\$\f[],
526\f[C]<html>\f[].
527.PP
528[STRIKEOUT:This is \f[I]strikeout\f[].]
529.PP
530Superscripts: a^bc^d a^\f[I]hello\f[]^ a^hello\ there^.
531.PP
532Subscripts: H~2~O, H~23~O, H~many\ of\ them~O.
533.PP
534These should not be superscripts or subscripts, because of the unescaped
535spaces: a^b c^d, a~b c~d.
536.PP
537 * * * * *
538.SH Smart quotes, ellipses, dashes
539.PP
540\[lq]Hello,\[rq] said the spider.
541\[lq]`Shelob' is my name.\[rq]
542.PP
543`A', `B', and `C' are letters.
544.PP
545`Oak,' `elm,' and `beech' are names of trees.
546So is `pine.'
547.PP
548`He said, \[lq]I want to go.\[rq]' Were you alive in the 70's?
549.PP
550Here is some quoted `\f[C]code\f[]' and a \[lq]quoted
551link (http://example.com/?foo=1&bar=2)\[rq].
552.PP
553Some dashes: one\[em]two \[em] three\[em]four \[em] five.
554.PP
555Dashes between numbers: 5\[en]7, 255\[en]66, 1987\[en]1999.
556.PP
557Ellipses\&...and\&...and\&....
558.PP
559 * * * * *
560.SH LaTeX
561.IP \[bu] 2
562.IP \[bu] 2
5632 + 2 = 4
564.IP \[bu] 2
565\f[I]x\f[] ∈ \f[I]y\f[]
566.IP \[bu] 2
567\f[I]α\f[] ∧ \f[I]ω\f[]
568.IP \[bu] 2
569223
570.IP \[bu] 2
571\f[I]p\f[]-Tree
572.IP \[bu] 2
573Here's some display math:
574.RS
575$\\frac{d}{dx}f(x)=\\lim_{h\\to 0}\\frac{f(x+h)-f(x)}{h}$
576.RE
577.IP \[bu] 2
578Here's one that has a line break in it:
579\f[I]α\f[] + \f[I]ω\f[] × \f[I]x\f[]^2^.
580.PP
581These shouldn't be math:
582.IP \[bu] 2
583To get the famous equation, write \f[C]$e\ =\ mc^2$\f[].
584.IP \[bu] 2
585$22,000 is a \f[I]lot\f[] of money.
586So is $34,000.
587(It worked if \[lq]lot\[rq] is emphasized.)
588.IP \[bu] 2
589Shoes ($20) and socks ($5).
590.IP \[bu] 2
591Escaped \f[C]$\f[]: $73 \f[I]this should be emphasized\f[] 23$.
592.PP
593Here's a LaTeX table:
594.PP
595 * * * * *
596.SH Special Characters
597.PP
598Here is some unicode:
599.IP \[bu] 2
600I hat: Î
601.IP \[bu] 2
602o umlaut: ö
603.IP \[bu] 2
604section: §
605.IP \[bu] 2
606set membership: ∈
607.IP \[bu] 2
608copyright: ©
609.PP
610AT&T has an ampersand in their name.
611.PP
612AT&T is another way to write it.
613.PP
614This & that.
615.PP
6164 < 5.
617.PP
6186 > 5.
619.PP
620Backslash: \\
621.PP
622Backtick: `
623.PP
624Asterisk: *
625.PP
626Underscore: _
627.PP
628Left brace: {
629.PP
630Right brace: }
631.PP
632Left bracket: [
633.PP
634Right bracket: ]
635.PP
636Left paren: (
637.PP
638Right paren: )
639.PP
640Greater-than: >
641.PP
642Hash: #
643.PP
644Period: .
645.PP
646Bang: !
647.PP
648Plus: +
649.PP
650Minus: -
651.PP
652 * * * * *
653.SH Links
654.SS Explicit
655.PP
656Just a URL (/url/).
657.PP
658URL and title (/url/).
659.PP
660URL and title (/url/).
661.PP
662URL and title (/url/).
663.PP
664URL and title (/url/)
665.PP
666URL and title (/url/)
667.PP
668with_underscore (/url/with_underscore)
669.PP
670Email link (mailto:nobody@nowhere.net)
671.PP
672Empty ().
673.SS Reference
674.PP
675Foo bar (/url/).
676.PP
677Foo bar (/url/).
678.PP
679Foo bar (/url/).
680.PP
681With embedded [brackets] (/url/).
682.PP
683b (/url/) by itself should be a link.
684.PP
685Indented once (/url).
686.PP
687Indented twice (/url).
688.PP
689Indented thrice (/url).
690.PP
691This should [not][] be a link.
692.IP
693.nf
694\f[C]
695[not]:\ /url
696\f[]
697.fi
698.PP
699Foo bar (/url/).
700.PP
701Foo biz (/url/).
702.SS With ampersands
703.PP
704Here's a link with an ampersand in the URL (http://example.com/?foo=1&bar=2).
705.PP
706Here's a link with an amersand in the link text: AT&T (http://att.com/).
707.PP
708Here's an inline link (/script?foo=1&bar=2).
709.PP
710Here's an inline link in pointy braces (/script?foo=1&bar=2).
711.SS Autolinks
712.PP
713With an ampersand: <http://example.com/?foo=1&bar=2>
714.IP \[bu] 2
715In a list?
716.IP \[bu] 2
717<http://example.com/>
718.IP \[bu] 2
719It should.
720.PP
721An e-mail address: <nobody@nowhere.net>
722.RS
723.PP
724Blockquoted: <http://example.com/>
725.RE
726.PP
727Auto-links should not occur here: \f[C]<http://example.com/>\f[]
728.IP
729.nf
730\f[C]
731or\ here:\ <http://example.com/>
732\f[]
733.fi
734.PP
735 * * * * *
736.SH Images
737.PP
738From \[lq]Voyage dans la Lune\[rq] by Georges Melies (1902):
739.PP
740[IMAGE: lalune (lalune.jpg)]
741.PP
742Here is a movie [IMAGE: movie (movie.jpg)] icon.
743.PP
744 * * * * *
745.SH Footnotes
746.PP
747Here is a footnote reference,[1] and another.[2] This should \f[I]not\f[] be a
748footnote reference, because it contains a space.[^my note] Here is an inline
749note.[3]
750.RS
751.PP
752Notes can go in quotes.[4]
753.RE
754.IP "1." 3
755And in list items.[5]
756.PP
757This paragraph should not be part of the note, as it is not indented.
758.SH NOTES
759.SS [1]
760.PP
761Here is the footnote.
762It can go anywhere after the footnote reference.
763It need not be placed at the end of the document.
764.SS [2]
765.PP
766Here's the long note.
767This one contains multiple blocks.
768.PP
769Subsequent blocks are indented to show that they belong to the footnote (as
770with list items).
771.IP
772.nf
773\f[C]
774\ \ {\ <code>\ }
775\f[]
776.fi
777.PP
778If you want, you can indent every line, but you can also be lazy and just
779indent the first line of each block.
780.SS [3]
781.PP
782This is \f[I]easier\f[] to type.
783Inline notes may contain links (http://google.com) and \f[C]]\f[] verbatim
784characters, as well as [bracketed text].
785.SS [4]
786.PP
787In quote.
788.SS [5]
789.PP
790In list.
791.SH AUTHORS
792John MacFarlane; Anonymous.