app/vmselect/promql: fix TestVmrangeBucketsToLE test after 8516670582

Remove 'AccountID=0, ProjectID=0, ' prefix for cluster version
This commit is contained in:
Aliaksandr Valialkin 2022-08-07 00:15:04 +03:00
parent 5e43145031
commit 21f588e9cf
No known key found for this signature in database
GPG key ID: A72BEC6CD3D0DED1

View file

@ -214,6 +214,7 @@ func timeseriesToPromMetrics(tss []*timeseries) string {
for _, ts := range tss {
metricName := ts.MetricName.String()
for i := range ts.Timestamps {
metricName = strings.TrimPrefix(metricName, "AccountID=0, ProjectID=0, ")
line := fmt.Sprintf("%s %v %d", metricName, ts.Values[i], ts.Timestamps[i])
a = append(a, line)
}