Skip to main content

max / ripgrow

pdf: extend e2e test to cover a mixed-kind session Phase 5b's PrescriptionParts::from_any already handled per-kind rendering; this widens the end-to-end test to exercise the full shape space in one PDF — freeweight (82.5 kg), bodyweight (BW), timed (1m30s), distance-seed (- / - / seed), and a name with escaped quotes. Verifies the template survives an empty UNIT column and a non-numeric LOAD cell.
Author: Max Johnson <me@maxj.phd> · 2026-07-18 20:31 UTC
Commit: 5a2701a60f42f999a83bea4ba8c9b5fbdee0e55d
Parent: 68f617e
1 file changed, +20 insertions, -0 deletions
@@ -482,6 +482,10 @@ mod tests {
482 482 eprintln!("skipping: typst not on PATH");
483 483 return;
484 484 }
485 + // Mixed-kind session: reps (freeweight + bodyweight), a timed
486 + // slot with duration in the load column, and a distance slot in
487 + // the seed-on-first-log state. Exercises the full PrescriptionParts
488 + // shape space through the template.
485 489 let s = SessionExport {
486 490 profile: "self".into(),
487 491 date: NaiveDate::from_ymd_opt(2026, 7, 18).unwrap(),
@@ -504,6 +508,22 @@ mod tests {
504 508 glyph: "flat".into(),
505 509 },
506 510 SlotExport {
511 + name: "plank".into(),
512 + sets: "3".into(),
513 + reps: "-".into(),
514 + load: "1m30s".into(),
515 + unit: "".into(),
516 + glyph: "up".into(),
517 + },
518 + SlotExport {
519 + name: "5k run".into(),
520 + sets: "-".into(),
521 + reps: "-".into(),
522 + load: "seed".into(),
523 + unit: "".into(),
524 + glyph: "".into(),
525 + },
526 + SlotExport {
507 527 name: "row \"paused\"".into(),
508 528 sets: "3".into(),
509 529 reps: "6".into(),