Change List() implementation for all backends
This commit is contained in:
parent
dd91b13ff3
commit
e9ea268847
12 changed files with 363 additions and 329 deletions
|
@ -56,9 +56,10 @@ func TestLayout(t *testing.T) {
|
|||
}
|
||||
|
||||
datafiles := make(map[string]bool)
|
||||
for id := range be.List(context.TODO(), restic.DataFile) {
|
||||
datafiles[id] = false
|
||||
}
|
||||
err = be.List(context.TODO(), restic.DataFile, func(fi restic.FileInfo) error {
|
||||
datafiles[fi.Name] = false
|
||||
return nil
|
||||
})
|
||||
|
||||
if len(datafiles) == 0 {
|
||||
t.Errorf("List() returned zero data files")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue