mirror of
https://github.com/rclone/rclone.git
synced 2025-01-13 20:38:12 +02:00
local: make sure we close file handle in local tests
...as Windows can't remove a directory with an open file handle in
This commit is contained in:
parent
7e13103ba2
commit
74297a0c55
@ -47,6 +47,9 @@ func TestUpdatingCheck(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Fatalf("failed opening file %q: %v", filePath, err)
|
||||
}
|
||||
defer func() {
|
||||
require.NoError(t, fd.Close())
|
||||
}()
|
||||
|
||||
fi, err := fd.Stat()
|
||||
require.NoError(t, err)
|
||||
|
Loading…
Reference in New Issue
Block a user