summaryrefslogtreecommitdiff
path: root/tests/Tests/Readers/Docx.hs
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2016-11-27 16:38:46 +0100
committerJohn MacFarlane <jgm@berkeley.edu>2017-01-25 17:07:40 +0100
commit18e85f8dfbf9323945969cdf831c9a16f90299a0 (patch)
treec47adf1787d486874c54e18b9d19821fc0ca5433 /tests/Tests/Readers/Docx.hs
parentbf8fb78389c0d2dc06ad91bc379fde5bd7e1f768 (diff)
Changed readNative to use PandocMonad.
Diffstat (limited to 'tests/Tests/Readers/Docx.hs')
-rw-r--r--tests/Tests/Readers/Docx.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/Tests/Readers/Docx.hs b/tests/Tests/Readers/Docx.hs
index 3e630dd49..59147b664 100644
--- a/tests/Tests/Readers/Docx.hs
+++ b/tests/Tests/Readers/Docx.hs
@@ -14,6 +14,7 @@ import qualified Data.Map as M
import Text.Pandoc.MediaBag (MediaBag, lookupMedia, mediaDirectory)
import Codec.Archive.Zip
import Text.Pandoc.Error
+import Text.Pandoc.Class (runIOorExplode)
-- We define a wrapper around pandoc that doesn't normalize in the
-- tests. Since we do our own normalization, we want to make sure
@@ -43,7 +44,8 @@ compareOutput opts docxFile nativeFile = do
df <- B.readFile docxFile
nf <- Prelude.readFile nativeFile
let (p, _) = handleError $ readDocx opts df
- return $ (noNorm p, noNorm (handleError $ readNative nf))
+ df' <- runIOorExplode $ readNative nf
+ return $ (noNorm p, noNorm $ handleError df')
testCompareWithOptsIO :: ReaderOptions -> String -> FilePath -> FilePath -> IO Test
testCompareWithOptsIO opts name docxFile nativeFile = do