diff options
| author | Lukasz Kasprzak <lukas@labunix.xyz> | 2026-08-19 23:48:35 +0200 |
|---|---|---|
| committer | Lukasz Kasprzak <lukas@labunix.xyz> | 2026-08-19 23:48:35 +0200 |
| commit | ecadd969e1d96918820a1fdac0cf0d520d96ba06 (patch) | |
| tree | a06ed1160bfd28ae4578d9445242e48ac9ac3ea4 /test/test_emit.ml | |
| parent | 6762ce46af3cb12bc6ae37cda762c5d95add7903 (diff) | |
| parent | 329d07b49e397cb65ab52e7ca019b47313027136 (diff) | |
| download | colitur-ecadd969e1d96918820a1fdac0cf0d520d96ba06.tar.gz colitur-ecadd969e1d96918820a1fdac0cf0d520d96ba06.zip | |
feat: naming, localisation and the rebuilt printed output
colitur computed the calendar correctly and could not say what it had
computed. A printed ordo read ef-septuagesima-sunday-2 where a reader
expects Dominica in Sexagesima, and the wall calendar showed slugs in
every cell.
lib/naming a language table and a config file, both pure and total,
parsing the INI reader Overlay_ini already had
lang/ la.ini and en.ini -- 725 names, every one transcribed
from the 1962 Missal and citing the line it came from
templates the ordo rebuilt as an A5 booklet: one week per page, a
table of contents, framed days, a colour swatch; the wall
calendar now fills its sheet instead of a quarter of it
tools check_citations.py verifies all 400 citations resolve,
with 33 self-tests of its own
Names resolve through lang -> declared fallback -> the slug, so a partial
translation is usable from its first line and the fully degraded case is
the old output rather than a blank page.
colitur day and colitur readings are BYTE-IDENTICAL to before, verified
against main rather than asserted; --lang, --raw and the lang/config
subcommands are still to come, and man/colitur-templates.5 still
documents the pre-naming view, so writing a custom template needs the
source until that lands.
Diffstat (limited to 'test/test_emit.ml')
| -rw-r--r-- | test/test_emit.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test_emit.ml b/test/test_emit.ml index a22eaaf..0a40054 100644 --- a/test/test_emit.ml +++ b/test/test_emit.ml @@ -61,7 +61,7 @@ let test_csv_header_and_rows () = let lines = String.split_on_char '\n' out |> List.filter (fun l -> l <> "") in Alcotest.(check int) "366 lines: header + 365 days" 366 (List.length lines); Alcotest.(check string) "header" - "date,rite,season,week,slug,rank,colour,subject,name_la,name_en,first,gospel,comms" + "date,rite,season,season_name,week,slug,name,weekday,rank,rank_name,colour,colour_name,subject,first,gospel,comms" (List.hd lines); Alcotest.(check bool) "first row is 1 January" true (String.length (List.nth lines 1) > 10 && String.sub (List.nth lines 1) 0 10 = "2027-01-01") @@ -86,8 +86,8 @@ let test_csv_quotes_commas () = that escapes its quoting produces 14 fields, not 13. Also assert the quoted substring appears literally, byte for byte -- belt and braces, and closer to what a human reviewing the CSV would actually look for. *) - Alcotest.(check int) "the row has exactly 13 fields, same as the header" - 13 (List.length (parse_csv_row joseph)); + Alcotest.(check int) "the row has exactly 16 fields, same as the header" + 16 (List.length (parse_csv_row joseph)); Alcotest.(check bool) "Joseph's comma-bearing name is quoted whole, not split" true (contains ~needle:"\"St. Joseph, Spouse of the Bl. Virgin Mary\"" joseph) |
