diff options
Diffstat (limited to 'test/Tests/Readers')
-rw-r--r-- | test/Tests/Readers/Docx.hs | 2 | ||||
-rw-r--r-- | test/Tests/Readers/HTML.hs | 8 | ||||
-rw-r--r-- | test/Tests/Readers/Man.hs | 30 | ||||
-rw-r--r-- | test/Tests/Readers/Org/Meta.hs | 2 | ||||
-rw-r--r-- | test/Tests/Readers/Txt2Tags.hs | 6 |
5 files changed, 24 insertions, 24 deletions
diff --git a/test/Tests/Readers/Docx.hs b/test/Tests/Readers/Docx.hs index bc036e0cc..4d2e0d276 100644 --- a/test/Tests/Readers/Docx.hs +++ b/test/Tests/Readers/Docx.hs @@ -91,7 +91,7 @@ testForWarningsWithOpts opts name docxFile expected = getMedia :: FilePath -> FilePath -> IO (Maybe B.ByteString) getMedia archivePath mediaPath = do - zf <- B.readFile archivePath >>= return . toArchive + zf <- toArchive <$> B.readFile archivePath return $ findEntryByPath ("word/" ++ mediaPath) zf >>= (Just . fromEntry) compareMediaPathIO :: FilePath -> MediaBag -> FilePath -> IO Bool diff --git a/test/Tests/Readers/HTML.hs b/test/Tests/Readers/HTML.hs index 189d37945..571c5ff49 100644 --- a/test/Tests/Readers/HTML.hs +++ b/test/Tests/Readers/HTML.hs @@ -95,14 +95,14 @@ tests = [ testGroup "base tag" ] , testGroup "samp" [ - test html "inline samp block" $ - "<samp>Answer is 42</samp>" =?> + test html "inline samp block" $ + "<samp>Answer is 42</samp>" =?> plain (codeWith ("",["sample"],[]) "Answer is 42") ] , testGroup "var" [ - test html "inline var block" $ - "<var>result</var>" =?> + test html "inline var block" $ + "<var>result</var>" =?> plain (codeWith ("",["variable"],[]) "result") ] , askOption $ \(QuickCheckTests numtests) -> diff --git a/test/Tests/Readers/Man.hs b/test/Tests/Readers/Man.hs index c3d2582ca..92a9207cb 100644 --- a/test/Tests/Readers/Man.hs +++ b/test/Tests/Readers/Man.hs @@ -51,13 +51,13 @@ tests = [ =?> header 2 (text "The header 2") , "Macro args" =: ".B \"single arg with \"\"Q\"\"\"" - =?> (para $ strong $ text "single arg with \"Q\"") + =?>para (strong $ text "single arg with \"Q\"") , "Argument from next line" =: ".B\nsingle arg with \"Q\"" - =?> (para $ strong $ text "single arg with \"Q\"") + =?>para (strong $ text "single arg with \"Q\"") , "comment" =: ".\\\"bla\naaa" - =?> (para $ str "aaa") + =?>para (str "aaa") , "link" =: ".BR aa (1)" =?> para (strong (str "aa") <> str "(1)") @@ -65,7 +65,7 @@ tests = [ testGroup "Escapes" [ "fonts" =: "aa\\fIbb\\fRcc" - =?> (para $ str "aa" <> (emph $ str "bb") <> str "cc") + =?>para (str "aa" <> (emph $ str "bb") <> str "cc") , "nested fonts" =: "\\f[BI]hi\\f[I] there\\f[R]" =?> para (emph (strong (text "hi") <> text " there")) @@ -75,26 +75,26 @@ tests = [ text " ok") , "skip" =: "a\\%\\\n\\:b\\0" - =?> (para $ str "ab\8199") + =?>para (str "ab\8199") , "replace" =: "\\-\\ \\\\\\[lq]\\[rq]\\[em]\\[en]\\*(lq\\*(rq" - =?> (para $ text "- \\“”—–“”") + =?>para (text "- \\“”—–“”") , "replace2" =: - "\\t\\e\\`\\^\\|\\'" =?> (para $ text "\\`\8202\8198`") + "\\t\\e\\`\\^\\|\\'" =?>para (text "\\`\8202\8198`") , "comment with \\\"" =: - "Foo \\\" bar\n" =?> (para $ text "Foo") + "Foo \\\" bar\n" =?>para (text "Foo") , "comment with \\#" =: - "Foo\\#\nbar\n" =?> (para $ text "Foobar") + "Foo\\#\nbar\n" =?>para (text "Foobar") , "two letter escapes" =: - "\\(oA\\(~O" =?> (para $ text "ÅÕ") + "\\(oA\\(~O" =?>para (text "ÅÕ") , "bracketed escapes" =: - "\\[oA]\\[~O]\\[Do]\\[Ye]\\[product]\\[ul]" =?> (para $ text "ÅÕ$¥∏_") + "\\[oA]\\[~O]\\[Do]\\[Ye]\\[product]\\[ul]" =?>para (text "ÅÕ$¥∏_") , "unicode escapes" =: - "\\[u2020]" =?> (para $ text "†") + "\\[u2020]" =?>para (text "†") , "unicode escapes (combined)" =: - "\\[u0075_u0301]" =?> (para $ text "\250") + "\\[u0075_u0301]" =?>para (text "\250") , "unknown escape (#5034)" =: - "\\9" =?> (para $ text "9") + "\\9" =?>para (text "9") ], testGroup "Lists" [ "bullet" =: @@ -108,7 +108,7 @@ tests = [ =?> orderedListWith (1,UpperAlpha,OneParen) [para $ str "first", para $ str "second"] , "nested" =: ".IP \"\\[bu]\"\nfirst\n.RS\n.IP \"\\[bu]\"\n1a\n.IP \"\\[bu]\"\n1b\n.RE" - =?> bulletList [(para $ str "first") <> (bulletList [para $ str "1a", para $ str "1b"])] + =?> bulletList [para (str "first") <> bulletList [para $ str "1a", para $ str "1b"]] , "change in list style" =: ".IP \\[bu]\nfirst\n.IP 1\nsecond" =?> bulletList [para (str "first")] <> diff --git a/test/Tests/Readers/Org/Meta.hs b/test/Tests/Readers/Org/Meta.hs index 2843bf0d0..3b89ac5ad 100644 --- a/test/Tests/Readers/Org/Meta.hs +++ b/test/Tests/Readers/Org/Meta.hs @@ -199,6 +199,6 @@ tests = , "#+pandoc-emphasis-post:" , "[/noemph/]" ] =?> - para ("[/noemph/]") + para "[/noemph/]" ] ] diff --git a/test/Tests/Readers/Txt2Tags.hs b/test/Tests/Readers/Txt2Tags.hs index 20b1e74e7..dbf388a0f 100644 --- a/test/Tests/Readers/Txt2Tags.hs +++ b/test/Tests/Readers/Txt2Tags.hs @@ -311,14 +311,14 @@ tests = , "Ordered List in Bullet List" =: ("- Emacs\n" <> " + Org\n") =?> - bulletList [ (plain "Emacs") <> - (orderedList [ plain "Org"]) + bulletList [ plain "Emacs" <> + orderedList [ plain "Org"] ] , "Bullet List in Ordered List" =: ("+ GNU\n" <> " - Freedom\n") =?> - orderedList [ (plain "GNU") <> bulletList [ (plain "Freedom") ] ] + orderedList [ plain "GNU" <> bulletList [ plain "Freedom" ] ] , "Definition List" =: T.unlines [ ": PLL" |