mirror of
https://github.com/prometheus/prometheus.git
synced 2025-03-05 20:59:13 -08:00
fix(test): if we are dereferencing a slice we should check its len
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
This commit is contained in:
parent
8f572fe905
commit
07276aeece
|
@ -631,6 +631,7 @@ func TestPartialTruncateWAL(t *testing.T) {
|
|||
s.truncate(lastTs - 1)
|
||||
|
||||
m := gatherFamily(t, reg, "prometheus_agent_deleted_series")
|
||||
require.Len(t, m.Metric, 1)
|
||||
require.Equal(t, float64(numSeries*5), m.Metric[0].Gauge.GetValue(), "agent wal truncate mismatch of deleted series count")
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue