diff options
Diffstat (limited to 'test/Tests')
-rw-r--r-- | test/Tests/Writers/Jira.hs | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/test/Tests/Writers/Jira.hs b/test/Tests/Writers/Jira.hs new file mode 100644 index 000000000..063497fd1 --- /dev/null +++ b/test/Tests/Writers/Jira.hs @@ -0,0 +1,27 @@ +{-# LANGUAGE OverloadedStrings #-} +module Tests.Writers.Jira (tests) where + +import Data.Text (unpack) +import Test.Tasty +import Tests.Helpers +import Text.Pandoc +import Text.Pandoc.Arbitrary () +import Text.Pandoc.Builder + +jira :: (ToPandoc a) => a -> String +jira = unpack . purely (writeJira def) . toPandoc + +infix 4 =: +(=:) :: (ToString a, ToPandoc a) + => String -> (a, String) -> TestTree +(=:) = test jira + +tests :: [TestTree] +tests = + [ testGroup "inlines" + [ "underlined text" =: + spanWith ("ignored", ["ignored", "underline"], [("foo", "bar")]) + "underlined text" =?> + "+underlined text+" + ] + ] |