summaryrefslogtreecommitdiff
path: root/test/test_colitur.ml
diff options
context:
space:
mode:
authorLukasz Kasprzak <lukas@labunix.xyz>2026-08-19 08:17:30 +0200
committerLukasz Kasprzak <lukas@labunix.xyz>2026-08-19 08:17:30 +0200
commitda9cf402ceed8102aec1a9d008f8e918a23d39f3 (patch)
tree3c9a7bd748f886633117cce7059ba304c23541cb /test/test_colitur.ml
parenta526d934cea17ff1b76ddad5c5f2934fb85c11cb (diff)
downloadcolitur-da9cf402ceed8102aec1a9d008f8e918a23d39f3.tar.gz
colitur-da9cf402ceed8102aec1a9d008f8e918a23d39f3.zip
feat(render): template renderer with mandatory escaping
Every interpolated value is escaped for the template's flavour; the template's own literal text never is, because that is the author's markup. There is no raw form, so a template cannot opt out. Scope is a stack with outward fallback, so a grid template can reach the year number from inside a week without the view duplicating it into every cell. A missing key renders empty -- the one deliberate silence, so a template survives a rite that does not set every optional field. Mutation-tested: dropping the Escape.apply call reddens the data-cannot-escape-flavour case.
Diffstat (limited to 'test/test_colitur.ml')
-rw-r--r--test/test_colitur.ml3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/test_colitur.ml b/test/test_colitur.ml
index a264174..f12dab5 100644
--- a/test/test_colitur.ml
+++ b/test/test_colitur.ml
@@ -8,4 +8,5 @@ let () =
("lectionary", Test_lectionary.suite);
("lectionary-ef", Test_lectionary_ef.suite);
Test_escape.suite;
- Test_template.suite ]
+ Test_template.suite;
+ Test_template.render_suite ]