From 454ba12676d1b49bec86658c97d41c952d2a9a3f Mon Sep 17 00:00:00 2001 From: Tobias Guggenmos Date: Mon, 3 Feb 2020 19:09:10 +0100 Subject: [PATCH] Fix build errors in promtool Signed-off-by: Tobias Guggenmos --- cmd/promtool/unittest.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/promtool/unittest.go b/cmd/promtool/unittest.go index 9f5ac09cc..c64b33acc 100644 --- a/cmd/promtool/unittest.go +++ b/cmd/promtool/unittest.go @@ -31,6 +31,7 @@ import ( "github.com/prometheus/prometheus/pkg/labels" "github.com/prometheus/prometheus/promql" + "github.com/prometheus/prometheus/promql/parser" "github.com/prometheus/prometheus/rules" "github.com/prometheus/prometheus/storage" ) @@ -339,7 +340,7 @@ Outer: var expSamples []parsedSample for _, s := range testCase.ExpSamples { - lb, err := promql.ParseMetric(s.Labels) + lb, err := parser.ParseMetric(s.Labels) if err != nil { err = errors.Wrapf(err, "labels %q", s.Labels) errs = append(errs, errors.Errorf(" expr: %q, time: %s, err: %s", testCase.Expr,