repository: split index into a separate package

This commit is contained in:
Michael Eischer
2022-06-12 14:43:43 +02:00
parent 5760ba6989
commit 2e3f1c08c5
20 changed files with 101 additions and 80 deletions

View File

@@ -138,13 +138,3 @@ func BenchmarkAllVersions(b *testing.B, bench VersionedBenchmark) {
})
}
}
func TestMergeIndex(t testing.TB, mi *MasterIndex) ([]*Index, int) {
finalIndexes := mi.finalizeNotFinalIndexes()
for _, idx := range finalIndexes {
test.OK(t, idx.SetID(restic.NewRandomID()))
}
test.OK(t, mi.MergeFinalIndexes())
return finalIndexes, len(mi.idx)
}