storj/storage/filestore/dir_test.go

22 lines
426 B
Go
Raw Normal View History

2019-01-24 20:15:10 +00:00
// Copyright (C) 2019 Storj Labs, Inc.
2018-09-28 07:59:27 +01:00
// See LICENSE for copying information.
package filestore
import "testing"
func TestDiskInfoFromPath(t *testing.T) {
info, err := diskInfoFromPath(".")
if err != nil {
t.Fatal(err)
}
if info.AvailableSpace <= 0 {
t.Fatal("expected to have some disk space")
}
if info.ID == "" {
t.Fatal("didn't get filesystem id")
}
t.Logf("Got: %v %v", info.ID, info.AvailableSpace)
}