prometheus/discovery/kubernetes
Mateusz Gozdek ea924746b3
discovery/kubernetes: improve test logic for waiting for discoverers (#9584)
When running tests in parallel, 10 milliseconds may not be enough for
all discoverers to register, which will make test flaky.

This commit changes the waiting logic to wait for number of discoverers
to stop increasing during given time frame, which should be large enough
for single discoverer to register in test environment.

A following run passes with this commit:

go test -failfast -race -count 100 -v ./discovery/kubernetes/

Signed-off-by: Mateusz Gozdek <mgozdekof@gmail.com>
2021-11-02 22:17:32 +01:00
..
client_metrics.go Format Go source files using 'gofumpt -w -s -extra' 2021-11-02 19:52:34 +01:00
endpoints.go Fix imports formatting 2021-11-02 19:52:34 +01:00
endpoints_test.go Format Go source files using 'gofumpt -w -s -extra' 2021-11-02 19:52:34 +01:00
endpointslice.go discovery/kubernetes: issue overcapacity warning for endpoint rather than endpointslice 2021-10-08 23:17:04 +03:00
endpointslice_test.go Move away from testutil, refactor imports (#8087) 2020-10-22 11:00:08 +02:00
ingress.go kubernetes ingress: adjust comment style 2021-08-30 22:34:24 +02:00
ingress_adaptor.go Kubernetes SD: Fix golint issue 2021-08-24 17:30:33 +09:00
ingress_test.go kubernetes ingress: adjust comment style 2021-08-30 22:34:24 +02:00
kubernetes.go Enable HTTP2 again (#9398) 2021-09-26 23:16:12 +02:00
kubernetes_test.go discovery/kubernetes: improve test logic for waiting for discoverers (#9584) 2021-11-02 22:17:32 +01:00
node.go Switched to go-kit/log 2021-06-11 12:28:36 -04:00
node_test.go Format Go source files using 'gofumpt -w -s -extra' 2021-11-02 19:52:34 +01:00
pod.go Switched to go-kit/log 2021-06-11 12:28:36 -04:00
pod_test.go update kubernetes to v1.18.x and update ingress apiVersion 2020-06-01 08:26:50 -07:00
service.go Switched to go-kit/log 2021-06-11 12:28:36 -04:00
service_test.go update kubernetes to v1.18.x and update ingress apiVersion 2020-06-01 08:26:50 -07:00