From 9f95a05caa34fda8791d8b63db5e9c80814685d8 Mon Sep 17 00:00:00 2001 From: Pykselle Date: Fri, 30 Mar 2018 09:55:59 +0200 Subject: [PATCH] Fix windows bug Since last update on go 1.10.0 and godog v0.7.7, a "dev" folder (containing the test binary named "null") was created in the current test directory (where the "godog" cmd was called) on WINDOWS machines --- builder_go110.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builder_go110.go b/builder_go110.go index 19aa297..0b2b91a 100644 --- a/builder_go110.go +++ b/builder_go110.go @@ -91,7 +91,7 @@ func Build(bin string) error { // since we do not need it for godog suite. // we also print back the temp WORK directory // go has built. We will reuse it for our suite workdir. - out, err = exec.Command("go", "test", "-c", "-work", "-o", "/dev/null").CombinedOutput() + out, err = exec.Command("go", "test", "-c", "-work", "-o", os.DevNull).CombinedOutput() if err != nil { return fmt.Errorf("failed to compile tested package: %s, reason: %v, output: %s", pkg.Name, err, string(out)) }