aboutsummaryrefslogtreecommitdiff
path: root/tests/Tests/Readers/Org.hs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Tests/Readers/Org.hs')
-rw-r--r--tests/Tests/Readers/Org.hs25
1 files changed, 25 insertions, 0 deletions
diff --git a/tests/Tests/Readers/Org.hs b/tests/Tests/Readers/Org.hs
index 49130f0ab..f39bd7992 100644
--- a/tests/Tests/Readers/Org.hs
+++ b/tests/Tests/Readers/Org.hs
@@ -94,6 +94,10 @@ tests =
"a_{n+1}" =?>
para (str "a" <> subscript "n+1")
+ , "Linebreak" =:
+ "line \\\\ \nbreak" =?>
+ para ("line" <> linebreak <> "break")
+
, "Markup-chars not occuring on word break are symbols" =:
unlines [ "this+that+ +so+on"
, "seven*eight* nine*"
@@ -377,6 +381,27 @@ tests =
code' = "main = putStrLn greeting\n" ++
" where greeting = \"moin\"\n"
in codeBlockWith attr' code'
+
+ , "Figure" =:
+ unlines [ "#+caption: A very courageous man."
+ , "#+name: goodguy"
+ , "[[edward.jpg]]"
+ ] =?>
+ para (image "edward.jpg" "fig:goodguy" "A very courageous man.")
+
+ , "Unnamed figure" =:
+ unlines [ "#+caption: A great whistleblower."
+ , "[[snowden.png]]"
+ ] =?>
+ para (image "snowden.png" "" "A great whistleblower.")
+
+ , "Figure with `fig:` prefix in name" =:
+ unlines [ "#+caption: Used as a metapher in evolutionary biology."
+ , "#+name: fig:redqueen"
+ , "[[the-red-queen.jpg]]"
+ ] =?>
+ para (image "the-red-queen.jpg" "fig:redqueen"
+ "Used as a metapher in evolutionary biology.")
]
, testGroup "Lists" $