Remove dummy url cache
This commit is contained in:
parent
34e1f393cb
commit
397a0a6aa3
@ -467,8 +467,8 @@ func (c *Collections) addURLCacheToDriveCollections(
|
||||
uc, err := newURLCache(
|
||||
driveID,
|
||||
urlCacheRefreshInterval,
|
||||
errs,
|
||||
c.handler.ItemPager(driveID, "", api.DriveItemSelectDefault()))
|
||||
c.handler.NewItemPager(driveID, "", api.DriveItemSelectDefault()),
|
||||
errs)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@ -2700,7 +2700,7 @@ func (suite *OneDriveCollectionsUnitSuite) TestURLCacheIntegration() {
|
||||
suite.Run(test.name, func() {
|
||||
t := suite.T()
|
||||
|
||||
ctx, flush := tester.NewContext()
|
||||
ctx, flush := tester.NewContext(t)
|
||||
defer flush()
|
||||
|
||||
mbh := mock.DefaultOneDriveBH()
|
||||
|
||||
@ -15,11 +15,20 @@ import (
|
||||
"github.com/alcionai/corso/src/pkg/services/m365/api"
|
||||
)
|
||||
|
||||
type urlCacher interface {
|
||||
getItemProperties(
|
||||
ctx context.Context,
|
||||
itemID string,
|
||||
) (itemProps, error)
|
||||
}
|
||||
|
||||
type itemProps struct {
|
||||
downloadURL string
|
||||
isDeleted bool
|
||||
}
|
||||
|
||||
var _ urlCacher = &urlCache{}
|
||||
|
||||
// urlCache caches download URLs for drive items
|
||||
type urlCache struct {
|
||||
driveID string
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user