mirror of
https://github.com/restic/restic.git
synced 2025-12-04 02:31:57 +00:00
test: Use testing.T.Cleanup to remove tempdirs
This commit is contained in:
@@ -60,8 +60,10 @@ func (s *Suite) RunTests(t *testing.T) {
|
||||
return
|
||||
}
|
||||
|
||||
if err = s.Cleanup(s.Config); err != nil {
|
||||
t.Fatal(err)
|
||||
if s.Cleanup != nil {
|
||||
if err = s.Cleanup(s.Config); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user