diff --git a/lib/prom/prom_test.go b/lib/prom/prom_test.go index 4c07a8cb..71bdb3d3 100644 --- a/lib/prom/prom_test.go +++ b/lib/prom/prom_test.go @@ -79,9 +79,7 @@ func TestMetrics_Observe(t *testing.T) { name, _ := p.Help() nameStr := string(name) - if _, ok := want[nameStr]; ok { - delete(want, nameStr) - } + delete(want, nameStr) } if len(want) > 0 {