From 88fe62ddef76c8183db7847d251b1e6a31bc41ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sybren=20A=2E=20St=C3=BCvel?= Date: Mon, 28 Mar 2022 11:33:09 +0200 Subject: [PATCH] Manager: skip shaman permission unit test on Windows The test was made with umask on UNIX-like systems in mind. It doesn't make much sense on Windows, at least not in its current form, so it's better to just explicitly skip it. --- pkg/shaman/filestore/substore_test.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkg/shaman/filestore/substore_test.go b/pkg/shaman/filestore/substore_test.go index 70b3efe8..ae188021 100644 --- a/pkg/shaman/filestore/substore_test.go +++ b/pkg/shaman/filestore/substore_test.go @@ -25,6 +25,7 @@ package filestore import ( "os" "path/filepath" + "runtime" "testing" "github.com/stretchr/testify/assert" @@ -55,6 +56,10 @@ func TestContains(t *testing.T) { } func TestFilePermissions(t *testing.T) { + if runtime.GOOS == "windows" { + t.Logf("Skipping permission test on %s, as it was designed for umask/UNIX", runtime.GOOS) + t.SkipNow() + } dirname, err := os.MkdirTemp("", "file-permission-test") assert.NoError(t, err) defer os.RemoveAll(dirname)