From 84f9c42bbbfb67c2ef78d4a4e19417329d7f8f5a Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Thu, 18 Sep 2014 20:13:07 -0400 Subject: [PATCH] os: skip TestRemoveAllRace on Windows It's just fundamentally incompatible with Windows' pickiness about removing things that are in use. TBR=brainman CC=golang-codereviews https://golang.org/cl/142270043 --- src/os/os_test.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/os/os_test.go b/src/os/os_test.go index 7a284974141..973cc3a7bff 100644 --- a/src/os/os_test.go +++ b/src/os/os_test.go @@ -1422,6 +1422,14 @@ func mkdirTree(t *testing.T, root string, level, max int) { // Test that simultaneous RemoveAll do not report an error. // As long as it gets removed, we should be happy. func TestRemoveAllRace(t *testing.T) { + if runtime.GOOS == "windows" { + // Windows has very strict rules about things like + // removing directories while someone else has + // them open. The racing doesn't work out nicely + // like it does on Unix. + t.Skip("skipping on windows") + } + n := runtime.GOMAXPROCS(16) defer runtime.GOMAXPROCS(n) root, err := ioutil.TempDir("", "issue")