Fake Clock
open class FakeClock @JvmOverloads constructor(epochMillis: Long = Instant.parse("2018-01-01T00:00:00Z").toEpochMilli(), zone: ZoneId = ZoneId.of("UTC")) : Clock
Controllable clock for testing.
Constructors
Functions
Link copied to clipboard
Advance the clock by specified Duration.
Advance the clock by the specified Period. Note that unlike adding a Duration the exact amount that is added to the clock will depend on its current time and timezone. Not all days, months or years have the same length. See the documentation for Period.
Advance the clock by specified amount n of TimeUnit.