FA-77075 / Calendar recurrence rules / Member archive
Occurrence test and next-occurrence lookup for an anchored N-weekly series: before anchor · case 05
A query on the anchor date returns the anchor as the next occurrence instead of the following one.
Case contract
A series occurs every interval_weeks weeks starting at anchor, for count occurrences. For a query date return [is_occurrence, next occurrence strictly after the query or None, 0-based index of that next occurrence or None]. Dates before the anchor are never occurrences; the next occurrence after a query before the anchor is the anchor itself.
Why this case matters
Recurring calendar series are expanded into concrete instances for display, reminders and conflict checks.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| query on anchor | [true, "2024-01-05", 0] | [true, "2024-01-19", 1] | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗