mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-12 01:14:22 +00:00
Stop using deprecated ioutil functions
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
package kio
|
||||
|
||||
import (
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
"testing"
|
||||
@@ -46,10 +46,10 @@ func TestIgnoreFilesMatcher_readIgnoreFile(t *testing.T) {
|
||||
|
||||
if writeIgnoreFile {
|
||||
ignoreFilePath := filepath.Join(dir, ignoreFileName)
|
||||
require.NoError(t, ioutil.WriteFile(ignoreFilePath, []byte(ignoreFileBody), 0600))
|
||||
require.NoError(t, os.WriteFile(ignoreFilePath, []byte(ignoreFileBody), 0600))
|
||||
}
|
||||
testFilePath := filepath.Join(dir, testFileName)
|
||||
require.NoError(t, ioutil.WriteFile(testFilePath, []byte{}, 0600))
|
||||
require.NoError(t, os.WriteFile(testFilePath, []byte{}, 0600))
|
||||
return dir, nil
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user