pkg/naming: fix unit test

This commit is contained in:
paulfantom 2019-05-17 14:36:02 +02:00
parent 99d52a4ce8
commit 2374cef641
No known key found for this signature in database
GPG key ID: 12AE0185401674E7

View file

@ -341,17 +341,16 @@ func TestBuildExternalSelector(t *testing.T) {
),
},
{
name: "multiple LabelValuesByName",
name: "single LabelValuesByName with multiple selectors",
mq: mustNewQuery(`<<.LabelValuesByName>>`, false),
metricSelector: labels.NewSelector().Add(
*mustNewLabelRequirement("foo", selection.Equals, []string{"bar"}),
*mustNewLabelRequirement("qux", selection.In, []string{"bar", "baz"}),
*mustNewLabelRequirement("foo", selection.In, []string{"bar", "baz"}),
),
check: checks(
hasError(nil),
hasSelector("map[foo:bar qux:bar|baz]"),
hasSelector("map[foo:bar|baz]"),
),
},
}