Closed kimata closed 3 months ago
Note that up until version 1.2.1, I could force the test to pass by modifying freeze_time as shown below. However, since version 1.2.2, it takes time zones into consideration, so it is no longer possible to pass the test.
freeze_time = datetime.datetime.now(tz=datetime.timezone(datetime.timedelta(hours=9))).replace(
hour=0, minute=0, second=0
) + datetime.timedelta(hours=+9)
It may be problem of schedule. So, I close this issue.
To test the code that uses schedule, I ran the following test code in combination with freezegun, but the test failed.
The output when running the test is as follows.
pytest-freezegun appears to be freezing the time as intended. What could be the issue?