Modified testDirs list in initDirs to avoid invalid path on Windows

This commit is contained in:
inkychris 2019-03-16 13:20:04 +00:00
parent cb74da57f4
commit d86fb2e6af

View file

@ -191,10 +191,14 @@ func initHcl() {
func initDirs(t *testing.T) (string, string, func()) { func initDirs(t *testing.T) (string, string, func()) {
var ( var (
testDirs = []string{`a a`, `b`, `c\c`, `D_`} testDirs = []string{`a a`, `b`, `C_`}
config = `improbable` config = `improbable`
) )
if runtime.GOOS != "windows" {
testDirs = append(testDirs, `d\d`)
}
root, err := ioutil.TempDir("", "") root, err := ioutil.TempDir("", "")
require.NoError(t, err, "Failed to create temporary directory") require.NoError(t, err, "Failed to create temporary directory")