forked from TrueCloudLab/restic
test: Use testing.T.Cleanup to remove tempdirs
This commit is contained in:
parent
eae7366563
commit
f90bf84ba7
31 changed files with 79 additions and 176 deletions
|
@ -120,8 +120,7 @@ func removeAll(t testing.TB, dir string) {
|
|||
}
|
||||
|
||||
func TestOpenNotExistingDirectory(t *testing.T) {
|
||||
dir, cleanup := rtest.TempDir(t)
|
||||
defer cleanup()
|
||||
dir := rtest.TempDir(t)
|
||||
|
||||
// local.Open must not create any files dirs in the repo
|
||||
openclose(t, filepath.Join(dir, "repo"))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue