Skip to content

Commit

Permalink
[chore] fix TestProcessTelemetryWithHostProc test (#11222)
Browse files Browse the repository at this point in the history
#### Description
Fixes failing unit test TestProcessTelemetryWithHostProc under
service/internal/proctelemetry/process_telemetry_linux_test.go due to
incorrect metric name

#### Link to tracking issue
Fixes [#11221](#11221)
  • Loading branch information
jackgopack4 authored Sep 23, 2024
1 parent 77bb849 commit 60a3e5a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ func TestProcessTelemetryWithHostProc(t *testing.T) {
} else {
metricValue = metric.Metric[0].GetGauge().GetValue()
}
if strings.HasPrefix(metricName, "process_uptime") || strings.HasPrefix(metricName, "process_cpu_seconds") {
if strings.HasPrefix(metricName, "otelcol_process_uptime") || strings.HasPrefix(metricName, "otelcol_process_cpu_seconds") {
// This likely will still be zero when running the test.
assert.GreaterOrEqual(t, metricValue, float64(0), metricName)
continue
Expand Down

0 comments on commit 60a3e5a

Please sign in to comment.