test helpers: add RemoveAll and ResetReadOnly

This is mainly needed in Windows, where files and dirs cannot be
removed unless they are writeable.
This commit is contained in:
Alexander Neumann 2015-08-18 21:05:49 +02:00
parent 36ed3add3a
commit 1a47ea4ab8
5 changed files with 36 additions and 7 deletions

View file

@ -50,7 +50,7 @@ func TestTree(t *testing.T) {
dir := createTempDir(t)
defer func() {
if TestCleanup {
OK(t, os.RemoveAll(dir))
RemoveAll(t, dir)
}
}()
}