(t *testing.T, metric *prometheus.CounterVec, val string)
| 22 | } |
| 23 | |
| 24 | func getCounterValue(t *testing.T, metric *prometheus.CounterVec, val string) float64 { |
| 25 | var m = &dto.Metric{} |
| 26 | err := metric.WithLabelValues(val).Write(m) |
| 27 | assert.NoError(t, err) |
| 28 | return m.Counter.GetValue() |
| 29 | } |
| 30 | |
| 31 | func TestRegisterServerLocation(t *testing.T) { |
| 32 | m := newTunnelMetrics() |