Closed dghubble closed 8 years ago
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
:+1:
Fixed in c30457ecaf841a445abbaf6a184400abb4741bb8
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.