From 2081bafee8e3c9d51dff55006953f449617def52 Mon Sep 17 00:00:00 2001 From: Jacob Baungard Hansen Date: Thu, 19 Dec 2024 14:54:50 +0100 Subject: [PATCH] Don't use ioutils Signed-off-by: Jacob Baungard Hansen --- tests/pkg/tests/observability_alert_test.go | 3 +-- tests/pkg/utils/mco_grafana.go | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/tests/pkg/tests/observability_alert_test.go b/tests/pkg/tests/observability_alert_test.go index bd22345e2..c591e8185 100644 --- a/tests/pkg/tests/observability_alert_test.go +++ b/tests/pkg/tests/observability_alert_test.go @@ -11,7 +11,6 @@ import ( "encoding/json" "fmt" "io" - "io/ioutil" "net/http" "net/url" "os" @@ -595,7 +594,7 @@ var _ = Describe("Observability:", func() { return false } - alertResult, err := ioutil.ReadAll(resp.Body) + alertResult, err := io.ReadAll(resp.Body) if err != nil { return false } diff --git a/tests/pkg/utils/mco_grafana.go b/tests/pkg/utils/mco_grafana.go index 3a864629d..3104928d8 100644 --- a/tests/pkg/utils/mco_grafana.go +++ b/tests/pkg/utils/mco_grafana.go @@ -5,7 +5,6 @@ package utils import ( - "io/ioutil" "os" "strings" "time" @@ -41,7 +40,7 @@ func GetGrafanaURL(opt TestOptions) string { } } - data, err := ioutil.ReadFile(optionsFile) + data, err := os.ReadFile(optionsFile) if err != nil { klog.Errorf("--options error: %v", err) }