You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using Sleep for the name incorrectly implies that this function exists to satisfy the Sleeper interface. In fact, the receiver function can use any valid function name. The only requirement is the function's signature matches that of ConfigurableSleeper's sleep member, i.e func(time.Duration).
Why SetDurationSlept
SetDurationSlept accurately describes what the function does. That is SpyTime.SetDurationSlept(5*t.Seconds) sets SpyTime's durationSlept member to 5 seconds.
I will open a PR if the maintainer(s) is(are) interested.
The text was updated successfully, but these errors were encountered:
Reason for Change
Using
Sleep
for the name incorrectly implies that this function exists to satisfy theSleeper
interface. In fact, the receiver function can use any valid function name. The only requirement is the function's signature matches that of ConfigurableSleeper'ssleep
member, i.efunc(time.Duration)
.Why SetDurationSlept
SetDurationSlept accurately describes what the function does. That is SpyTime.SetDurationSlept(5*t.Seconds) sets SpyTime's durationSlept member to 5 seconds.
I will open a PR if the maintainer(s) is(are) interested.
The text was updated successfully, but these errors were encountered: