metrics: fix out of range error message (#29821)

pull/29826/head^2
Halimao 4 months ago committed by GitHub
parent b779e469da
commit 70bee977d6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 4
      metrics/sample_test.go

@ -114,7 +114,7 @@ func TestExpDecaySample(t *testing.T) {
} }
for _, v := range values { for _, v := range values {
if v > int64(tc.updates) || v < 0 { if v > int64(tc.updates) || v < 0 {
t.Errorf("out of range [0, %d): %v", tc.updates, v) t.Errorf("out of range [0, %d]: %v", tc.updates, v)
} }
} }
} }
@ -195,7 +195,7 @@ func TestUniformSample(t *testing.T) {
} }
for _, v := range values { for _, v := range values {
if v > 1000 || v < 0 { if v > 1000 || v < 0 {
t.Errorf("out of range [0, 100): %v\n", v) t.Errorf("out of range [0, 1000]: %v\n", v)
} }
} }
} }

Loading…
Cancel
Save