1 // Copyright 2017 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
13 "golang.org/x/sys/unix"
16 func TestStatvfs(t *testing.T) {
17 if err := unix.Statvfs("", nil); err == nil {
18 t.Fatal(`Statvfs("") expected failure`)
21 statvfs := unix.Statvfs_t{}
22 if err := unix.Statvfs("/", &statvfs); err != nil {
23 t.Errorf(`Statvfs("/") failed: %v`, err)
27 mount, err := exec.Command("mount").CombinedOutput()
29 t.Logf("mount: %v\n%s", err, mount)
31 t.Logf("mount: %s", mount)