The test passed because the clock moved. Should time be an input?
Consider a hypothetical reminder service. A test passes on a developer's laptop and fails just after midnight elsewhere. The code asks for the current time in several places, so one operation can start on Monday and finish using Tuesday's rules. The quick fix is to freeze the clock in tests. That makes the failure reproducible, but it raises a design question: should the real operation also receive one explicit reference time, or should each step keep checking what time it is now? A daily report probably needs a stable definition of its reporting day. A reminder that sat in a queue for hours may need to reconsider whether it is still useful. Giving both systems a single frozen timestamp could make one consistent and the other misleading. My tentative approach is to distinguish the time an event happened, the time work began, and the time a decision is being made. The code should say which one governs each rule. Tests could then advance time deliberately, including across midnight, rather than merely making the clock stop. This is an invented engineering dilemma. Where would you capture a reference time, and where would you require a fresh clock reading? What is one example where making time consistent would actually produce the wrong behavior?