From 311899709b3680871233817c8e5033ce36fe1554 Mon Sep 17 00:00:00 2001 From: Alex Brainman Date: Sat, 17 Oct 2020 18:00:38 +1100 Subject: [PATCH] =?UTF-8?q?version:=20skip=C2=A0TestMkversion=C2=A0on=20wi?= =?UTF-8?q?ndows?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit TestMkversion requires UNIX shell to run mkversion.sh. No such shell is present on Windows. Just skip the test. Updates #50 Signed-off-by: Alex Brainman --- version/mkversion_test.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/version/mkversion_test.go b/version/mkversion_test.go index 8e2384f55..c670b4989 100644 --- a/version/mkversion_test.go +++ b/version/mkversion_test.go @@ -7,6 +7,7 @@ package version import ( "fmt" "os/exec" + "runtime" "strings" "testing" ) @@ -26,6 +27,9 @@ func mkversion(t *testing.T, mode, in string) (string, bool) { } func TestMkversion(t *testing.T) { + if runtime.GOOS == "windows" { + t.Skip("skip test on Windows, because there is no shell to execute mkversion.sh.") + } tests := []struct { in string ok bool