-
Notifications
You must be signed in to change notification settings - Fork 128
Open
Labels
breaking changeThis could break existing codeThis could break existing codetimezoneThe model and API of timezonesThe model and API of timezones
Milestone
Description
Following on from the Instant.now() static dependency on the system clock, TimeZone.SYSTEM has a similar static dependency on the system.
Would it make sense to put this as an instance member on Clock as well? That's how (one of) our clock abstractions exposes it.
Without this you'll have the ability to control time in places like tests. Anyone calling into TimeZone.SYSTEM and combining it with an instant from a fake clock will produce a time in the hosts zone rather than a stable zone likely producing flaky tests.
LeoColman, aartikov, axelfontaine, Jadarma, kevincianfarini and 5 more
Metadata
Metadata
Assignees
Labels
breaking changeThis could break existing codeThis could break existing codetimezoneThe model and API of timezonesThe model and API of timezones