func cleanUpDir is unused

Signed-off-by: Benoit Tigeot <benoit.tigeot@lifen.fr>
pull/30752/head
Benoit Tigeot 5 months ago
parent a23b96276a
commit b2ac216763
No known key found for this signature in database
GPG Key ID: 8E6D4FC8AEBDA62C

@ -33,7 +33,6 @@ package fs
import ( import (
"os" "os"
"os/exec"
"path/filepath" "path/filepath"
"runtime" "runtime"
"testing" "testing"
@ -355,19 +354,6 @@ func TestCopyFile(t *testing.T) {
} }
} }
func cleanUpDir(dir string) {
// NOTE(mattn): It seems that sometimes git.exe is not dead
// when cleanUpDir() is called. But we do not know any way to wait for it.
if runtime.GOOS == "windows" {
mu.Lock()
exec.Command(`taskkill`, `/F`, `/IM`, `git.exe`).Run()
mu.Unlock()
}
if dir != "" {
os.RemoveAll(dir)
}
}
func TestCopyFileSymlink(t *testing.T) { func TestCopyFileSymlink(t *testing.T) {
tempdir := t.TempDir() tempdir := t.TempDir()

Loading…
Cancel
Save