MCPcopy
hub / github.com/grafana/dskit / newTestHTTPProvider

Function newTestHTTPProvider

runtimeconfig/provider_test.go:36–40  ·  view source on GitHub ↗
(t *testing.T, url string, client *http.Client)

Source from the content-addressed store, hash-verified

34}
35
36func newTestHTTPProvider(t *testing.T, url string, client *http.Client) (*httpProvider, *prometheus.Registry) {
37 reg := prometheus.NewPedanticRegistry()
38 dur := newHTTPRequestDuration(reg)
39 return newHTTPProvider(url, client, dur), reg
40}
41
42func TestHTTPProvider_Success(t *testing.T) {
43 body := "overrides:\n user1:\n limit1: 100\n"

Calls 2

newHTTPRequestDurationFunction · 0.85
newHTTPProviderFunction · 0.85

Tested by

no test coverage detected