summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/cli.t15
1 files changed, 12 insertions, 3 deletions
diff --git a/test/cli.t b/test/cli.t
index 610ce5b..ef1243e 100644
--- a/test/cli.t
+++ b/test/cli.t
@@ -621,18 +621,27 @@ An unknown extension with no --flavour is an error, not a silent fallback:
$ printf 'x' > /tmp/t.wat
$ colitur table --year 2027 --template /tmp/t.wat
- colitur: cannot infer a flavour from ".wat"; pass --flavour latex|groff|html|xml|ics|none
+ colitur: cannot infer a flavour from ".wat"; pass --flavour latex|typst|groff|html|xml|ics|none
[2]
$ colitur table --year 2027 --template /tmp/t.wat --flavour none
x
-An unrecognised --flavour value is also an error naming the six valid ones:
+An unrecognised --flavour value is also an error naming the seven valid ones:
$ colitur table --year 2027 --template /tmp/t.txt --flavour bogus
- colitur: unknown flavour "bogus" (want latex, groff, html, xml, ics or none)
+ colitur: unknown flavour "bogus" (want latex, typst, groff, html, xml, ics or none)
[2]
+Typst is inferred from .typ, like every other flavour's own extension.
+Its metacharacters are escaped the same way latex's own is above -- here
+'-', verified live (against the real typst binary) to collapse into an
+en dash if left unescaped; a real shipped citation carries one:
+
+ $ printf '{{#days}}{{first}}\n{{/days}}' > /tmp/t.typ
+ $ colitur table --year 2027 --template /tmp/t.typ | grep -c '11\\-16'
+ 1
+
A malformed template is a clear error, not a crash:
$ printf '{{#days}}oops' > /tmp/bad.txt