Closed
Description
When using hypothesis with the mock_clock
fixture, I sometime end up with a raise ValueError("time can't go backwards")
The thing is we have MockClock._autojumper
doing this:
trio/trio/testing/_mock_clock.py
Lines 149 to 152 in 4512ae3
However according to current_statisticts
documentation:
Lines 1143 to 1146 in 4512ae3
I guess _autojumper
should be corrected to do something like this:
statistics = _core.current_statistics()
jump = statistics.seconds_to_next_deadline
if 0 < jump < inf:
self.jump(jump)
What do you think ?
Metadata
Metadata
Assignees
Labels
No labels