aboutsummaryrefslogtreecommitdiff
path: root/test/Tests/Readers
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2017-09-11 14:01:05 -0700
committerGitHub <noreply@github.com>2017-09-11 14:01:05 -0700
commitddecd727838c017f376cdd8d51e14db1b9652217 (patch)
treebc240b183d2aff8862f61f9f19101cd1969617a8 /test/Tests/Readers
parent1307b023af801d8eabeef7404478c4d923c82b0a (diff)
parent508c3a64d823989dc6613ac7656851989530af65 (diff)
downloadpandoc-ddecd727838c017f376cdd8d51e14db1b9652217.tar.gz
Merge pull request #3911 from labdsf/muse-reader-braces
Muse reader: parse {{{ }}} example syntax
Diffstat (limited to 'test/Tests/Readers')
-rw-r--r--test/Tests/Readers/Muse.hs33
1 files changed, 33 insertions, 0 deletions
diff --git a/test/Tests/Readers/Muse.hs b/test/Tests/Readers/Muse.hs
index 03dd895e0..baa4df7fd 100644
--- a/test/Tests/Readers/Muse.hs
+++ b/test/Tests/Readers/Muse.hs
@@ -248,6 +248,39 @@ tests =
lineBlock [ "Foo bar" ] <>
lineBlock [ "Foo bar" ] <>
lineBlock [ "\160\160\160Foo" ]
+ , testGroup "Example"
+ [ "Braces on separate lines" =:
+ T.unlines [ "{{{"
+ , "Example line"
+ , "}}}"
+ ] =?>
+ codeBlock "Example line"
+ , "Spaces after opening braces" =:
+ T.unlines [ "{{{ "
+ , "Example line"
+ , "}}}"
+ ] =?>
+ codeBlock "Example line"
+ , "One blank line in the beginning" =:
+ T.unlines [ "{{{"
+ , ""
+ , "Example line"
+ , "}}}"
+ ] =?>
+ codeBlock "\nExample line"
+ , "One blank line in the end" =:
+ T.unlines [ "{{{"
+ , "Example line"
+ , ""
+ , "}}}"
+ ] =?>
+ codeBlock "Example line\n"
+ -- Amusewiki requires braces to be on separate line,
+ -- this is an extension.
+ , "One line" =:
+ "{{{Example line}}}" =?>
+ codeBlock "Example line"
+ ]
, testGroup "Example tag"
[ "Tags on separate lines" =:
T.unlines [ "<example>"