1
0
mirror of https://github.com/go-kit/kit.git synced 2025-07-15 01:04:44 +02:00

Changes as per code review

This commit is contained in:
esenac
2017-09-15 22:17:02 +02:00
parent 4e222a33e0
commit 0b39753a72
2 changed files with 2 additions and 2 deletions

View File

@ -29,7 +29,8 @@ func (t *Timer) ObserveDuration() {
t.h.Observe(d)
}
// Unit sets the timer time unit
// Unit sets the unit of the float64 emitted by the timer.
// By default, the timer emits seconds.
func (t *Timer) Unit(u time.Duration) {
t.u = u
}

View File

@ -33,7 +33,6 @@ func TestTimerSlow(t *testing.T) {
}
func TestTimerUnit(t *testing.T) {
for _, tc := range []struct {
name string
unit time.Duration