test(schedule): PR #177 second-pass P3 follow-ups (test gaps on reset transitions, controlled time, crash recovery) #213

Open
opened 2026-10-02 18:08:26 +00:00 by gabogg · 0 comments
Owner

Follow-up for PR #177 (next-day settings activation, #114) addressing second-pass review finding P3-17:

Scope

  1. Hand-built ResetSchedule: The 25h and 23h transition tests build ResetSchedule by hand rather than driving it through update_schedule_config_async and natural transition progression.
  2. Uncontrolled Clocks: Several tests use time.time() directly rather than fixed facility-time epochs.
  3. Untested Transition Scenarios: Add test coverage for a reset saved before today's reset, and a reset moved earlier through the real staging path.
  4. Outage and Crash Recovery: Add comprehensive test scenarios simulating application restarts and crashes across effective boundaries.
  5. UI Notices: Add end-to-end tests covering the bilingual pre-save confirmation text and post-save effective date/time/timezone notices.

Acceptance Criteria

  • Transition tests construct and test ResetSchedule via update_schedule_config_async rather than mocking internal dictionary structures.
  • All scheduled reset tests run against deterministic facility-time timestamps without depending on system wall-clock.
  • Explicit test coverage verifies advancing reset earlier and later with seamless single-transition cycles.
  • Automated tests verify daemon crash recovery across boundaries with exactly-once activation.
  • Tests verify presence and content of bilingual UI confirmation dialogs and effective notices.

Refs #177, #114.

Follow-up for PR #177 (next-day settings activation, #114) addressing second-pass review finding P3-17: ### Scope 1. **Hand-built ResetSchedule**: The 25h and 23h transition tests build ResetSchedule by hand rather than driving it through `update_schedule_config_async` and natural transition progression. 2. **Uncontrolled Clocks**: Several tests use `time.time()` directly rather than fixed facility-time epochs. 3. **Untested Transition Scenarios**: Add test coverage for a reset saved before today's reset, and a reset moved earlier through the real staging path. 4. **Outage and Crash Recovery**: Add comprehensive test scenarios simulating application restarts and crashes across effective boundaries. 5. **UI Notices**: Add end-to-end tests covering the bilingual pre-save confirmation text and post-save effective date/time/timezone notices. ### Acceptance Criteria - Transition tests construct and test `ResetSchedule` via `update_schedule_config_async` rather than mocking internal dictionary structures. - All scheduled reset tests run against deterministic facility-time timestamps without depending on system wall-clock. - Explicit test coverage verifies advancing reset earlier and later with seamless single-transition cycles. - Automated tests verify daemon crash recovery across boundaries with exactly-once activation. - Tests verify presence and content of bilingual UI confirmation dialogs and effective notices. Refs #177, #114.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gabogg/hikcentral#213
No description provided.