MCPcopy Index your code
hub / github.com/coder/coder / PromCounterHasValue

Function PromCounterHasValue

testutil/prometheus.go:22–25  ·  view source on GitHub ↗
(t testing.TB, metrics []*dto.MetricFamily, value float64, name string, labels ...string)

Source from the content-addressed store, hash-verified

20}
21
22func PromCounterHasValue(t testing.TB, metrics []*dto.MetricFamily, value float64, name string, labels ...string) bool {
23 t.Helper()
24 return value == getValue(t, metrics, counterKind, name, labels...)
25}
26
27func PromGaugeAssertion(t testing.TB, metrics []*dto.MetricFamily, assert func(in float64) bool, name string, labels ...string) bool {
28 t.Helper()

Callers 3

TestPGPubsub_MetricsFunction · 0.92
TestProxy_MITMFunction · 0.92

Calls 2

getValueFunction · 0.85
HelperMethod · 0.65

Tested by 3

TestPGPubsub_MetricsFunction · 0.74
TestProxy_MITMFunction · 0.74