MCPcopy Index your code
hub / github.com/coder/coder / removeTmpDirUntilSuccessAfterTest

Function removeTmpDirUntilSuccessAfterTest

cli/templatepush_test.go:1335–1343  ·  view source on GitHub ↗

Need this for Windows because of a known issue with Go: https://github.com/golang/go/issues/52986

(t *testing.T, tempDir string)

Source from the content-addressed store, hash-verified

1333// Need this for Windows because of a known issue with Go:
1334// https://github.com/golang/go/issues/52986
1335func removeTmpDirUntilSuccessAfterTest(t *testing.T, tempDir string) {
1336 t.Helper()
1337 t.Cleanup(func() {
1338 err := os.RemoveAll(tempDir)
1339 for err != nil {
1340 err = os.RemoveAll(tempDir)
1341 }
1342 })
1343}

Callers 7

TestCliTemplateCreateFunction · 0.85
TestCreateWithPresetFunction · 0.85
TestTemplatePushFunction · 0.85

Calls 3

RemoveAllMethod · 0.80
HelperMethod · 0.65
CleanupMethod · 0.65

Tested by

no test coverage detected