aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/matrix/matrix_test.go2
-rw-r--r--tests/test_helpers/mount_unmount.go3
2 files changed, 3 insertions, 2 deletions
diff --git a/tests/matrix/matrix_test.go b/tests/matrix/matrix_test.go
index ad2eeae..e4c6b5f 100644
--- a/tests/matrix/matrix_test.go
+++ b/tests/matrix/matrix_test.go
@@ -625,7 +625,7 @@ func doTestUtimesNano(t *testing.T, path string) {
for i, tc := range utimeTestcases {
err := syscall.UtimesNano(path, tc.in[:])
if err != nil {
- t.Fatal(err)
+ t.Fatalf("%q: %v", path, err)
}
var st syscall.Stat_t
err = syscall.Stat(path, &st)
diff --git a/tests/test_helpers/mount_unmount.go b/tests/test_helpers/mount_unmount.go
index 1d43418..20b1143 100644
--- a/tests/test_helpers/mount_unmount.go
+++ b/tests/test_helpers/mount_unmount.go
@@ -133,7 +133,8 @@ func UnmountErr(dir string) (err error) {
var fdsNow []string
pid := MountInfo[dir].Pid
fds := MountInfo[dir].Fds
- if pid <= 0 {
+ if pid <= 0 && runtime.GOOS == "linux" {
+ // The FD leak check only works on Linux.
fmt.Printf("UnmountErr: %q was not found in MountInfo, cannot check for FD leaks\n", dir)
}