Skip to main content

Module time

Module time 

Source
Expand description

Virtual time, which never mixes with the real clock.

A VirtualInstant is an offset from the moment a harness booted, so it prints the same on every run. There is no way to make one from std::time::Instant and no now(): only the harness hands them out. A VirtualDuration converts from std::time::Duration, because a duration belongs to no clock.

Structs§

VirtualDuration
A span of virtual time.
VirtualInstant
An instant on the harness’s virtual clock.