aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAlexander Krotov <ilabdsf@gmail.com>2018-09-11 14:22:09 +0300
committerAlexander Krotov <ilabdsf@gmail.com>2018-09-11 14:22:09 +0300
commit0ac3512cfe39761bb7ced6d9b624315c94c2cc8d (patch)
tree69973b98b5091cae7b30201ead70bef5251fe1af /test
parent1aac754359d44a96e30e96f61f38c58d6aea29b4 (diff)
downloadpandoc-0ac3512cfe39761bb7ced6d9b624315c94c2cc8d.tar.gz
Muse reader tests: accept Blocks instead of Block in round trip test
This way testcase can be shrinked better up to removing all blocks completely.
Diffstat (limited to 'test')
-rw-r--r--test/Tests/Readers/Muse.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/Tests/Readers/Muse.hs b/test/Tests/Readers/Muse.hs
index 73abff213..e88cfa5f1 100644
--- a/test/Tests/Readers/Muse.hs
+++ b/test/Tests/Readers/Muse.hs
@@ -39,9 +39,9 @@ makeRoundTrip x = x
-- Demand that any AST produced by Muse reader and written by Muse writer can be read back exactly the same way.
-- Currently we remove tables and compare first rewrite to the second.
-roundTrip :: Block -> Bool
+roundTrip :: Blocks -> Bool
roundTrip b = d' == d''
- where d = walk makeRoundTrip $ Pandoc nullMeta [b]
+ where d = walk makeRoundTrip $ Pandoc nullMeta $ toList b
d' = rewrite d
d'' = rewrite d'
rewrite = amuse . T.pack . (++ "\n") . T.unpack .