promql/tests: couple more labels.FromStrings

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
This commit is contained in:
Bryan Boreham 2022-10-27 18:29:01 +01:00
parent 8a7ef4cfac
commit 0679437825

View file

@ -3114,17 +3114,11 @@ func TestRangeQuery(t *testing.T) {
Result: Matrix{ Result: Matrix{
Series{ Series{
Points: []Point{{V: 1, T: 0}, {V: 3, T: 60000}, {V: 5, T: 120000}}, Points: []Point{{V: 1, T: 0}, {V: 3, T: 60000}, {V: 5, T: 120000}},
Metric: labels.Labels{ Metric: labels.FromStrings("__name__", "bar", "job", "2"),
labels.Label{Name: "__name__", Value: "bar"},
labels.Label{Name: "job", Value: "2"},
},
}, },
Series{ Series{
Points: []Point{{V: 3, T: 60000}, {V: 5, T: 120000}}, Points: []Point{{V: 3, T: 60000}, {V: 5, T: 120000}},
Metric: labels.Labels{ Metric: labels.FromStrings("__name__", "foo", "job", "1"),
labels.Label{Name: "__name__", Value: "foo"},
labels.Label{Name: "job", Value: "1"},
},
}, },
}, },
Start: time.Unix(0, 0), Start: time.Unix(0, 0),