From ba8484ee6b1dd77f0725852d916c1c839672b3b2 Mon Sep 17 00:00:00 2001 From: Adrien Delorme Date: Thu, 11 Feb 2021 14:49:52 +0100 Subject: [PATCH] tests: pre make dir in case nothing happens --- command/utils_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/command/utils_test.go b/command/utils_test.go index f381b2e98..81dcf9e05 100644 --- a/command/utils_test.go +++ b/command/utils_test.go @@ -15,6 +15,9 @@ func mustString(s string, e error) string { } func createFiles(dir string, content map[string]string) { + if err := os.MkdirAll(dir, 0777); err != nil { + panic(err) + } for relPath, content := range content { contentPath := filepath.Join(dir, relPath) if err := os.MkdirAll(filepath.Dir(contentPath), 0777); err != nil {