diff --git a/block_test.go b/block_test.go index b8903df..ae75f2b 100644 --- a/block_test.go +++ b/block_test.go @@ -473,3 +473,79 @@ func TestOrderedList(t *testing.T) { } doTestsBlock(t, tests, 0) } + +func TestPreformattedHtml(t *testing.T) { + var tests = []string{ + "
\n", + "\n", + + "Paragraph\n
Paragraph
\n\nParagraph\n
Paragraph
\n\nParagraph\n
And here?
\n", + + "Paragraph\n\nParagraph
\n\nAnd here?
\n", + } + doTestsBlock(t, tests, 0) +} + +func TestPreformattedHtmlLax(t *testing.T) { + var tests = []string{ + "Paragraph\nParagraph
\n\nParagraph
\n\nParagraph
\n\nAnd here?
\n", + + "Paragraph\n\nParagraph
\n\nAnd here?
\n", + + "Paragraph\nParagraph
\n\nAnd here?
\n", + + "Paragraph\n\nParagraph
\n\nAnd here?
\n", + } + doTestsBlock(t, tests, EXTENSION_LAX_HTML_BLOCKS) +}