ScheduledExecutorService implementation designed for deterministic testing. It runs off an
internal clock which must be manually advanced via the ClockedExecutorService#advance
method.
Additionally, for recurring scheduled tasks, there is a guarantee that the task will only
be called once for each call to advance(...)
. This is important to note as it
rather violates the normal contracts, but is very useful for testing.
See this example.