all repos — grayfriday @ ff2d79c2cb08e0b410143e26f71a0e80e49d5b20

blackfriday fork with a few changes

markdown_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// Unit tests for full document parsing and rendering
12//
13
14package blackfriday
15
16import "testing"
17
18func TestDocument(t *testing.T) {
19	var tests = []string{
20		// Empty document.
21		"",
22		"",
23
24		" ",
25		"",
26
27		// This shouldn't panic.
28		// https://github.com/russross/blackfriday/issues/172
29		"[]:<",
30		"<p>[]:&lt;</p>\n",
31
32		// This shouldn't panic.
33		// https://github.com/russross/blackfriday/issues/173
34		"   [",
35		"<p>[</p>\n",
36	}
37	doTests(t, tests)
38}