mirror of
https://github.com/coredns/coredns.git
synced 2025-12-06 02:15:11 -05:00
cleanup deprecated package io/ioutil (#4920)
Signed-off-by: zounengren <zouyee1989@gmail.com>
This commit is contained in:
@@ -2,7 +2,7 @@ package health
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"io"
|
||||
"net/http"
|
||||
"testing"
|
||||
"time"
|
||||
@@ -25,7 +25,7 @@ func TestHealth(t *testing.T) {
|
||||
if response.StatusCode != 200 {
|
||||
t.Errorf("Invalid status code: expecting '200', got '%d'", response.StatusCode)
|
||||
}
|
||||
content, err := ioutil.ReadAll(response.Body)
|
||||
content, err := io.ReadAll(response.Body)
|
||||
if err != nil {
|
||||
t.Fatalf("Unable to get response body from %s: %v", address, err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user