mirror of
https://github.com/rclone/rclone.git
synced 2025-07-01 04:50:12 +02:00
fs/cache: factor Fs caching from fs/rc into its own package
This commit is contained in:
@ -7,6 +7,7 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/ncw/rclone/fs"
|
||||
"github.com/ncw/rclone/fs/cache"
|
||||
"github.com/ncw/rclone/fs/operations"
|
||||
"github.com/ncw/rclone/fs/rc"
|
||||
"github.com/ncw/rclone/fstest"
|
||||
@ -21,8 +22,8 @@ func rcNewRun(t *testing.T, method string) (*fstest.Run, *rc.Call) {
|
||||
r := fstest.NewRun(t)
|
||||
call := rc.Calls.Get(method)
|
||||
assert.NotNil(t, call)
|
||||
rc.PutCachedFs(r.LocalName, r.Flocal)
|
||||
rc.PutCachedFs(r.FremoteName, r.Fremote)
|
||||
cache.Put(r.LocalName, r.Flocal)
|
||||
cache.Put(r.FremoteName, r.Fremote)
|
||||
return r, call
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user