diff options
author | 2022-12-19 06:50:12 -0800 | |
---|---|---|
committer | 2022-12-19 09:50:12 -0500 | |
commit | 48c0b5f1653077bcb529c22aeaa95d4b01a582bf (patch) | |
tree | ce1dfff461bd80a32a86fbb429b86a2dd48cbe62 /utils_test.go | |
parent | e3604e558f6bd4dccc96b9bd071223fd8506888f (diff) | |
download | sally-48c0b5f1653077bcb529c22aeaa95d4b01a582bf.tar.gz sally-48c0b5f1653077bcb529c22aeaa95d4b01a582bf.tar.zst sally-48c0b5f1653077bcb529c22aeaa95d4b01a582bf.zip |
Fix lint error issues (#65)
Since upgrading to Go 1.19 we are seeing linter error due to
usage of the deprecated io/ioutil package.
This removes the usage of io/ioutil package.
Diffstat (limited to 'utils_test.go')
-rw-r--r-- | utils_test.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/utils_test.go b/utils_test.go index d5a4f89..1388475 100644 --- a/utils_test.go +++ b/utils_test.go @@ -1,7 +1,6 @@ package main import ( - "io/ioutil" "net/http" "net/http/httptest" "os" @@ -14,7 +13,7 @@ import ( // TempFile persists contents and returns the path and a clean func func TempFile(t *testing.T, contents string) (path string, clean func()) { content := []byte(contents) - tmpfile, err := ioutil.TempFile("", "sally-tmp") + tmpfile, err := os.CreateTemp("", "sally-tmp") if err != nil { t.Fatal("Unable to create tmpfile", err) } |