0955f7cbd1
Deploy / deploy (push) Successful in 1m9s
Continues the full-year sanctoral import: the Guardian Angels (Duplex majus, full proper content), St. Thérèse of Lisieux, St. Bruno, St. Bridget of Sweden, St. Francis Borgia, the Maternity of the BVM (Duplex II Classis, instituted 1931 for the 1500th anniversary of the Council of Ephesus, full proper content), St. Edward the Confessor, St. Teresa of Avila (distinct from St. Thérèse of Lisieux -- two different Carmelite saints sharing a name), St. Margaret Mary Alacoque, St. Peter of Alcantara, St. John Cantius, and St. Raphael the Archangel (own full proper content, matching st-gabriel-archangel.yml's established pattern for a Sancti file that redirects wholesale to another date's file but still carries its own real content). St. Raphael's new fixed day (Oct 24, Duplex majus) collided with the "clean, empty Saturday" fixture used by three tests for Marian Saturday/Lauds-psalmody-override behavior; moved all three to 2026-07-04, verified genuinely free of any sanctoral entry (not even a commemorated Simplex). Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
75 lines
3.6 KiB
TypeScript
75 lines
3.6 KiB
TypeScript
import { describe, expect, it } from 'vitest';
|
|
import { resolveDay } from '../../src/calendar';
|
|
import { getDayLabel } from '../../src/calendar/day-label';
|
|
|
|
// Direct instruction: on a free Saturday, "Our Lady's Saturday" is really
|
|
// only a Simplex-strength standing — a Simplex saint alone loses to it
|
|
// and is commemorated instead; anything Semiduplex-or-higher, or a Vigil
|
|
// (which keeps forcing its own primacy the same way it does any other
|
|
// day), still wins outright and Marian Saturday doesn't apply at all.
|
|
describe('Marian Saturday (applyMarianSaturday)', () => {
|
|
it('wins outright, with no commemoration, on a Saturday with nothing else at all going on', () => {
|
|
// Not 2026-10-24: that date is now St. Raphael the Archangel's own
|
|
// fixed day (Duplex majus, added per the full-year sanctoral
|
|
// import), which wins outright. 2026-07-04 is a genuinely clean
|
|
// Saturday with no sanctoral entry at all (not even a commemorated
|
|
// Simplex).
|
|
const day = resolveDay('2026-07-04');
|
|
expect(day.winner).toEqual({ kind: 'temporal', id: 'marian-saturday' });
|
|
expect(day.commemorations).toEqual([]);
|
|
expect(getDayLabel(day)).toBe("Our Lady's Saturday");
|
|
});
|
|
|
|
it('wins over a Simplex saint, who is commemorated instead of winning outright', () => {
|
|
const day = resolveDay('2026-06-20'); // St. Silverius, Pope and Martyr, Simplex
|
|
expect(day.winner).toEqual({ kind: 'temporal', id: 'marian-saturday' });
|
|
expect(day.commemorations).toEqual([
|
|
{ kind: 'sanctoral', id: 'st-silverius', name: 'St. Silverius, Pope and Martyr', rank: 'simplex' },
|
|
]);
|
|
});
|
|
|
|
it('loses to a Vigil, which keeps forcing its own primacy on a Saturday same as any other day -- Marian Saturday does not apply', () => {
|
|
// 2025-11-29: Vigil of St. Andrew collides with St. Saturninus
|
|
// (Simplex) via calendar/collision.ts (Vigil outranks Simplex there)
|
|
// before Marian Saturday even gets a look-in -- Vigil wins outright,
|
|
// Saturninus is commemorated as the collision's loser, not by Marian
|
|
// Saturday's own demotion rule.
|
|
const day = resolveDay('2025-11-29');
|
|
expect(day.winner).toEqual({
|
|
kind: 'sanctoral',
|
|
id: 'vigil-of-st-andrew',
|
|
name: 'Vigil of St. Andrew',
|
|
rank: 'vigil',
|
|
});
|
|
expect(day.commemorations).toEqual([
|
|
{ kind: 'sanctoral', id: 'st-saturninus', name: 'St. Saturninus, Martyr', rank: 'simplex' },
|
|
]);
|
|
});
|
|
|
|
it('loses outright to a Semiduplex-or-higher saint -- Marian Saturday does not apply at all', () => {
|
|
const day = resolveDay('2026-09-19'); // St. Januarius, Semiduplex
|
|
expect(day.winner).toEqual({
|
|
kind: 'sanctoral',
|
|
id: 'st-januarius',
|
|
name: 'St. Januarius, Bishop, and Companions, Martyrs',
|
|
rank: 'semiduplex',
|
|
});
|
|
});
|
|
|
|
it('never applies to a Saturday with real standing of its own (privileged season, Ember days, ...)', () => {
|
|
const day = resolveDay('2026-02-28'); // Lenten Ember Saturday
|
|
expect(day.winner).not.toEqual({ kind: 'temporal', id: 'marian-saturday' });
|
|
expect(day.temporalCategory).toBe('privileged-feria');
|
|
});
|
|
|
|
it('never applies while an octave is active, even on an otherwise-eligible Saturday (Pentecost Ember Saturday stays governed by its octave)', () => {
|
|
const day = resolveDay('2026-05-30');
|
|
expect(day.winner).toEqual({ kind: 'temporal', id: 'pentecost-sunday' });
|
|
});
|
|
|
|
it('never applies on a weekday other than Saturday', () => {
|
|
const day = resolveDay('2026-10-23'); // the Friday before the clean Marian Saturday above
|
|
expect(day.winner).not.toEqual({ kind: 'temporal', id: 'marian-saturday' });
|
|
});
|
|
});
|