aboutsummaryrefslogtreecommitdiff
path: root/test/Tests/Writers
diff options
context:
space:
mode:
Diffstat (limited to 'test/Tests/Writers')
-rw-r--r--test/Tests/Writers/HTML.hs4
-rw-r--r--test/Tests/Writers/Markdown.hs46
-rw-r--r--test/Tests/Writers/RST.hs2
3 files changed, 26 insertions, 26 deletions
diff --git a/test/Tests/Writers/HTML.hs b/test/Tests/Writers/HTML.hs
index f3c7b87fd..6ff0a6e1d 100644
--- a/test/Tests/Writers/HTML.hs
+++ b/test/Tests/Writers/HTML.hs
@@ -74,13 +74,13 @@ tests = [ testGroup "inline code"
, testGroup "sample with style"
[ "samp should wrap highlighted code" =:
codeWith ("",["sample","haskell"],[]) ">>="
- =?> ("<samp><code class=\"sourceCode haskell\">" ++
+ =?> ("<samp><code class=\"sourceCode haskell\">" ++
"<span class=\"op\">&gt;&gt;=</span></code></samp>")
]
, testGroup "variable with style"
[ "var should wrap highlighted code" =:
codeWith ("",["haskell","variable"],[]) ">>="
- =?> ("<var><code class=\"sourceCode haskell\">" ++
+ =?> ("<var><code class=\"sourceCode haskell\">" ++
"<span class=\"op\">&gt;&gt;=</span></code></var>")
]
]
diff --git a/test/Tests/Writers/Markdown.hs b/test/Tests/Writers/Markdown.hs
index aae4d082c..00f883ecb 100644
--- a/test/Tests/Writers/Markdown.hs
+++ b/test/Tests/Writers/Markdown.hs
@@ -93,7 +93,7 @@ noteTests = testGroup "note and reference location"
[ test (markdownWithOpts defopts)
"footnotes at the end of a document" $
noteTestDoc =?>
- (unlines [ "First Header"
+ unlines [ "First Header"
, "============"
, ""
, "This is a footnote.[^1] And this is a [link](https://www.google.com)."
@@ -110,11 +110,11 @@ noteTests = testGroup "note and reference location"
, "[^1]: Down here."
, ""
, "[^2]: The second note."
- ])
+ ]
, test (markdownWithOpts defopts{writerReferenceLocation=EndOfBlock})
"footnotes at the end of blocks" $
noteTestDoc =?>
- (unlines [ "First Header"
+ unlines [ "First Header"
, "============"
, ""
, "This is a footnote.[^1] And this is a [link](https://www.google.com)."
@@ -131,11 +131,11 @@ noteTests = testGroup "note and reference location"
, "============="
, ""
, "Some more text."
- ])
+ ]
, test (markdownWithOpts defopts{writerReferenceLocation=EndOfBlock, writerReferenceLinks=True})
"footnotes and reference links at the end of blocks" $
noteTestDoc =?>
- (unlines [ "First Header"
+ unlines [ "First Header"
, "============"
, ""
, "This is a footnote.[^1] And this is a [link]."
@@ -154,11 +154,11 @@ noteTests = testGroup "note and reference location"
, "============="
, ""
, "Some more text."
- ])
+ ]
, test (markdownWithOpts defopts{writerReferenceLocation=EndOfSection})
"footnotes at the end of section" $
noteTestDoc =?>
- (unlines [ "First Header"
+ unlines [ "First Header"
, "============"
, ""
, "This is a footnote.[^1] And this is a [link](https://www.google.com)."
@@ -175,7 +175,7 @@ noteTests = testGroup "note and reference location"
, "============="
, ""
, "Some more text."
- ])
+ ]
]
@@ -191,24 +191,24 @@ shortcutLinkRefsTests =
=: para (link "/url" "title" "foo")
=?> "[foo]\n\n [foo]: /url \"title\""
, "Followed by another link (unshortcutable)"
- =: para ((link "/url1" "title1" "first")
- <> (link "/url2" "title2" "second"))
+ =: para (link "/url1" "title1" "first"
+ <> link "/url2" "title2" "second")
=?> unlines [ "[first][][second]"
, ""
, " [first]: /url1 \"title1\""
, " [second]: /url2 \"title2\""
]
, "Followed by space and another link (unshortcutable)"
- =: para ((link "/url1" "title1" "first") <> " "
- <> (link "/url2" "title2" "second"))
+ =: para (link "/url1" "title1" "first" <> " "
+ <> link "/url2" "title2" "second")
=?> unlines [ "[first][] [second]"
, ""
, " [first]: /url1 \"title1\""
, " [second]: /url2 \"title2\""
]
, "Reference link is used multiple times (unshortcutable)"
- =: para ((link "/url1" "" "foo") <> (link "/url2" "" "foo")
- <> (link "/url3" "" "foo"))
+ =: para (link "/url1" "" "foo" <> link "/url2" "" "foo"
+ <> link "/url3" "" "foo")
=?> unlines [ "[foo][][foo][1][foo][2]"
, ""
, " [foo]: /url1"
@@ -216,8 +216,8 @@ shortcutLinkRefsTests =
, " [2]: /url3"
]
, "Reference link is used multiple times (unshortcutable)"
- =: para ((link "/url1" "" "foo") <> " " <> (link "/url2" "" "foo")
- <> " " <> (link "/url3" "" "foo"))
+ =: para (link "/url1" "" "foo" <> " " <> link "/url2" "" "foo"
+ <> " " <> link "/url3" "" "foo")
=?> unlines [ "[foo][] [foo][1] [foo][2]"
, ""
, " [foo]: /url1"
@@ -225,43 +225,43 @@ shortcutLinkRefsTests =
, " [2]: /url3"
]
, "Reference link is followed by text in brackets"
- =: para ((link "/url" "" "link") <> "[text in brackets]")
+ =: para (link "/url" "" "link" <> "[text in brackets]")
=?> unlines [ "[link][]\\[text in brackets\\]"
, ""
, " [link]: /url"
]
, "Reference link is followed by space and text in brackets"
- =: para ((link "/url" "" "link") <> " [text in brackets]")
+ =: para (link "/url" "" "link" <> " [text in brackets]")
=?> unlines [ "[link][] \\[text in brackets\\]"
, ""
, " [link]: /url"
]
, "Reference link is followed by RawInline"
- =: para ((link "/url" "" "link") <> rawInline "markdown" "[rawText]")
+ =: para (link "/url" "" "link" <> rawInline "markdown" "[rawText]")
=?> unlines [ "[link][][rawText]"
, ""
, " [link]: /url"
]
, "Reference link is followed by space and RawInline"
- =: para ((link "/url" "" "link") <> space <> rawInline "markdown" "[rawText]")
+ =: para (link "/url" "" "link" <> space <> rawInline "markdown" "[rawText]")
=?> unlines [ "[link][] [rawText]"
, ""
, " [link]: /url"
]
, "Reference link is followed by RawInline with space"
- =: para ((link "/url" "" "link") <> rawInline "markdown" " [rawText]")
+ =: para (link "/url" "" "link" <> rawInline "markdown" " [rawText]")
=?> unlines [ "[link][] [rawText]"
, ""
, " [link]: /url"
]
, "Reference link is followed by citation"
- =: para ((link "/url" "" "link") <> cite [Citation "author" [] [] NormalCitation 0 0] (str "[@author]"))
+ =: para (link "/url" "" "link" <> cite [Citation "author" [] [] NormalCitation 0 0] (str "[@author]"))
=?> unlines [ "[link][][@author]"
, ""
, " [link]: /url"
]
, "Reference link is followed by space and citation"
- =: para ((link "/url" "" "link") <> space <> cite [Citation "author" [] [] NormalCitation 0 0] (str "[@author]"))
+ =: para (link "/url" "" "link" <> space <> cite [Citation "author" [] [] NormalCitation 0 0] (str "[@author]"))
=?> unlines [ "[link][] [@author]"
, ""
, " [link]: /url"
diff --git a/test/Tests/Writers/RST.hs b/test/Tests/Writers/RST.hs
index e6377c02f..a52423fad 100644
--- a/test/Tests/Writers/RST.hs
+++ b/test/Tests/Writers/RST.hs
@@ -175,6 +175,6 @@ tests = [ testGroup "rubrics"
, "--------"]
]
, testTemplate "$subtitle$\n" "subtitle" $
- (setMeta "subtitle" ("subtitle" :: Inlines) $ doc $ plain "") =?>
+ setMeta "subtitle" ("subtitle" :: Inlines) (doc $ plain "") =?>
("subtitle" :: String)
]