Set NewFakeClock initial time
dghubble opened this issue · comments
Using NewFakeClock() to make a Clock at a specific point in time requires a custom implementation (since fakeClock is internal) or calling Advance while depending on the internal detail that the clock starts in 1900. Is this within the desired project scope?
I previously considered this package for some testing which depended on a specific timestamp for validations.
Certainly open to this, just hadn't wanted to clutter up the interfaces. Any suggestions for a name? NewFakeClockAt(time.Time)
or something?
NewFakeClockAt
sounds great and it matches the signature I was using to create a Clock
👍
Fixed in c30457e