mirror of
https://github.com/coredns/coredns.git
synced 2025-10-27 08:14:18 -04:00
cleanup deprecated package io/ioutil (#4920)
Signed-off-by: zounengren <zouyee1989@gmail.com>
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package forward
|
||||
|
||||
import (
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"reflect"
|
||||
"strings"
|
||||
@@ -126,7 +125,7 @@ func TestSetupTLS(t *testing.T) {
|
||||
|
||||
func TestSetupResolvconf(t *testing.T) {
|
||||
const resolv = "resolv.conf"
|
||||
if err := ioutil.WriteFile(resolv,
|
||||
if err := os.WriteFile(resolv,
|
||||
[]byte(`nameserver 10.10.255.252
|
||||
nameserver 10.10.255.253`), 0666); err != nil {
|
||||
t.Fatalf("Failed to write resolv.conf file: %s", err)
|
||||
|
||||
Reference in New Issue
Block a user