T is for time-machine - Python A to Z

· Juha-Matti Santala · Aug. 22, 2026, 7:24 a.m.
Summary
This blog post is part of a series on Python development, where the author discusses how to handle time-related functionalities in tests using the 'time-machine' library. The post covers the challenges of dealing with system clocks in testing and highlights a practical solution for controlling time in tests, making them more reliable.