aboutsummaryrefslogtreecommitdiff
path: root/utils_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'utils_test.go')
-rw-r--r--utils_test.go3
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)
}