summaryrefslogtreecommitdiff
path: root/tests/Tests/Readers/Org.hs
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2014-05-28 09:26:48 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2014-05-28 09:26:48 -0700
commite656658af8b833c589f4dda90dac3d09d73cd81f (patch)
tree60611cd5510fc7679f445fbe72d4c4724465ca28 /tests/Tests/Readers/Org.hs
parente3ddc371dee9630dae71d61a69088b06cea8e909 (diff)
parent3238a2f9191b83864abd682261634a603ec89056 (diff)
Merge pull request #1302 from tarleb/inline-latex
Org reader: support for inline LaTeX
Diffstat (limited to 'tests/Tests/Readers/Org.hs')
-rw-r--r--tests/Tests/Readers/Org.hs27
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/Tests/Readers/Org.hs b/tests/Tests/Readers/Org.hs
index ca97ba348..4ed77887f 100644
--- a/tests/Tests/Readers/Org.hs
+++ b/tests/Tests/Readers/Org.hs
@@ -247,6 +247,33 @@ tests =
, citationNoteNum = 0
, citationHash = 0}
in (para $ cite [citation] "[see @item1 p. 34-35]")
+
+ , "Inline LaTeX symbol" =:
+ "\\dots" =?>
+ para "…"
+
+ , "Inline LaTeX command" =:
+ "\\textit{Emphasised}" =?>
+ para (emph "Emphasised")
+
+ , "Inline LaTeX math symbol" =:
+ "\\tau" =?>
+ para (emph "τ")
+
+ , "Unknown inline LaTeX command" =:
+ "\\notacommand{foo}" =?>
+ para (rawInline "latex" "\\notacommand{foo}")
+
+ , "LaTeX citation" =:
+ "\\cite{Coffee}" =?>
+ let citation = Citation
+ { citationId = "Coffee"
+ , citationPrefix = []
+ , citationSuffix = []
+ , citationMode = AuthorInText
+ , citationNoteNum = 0
+ , citationHash = 0}
+ in (para . cite [citation] $ rawInline "latex" "\\cite{Coffee}")
]
, testGroup "Meta Information" $