Skip to content

config_test.go.TestNewDefaultWithXDGConfigHome fails on macOS #196

Description

@jbenge1

The test config_test.go.TestNewDefaultWithXDGConfigHome fails on any non linux based (or BSD) system as go respects the macOS/Windows default config folders (~/Library/Application\ Support/ and %AppData% respectively), or rather it ignores XDG_CONFIG_HOME on those systems.

Seeing as nom also repsects this I think this could be fixed by just skipping the tests on any environment that's not linux/bsd based

if runtime.GOOS != "linux" && runtime.GOOS != "freebsd"{
  t.Skip("XDG_CONFIG_HOME only supported on linux/BSD")
}

Happy to open up a pr if there aren't any other suggestions?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions