From a05fe44ad677ab476b9517e2807ea2ee9f01dfd1 Mon Sep 17 00:00:00 2001 From: Peter Bourgon Date: Tue, 6 Nov 2018 12:46:41 -0800 Subject: [PATCH] The error message changed --- metrics/prometheus/prometheus_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/metrics/prometheus/prometheus_test.go b/metrics/prometheus/prometheus_test.go index 9f7bf9b10..2a921bd64 100644 --- a/metrics/prometheus/prometheus_test.go +++ b/metrics/prometheus/prometheus_test.go @@ -12,9 +12,8 @@ import ( "strings" "testing" - stdprometheus "github.com/prometheus/client_golang/prometheus" - "github.com/go-kit/kit/metrics/teststat" + stdprometheus "github.com/prometheus/client_golang/prometheus" ) func TestCounter(t *testing.T) { @@ -198,7 +197,7 @@ func TestInconsistentLabelCardinality(t *testing.T) { if !ok { t.Fatalf("expected error, got %s", reflect.TypeOf(x)) } - if want, have := "inconsistent label cardinality", err.Error(); want != have { + if want, have := "inconsistent label cardinality", err.Error(); !strings.HasPrefix(have, want) { t.Fatalf("want %q, have %q", want, have) } }()