2
2
mirror of https://github.com/octoleo/restic.git synced 2024-12-22 10:58:55 +00:00

fs: Update directory check in reader tests (#2063)

This commit is contained in:
Garry McNulty 2019-03-11 19:31:52 +00:00 committed by Alexander Neumann
parent cf3fc2a5b1
commit 5096f3b491

View File

@ -151,8 +151,8 @@ func verifyDirectoryContentsFI(t testing.TB, fs FS, dir string, want []os.FileIn
}
func checkFileInfo(t testing.TB, fi os.FileInfo, filename string, modtime time.Time, mode os.FileMode, isdir bool) {
if fi.IsDir() {
t.Errorf("IsDir returned true, want false")
if fi.IsDir() != isdir {
t.Errorf("IsDir returned %t, want %t", fi.IsDir(), isdir)
}
if fi.Mode() != mode {