mirror of
https://github.com/prometheus/prometheus.git
synced 2025-08-05 13:47:10 +02:00
Fix flaky scrape test
t
This commit is contained in:
parent
eebe077f98
commit
895f2f092f
@ -19,6 +19,7 @@ import (
|
||||
"net/http/httptest"
|
||||
"net/url"
|
||||
"reflect"
|
||||
"sort"
|
||||
"strings"
|
||||
"sync"
|
||||
"testing"
|
||||
@ -469,6 +470,8 @@ func TestTargetScraperScrapeOK(t *testing.T) {
|
||||
Value: 2,
|
||||
},
|
||||
}
|
||||
sort.Sort(expectedSamples)
|
||||
sort.Sort(samples)
|
||||
|
||||
if !reflect.DeepEqual(samples, expectedSamples) {
|
||||
t.Errorf("Scraped samples did not match served metrics")
|
||||
|
Loading…
Reference in New Issue
Block a user