mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-05 15:37:24 +00:00
replace deprecated io/ioutil with os and io for cmd
This commit is contained in:
@@ -19,7 +19,6 @@ package app
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"reflect"
|
||||
@@ -406,7 +405,7 @@ func TestProcessHostnameOverrideFlag(t *testing.T) {
|
||||
|
||||
func TestConfigChange(t *testing.T) {
|
||||
setUp := func() (*os.File, string, error) {
|
||||
tempDir, err := ioutil.TempDir("", "kubeproxy-config-change")
|
||||
tempDir, err := os.MkdirTemp("", "kubeproxy-config-change")
|
||||
if err != nil {
|
||||
return nil, "", fmt.Errorf("unable to create temporary directory: %v", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user