aboutsummaryrefslogtreecommitdiff
path: root/tests/defaults/main_test.go
diff options
context:
space:
mode:
authorJakob Unterwurzacher2025-07-07 19:54:48 +0200
committerJakob Unterwurzacher2025-07-07 19:59:35 +0200
commit8f5df19b353e02ffba842fd1b15ccf93da7ee3b4 (patch)
tree8f68b74e56a1d20af82e5093a059d180c925f9be /tests/defaults/main_test.go
parentcdb80ea9825d2e876f1cf579bf960e4da7656b4c (diff)
Fix a bunch of staticcheck errors
Tool-assisted.
Diffstat (limited to 'tests/defaults/main_test.go')
-rw-r--r--tests/defaults/main_test.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/defaults/main_test.go b/tests/defaults/main_test.go
index 75a5dae..a19f079 100644
--- a/tests/defaults/main_test.go
+++ b/tests/defaults/main_test.go
@@ -5,7 +5,6 @@ import (
"bytes"
"fmt"
"io"
- "io/ioutil"
"os"
"os/exec"
"path/filepath"
@@ -176,7 +175,7 @@ func TestXfs124(t *testing.T) {
func TestWrite0200File(t *testing.T) {
fn := test_helpers.DefaultPlainDir + "/TestWrite0200File"
- err := ioutil.WriteFile(fn, nil, 0200)
+ err := os.WriteFile(fn, nil, 0200)
if err != nil {
t.Fatalf("creating empty file failed: %v", err)
}
@@ -212,7 +211,7 @@ func TestWrite0200File(t *testing.T) {
// Now we return EOPNOTSUPP and mv is happy.
func TestMvWarnings(t *testing.T) {
fn := test_helpers.TmpDir + "/TestMvWarnings"
- err := ioutil.WriteFile(fn, nil, 0600)
+ err := os.WriteFile(fn, nil, 0600)
if err != nil {
t.Fatalf("creating file failed: %v", err)
}
@@ -257,7 +256,7 @@ func TestMvWarningSymlink(t *testing.T) {
// See TestMvWarnings.
func TestCpWarnings(t *testing.T) {
fn := test_helpers.TmpDir + "/TestCpWarnings"
- err := ioutil.WriteFile(fn, []byte("foo"), 0600)
+ err := os.WriteFile(fn, []byte("foo"), 0600)
if err != nil {
t.Fatalf("creating file failed: %v", err)
}