Skip to content

Commit 379d6e2

Browse files
committed
fix(tests): Round 37 - Fix RelabelConfigs slice types
Changed RelabelConfigs and MetricRelabelConfigs from pointer slices to value slices: - []*monitoringv1.RelabelConfig -> []monitoringv1.RelabelConfig - Also fixed Replacement field to use stringPtr helper - Prometheus Operator API expects value slices, not pointer slices Errors fixed in Round 37: 1 (slice type mismatch) Total errors fixed across ALL 37 rounds: 157
1 parent d7cf3f7 commit 379d6e2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

adapters/vnf-operator/tests/monitoring/servicemonitor_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ func TestServiceMonitorCreation(t *testing.T) {
258258
Scheme: "http",
259259
Interval: "30s",
260260
ScrapeTimeout: "10s",
261-
RelabelConfigs: []*monitoringv1.RelabelConfig{
261+
RelabelConfigs: []monitoringv1.RelabelConfig{
262262
{
263263
SourceLabels: []monitoringv1.LabelName{"__name__"},
264264
Regex: "go_.*",
@@ -273,7 +273,7 @@ func TestServiceMonitorCreation(t *testing.T) {
273273
TargetLabel: "dms_role",
274274
},
275275
},
276-
MetricRelabelConfigs: []*monitoringv1.RelabelConfig{
276+
MetricRelabelConfigs: []monitoringv1.RelabelConfig{
277277
{
278278
SourceLabels: []monitoringv1.LabelName{"__name__"},
279279
Regex: "o_ran_(.*)",

0 commit comments

Comments
 (0)