all repos — grayfriday @ e95d23065aaafd2c383c35124cbb983609606011

blackfriday fork with a few changes

ref_test.go (view raw)

 1//
 2// Blackfriday Markdown Processor
 3// Available at http://github.com/russross/blackfriday
 4//
 5// Copyright © 2011 Russ Ross <russ@russross.com>.
 6// Distributed under the Simplified BSD License.
 7// See README.md for details.
 8//
 9
10//
11// Markdown 1.0.3 reference tests
12//
13
14package blackfriday
15
16import "testing"
17
18func TestReference(t *testing.T) {
19	files := []string{
20		"Amps and angle encoding",
21		"Auto links",
22		"Backslash escapes",
23		"Blockquotes with code blocks",
24		"Code Blocks",
25		"Code Spans",
26		"Hard-wrapped paragraphs with list-like lines",
27		"Horizontal rules",
28		"Inline HTML (Advanced)",
29		"Inline HTML (Simple)",
30		"Inline HTML comments",
31		"Links, inline style",
32		"Links, reference style",
33		"Links, shortcut references",
34		"Literal quotes in titles",
35		"Markdown Documentation - Basics",
36		"Markdown Documentation - Syntax",
37		"Nested blockquotes",
38		"Ordered and unordered lists",
39		"Strong and em together",
40		"Tabs",
41		"Tidyness",
42	}
43	doTestsReference(t, files, 0)
44}
45
46func TestReference_EXTENSION_NO_EMPTY_LINE_BEFORE_BLOCK(t *testing.T) {
47	files := []string{
48		"Amps and angle encoding",
49		"Auto links",
50		"Backslash escapes",
51		"Blockquotes with code blocks",
52		"Code Blocks",
53		"Code Spans",
54		"Hard-wrapped paragraphs with list-like lines no empty line before block",
55		"Horizontal rules",
56		"Inline HTML (Advanced)",
57		"Inline HTML (Simple)",
58		"Inline HTML comments",
59		"Links, inline style",
60		"Links, reference style",
61		"Links, shortcut references",
62		"Literal quotes in titles",
63		"Markdown Documentation - Basics",
64		"Markdown Documentation - Syntax",
65		"Nested blockquotes",
66		"Ordered and unordered lists",
67		"Strong and em together",
68		"Tabs",
69		"Tidyness",
70	}
71	doTestsReference(t, files, NoEmptyLineBeforeBlock)
72}