Run scrape loop with interval 1 instead of 0

0 is considered an invalid interval by time.NewTicker() and will cause a
panic if control reaches that point. Given the vagaries of timekeeping,
this may occasionally happen and make this test unstable.
pull/1901/head
Anders Daljord Morken 10 years ago
parent fcac52ebbf
commit 95cadd0702
  1. 2
      retrieval/scrape_test.go

@ -329,7 +329,7 @@ func TestScrapeLoopStop(t *testing.T) {
runDone := make(chan struct{})
go func() {
sl.run(0, 0, nil)
sl.run(1, 0, nil)
close(runDone)
}()

Loading…
Cancel
Save