-
Notifications
You must be signed in to change notification settings - Fork 13k
Open
Labels
lang:goThe Go languageThe Go language
Description
Reference: golang/go#67434
In the cases where it is necessary for testing, historically (inside Google) gophers have been advised to pass around values such as func() time.Time
, or some similar fake-able clock, instead of calling time.Now()
. With synctest it seems like a new strategy is to simply rely on the new primitives rather than bothering with that plumbing.
Does the Google Go style guide have an opinion on this?
Metadata
Metadata
Assignees
Labels
lang:goThe Go languageThe Go language