aboutsummaryrefslogtreecommitdiff
path: root/test/test_lang_coverage.ml
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_lang_coverage.ml')
-rw-r--r--test/test_lang_coverage.ml13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/test_lang_coverage.ml b/test/test_lang_coverage.ml
index 34758b2..9ed633c 100644
--- a/test/test_lang_coverage.ml
+++ b/test/test_lang_coverage.ml
@@ -80,6 +80,18 @@ let test_vocabularies_are_complete () =
if L.month t n = string_of_int n then Alcotest.failf "no Latin month for %d" n
done
+(* Defect 1: the booklet used to print the bare rite id ("ef") because no
+ [rite] section existed in either language file. Walks every rite id the
+ engine can actually emit -- one today (Rite_ef.Temporal_ef.id, the same
+ id `Rite_ef.context` stamps onto every Rite.t.id -- see rite_ef.ml) -- so
+ this is cheap now and fails loudly the moment a second rite module (OF)
+ is wired in without a matching [rite] entry in la.ini. *)
+let test_every_rite_has_a_latin_name () =
+ let t = la () in
+ List.iter
+ (fun id -> if L.rite t id = id then Alcotest.failf "no Latin display name for rite %S" id)
+ [ Rite_ef.Temporal_ef.id ]
+
(* lang/en.ini is DELIBERATELY partial (see its own header note): it declares
[meta] fallback = la, so a slug it does not carry itself should still
resolve through the chain to la.ini's name rather than degrade to the bare
@@ -120,4 +132,5 @@ let suite =
( "Lang/coverage",
[ Alcotest.test_case "every slug has a Latin name" `Slow test_every_slug_has_a_latin_name;
Alcotest.test_case "vocabularies complete" `Quick test_vocabularies_are_complete;
+ Alcotest.test_case "every rite has a Latin name" `Quick test_every_rite_has_a_latin_name;
Alcotest.test_case "en.ini falls back to Latin" `Quick test_en_falls_back_to_latin ] )