Fix timer going awry

This commit is contained in:
Deluan
2023-01-17 22:04:04 -05:00
parent feb774a149
commit 580e9ae4bd
5 changed files with 14 additions and 21 deletions
+3 -3
View File
@@ -16,9 +16,9 @@ import (
// Call NewFileCache and wait for it to be ready
func callNewFileCache(name, cacheSize, cacheFolder string, maxItems int, getReader ReadFunc) *fileCache {
fc := NewFileCache(name, cacheSize, cacheFolder, maxItems, getReader)
Eventually(func() bool { return fc.Ready(context.Background()) }).Should(BeTrue())
return fc.(*fileCache)
fc := NewFileCache(name, cacheSize, cacheFolder, maxItems, getReader).(*fileCache)
Eventually(func() bool { return fc.ready.Get() }).Should(BeTrue())
return fc
}
var _ = Describe("File Caches", func() {