func TestIsDirectory(t *testing.T) { assert := assert.New(t) path, err := ioutil.TempDir("", "directory") assert.NoError(err) file := resource.NewFile(path) assert.NoError(IsDirectory(file)) }
func TestIsRegular(t *testing.T) { assert := assert.New(t) f, err := ioutil.TempFile("", "regular") assert.NoError(err) file := resource.NewFile(f.Name()) assert.NoError(IsRegular(file)) }