summaryrefslogtreecommitdiff
path: root/test/Tests/Writers
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2017-08-10 23:51:42 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2017-08-10 23:51:42 -0700
commit83d856ee6c4065bc998832b60ec4347b0f528b6d (patch)
tree66c2816a90758ca6e758746f06450eb389f54c0f /test/Tests/Writers
parent0283616a4a4e5c9770a9bf2247efad96dcf984f8 (diff)
Fixed writer tests not to use writerUserDataDir.
Diffstat (limited to 'test/Tests/Writers')
-rw-r--r--test/Tests/Writers/Docx.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/Tests/Writers/Docx.hs b/test/Tests/Writers/Docx.hs
index ec147604c..9e6150abc 100644
--- a/test/Tests/Writers/Docx.hs
+++ b/test/Tests/Writers/Docx.hs
@@ -3,7 +3,7 @@ module Tests.Writers.Docx (tests) where
import System.FilePath ((</>))
import Test.Tasty
import Tests.Helpers
-import Text.Pandoc.Class (runIOorExplode)
+import Text.Pandoc.Class (runIOorExplode, setUserDataDir)
import Text.Pandoc.Definition
import Text.Pandoc.Options
import Text.Pandoc.Walk
@@ -24,9 +24,9 @@ compareOutput (wopts, ropts) nativeFileIn nativeFileOut = do
nf <- UTF8.toText <$> BS.readFile nativeFileIn
nf' <- UTF8.toText <$> BS.readFile nativeFileOut
runIOorExplode $ do
+ setUserDataDir $ Just (".." </> "data")
roundtripped <- readNative def nf >>=
- writeDocx wopts{writerUserDataDir = Just (".." </> "data")} >>=
- readDocx ropts
+ writeDocx wopts >>= readDocx ropts
orig <- readNative def nf'
return (walk fixImages roundtripped, walk fixImages orig)