aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2017-11-01 00:04:36 -0400
committerGitHub <noreply@github.com>2017-11-01 00:04:36 -0400
commitfd7e3cb18f55e05795180b782a1b61dc602b6ac4 (patch)
tree01cfd2a6981c72a1df0b82671650d7b9fcc27ed8 /test
parent0e57b8b85dd22b78e2f60226700260b4eb8d36ea (diff)
parent534e625ace6c2d94af5544591fab0a425445dfa3 (diff)
downloadpandoc-fd7e3cb18f55e05795180b782a1b61dc602b6ac4.tar.gz
Merge pull request #4018 from swilde/creole-fixes
Creole Reader: fix lists with triling white space
Diffstat (limited to 'test')
-rw-r--r--test/Tests/Readers/Creole.hs15
1 files changed, 14 insertions, 1 deletions
diff --git a/test/Tests/Readers/Creole.hs b/test/Tests/Readers/Creole.hs
index 96517c25c..3a21df738 100644
--- a/test/Tests/Readers/Creole.hs
+++ b/test/Tests/Readers/Creole.hs
@@ -127,6 +127,11 @@ tests = [
=?> bulletList [ plain "foo"
<> bulletList [ plain "bar", plain "baz" ]
, plain "blubb" ]
+ , "nested unordered list, one separating space, trailing space" =:
+ "* foo \n** bar \n** baz \n* blubb "
+ =?> bulletList [ plain "foo"
+ <> bulletList [ plain "bar", plain "baz" ]
+ , plain "blubb" ]
, "ordered list, two entries, one separating space" =:
"# foo\n# bar"
=?> orderedList [ plain "foo", plain "bar" ]
@@ -141,6 +146,11 @@ tests = [
=?> orderedList [ plain "foo"
<> orderedList [ plain "bar", plain "baz" ]
, plain "blubb" ]
+ , "nested ordered list, one separating space, trailing space" =:
+ "# foo \n## bar \n## baz \n# blubb "
+ =?> orderedList [ plain "foo"
+ <> orderedList [ plain "bar", plain "baz" ]
+ , plain "blubb" ]
, "nested many ordered lists, one separating space" =:
("# foo\n## bar\n### third\n### third two\n## baz\n### third again\n"
<> "#### fourth\n##### fith\n# blubb")
@@ -193,7 +203,10 @@ tests = [
, "forced line breaks" =:
"{{{no break!\\\\here}}} but a break\\\\here!"
=?> para (code "no break!\\\\here" <> " but a break"
- <> linebreak <> "here!")
+ <> linebreak <> "here!"),
+ "quoted block, after trailing white space" =:
+ "this is a paragraph \n{{{\nfoo bar\n //baz//\n}}}"
+ =?> para "this is a paragraph" <> codeBlock "foo bar\n //baz//"
]
, testGroup "Images and Links" [
"image simple" =: