address Don's comment

This commit is contained in:
Tejal Desai 2019-10-04 14:43:21 -07:00
parent 230c4c9b07
commit bb9ace058f
2 changed files with 3 additions and 3 deletions

View File

@ -241,7 +241,7 @@ func resolveRelativePaths() error {
}
for _, p := range optsPaths {
if path := *p; skipPath(path) {
if path := *p; shdSkip(path) {
logrus.Debugf("Skip resolving path %s", path)
continue
}
@ -269,6 +269,6 @@ func isURL(path string) bool {
return false
}
func skipPath(path string) bool {
func shdSkip(path string) bool {
return path == "" || isURL(path) || filepath.IsAbs(path)
}

View File

@ -56,7 +56,7 @@ func TestSkipPath(t *testing.T) {
for _, tt := range tests {
t.Run(tt.description, func(t *testing.T) {
testutil.CheckDeepEqual(t, tt.expected, skipPath(tt.path))
testutil.CheckDeepEqual(t, tt.expected, shdSkip(tt.path))
})
}
}