WithCache overrides the path of the on-disk cache file used by the Store. The parent directory will be created if it does not already exist.
(path string)
| 67 | // WithCache overrides the path of the on-disk cache file used by the Store. |
| 68 | // The parent directory will be created if it does not already exist. |
| 69 | func WithCache(path string) Opt { |
| 70 | return func(o *storeOptions) { |
| 71 | o.cacheFile = path |
| 72 | } |
| 73 | } |
| 74 | |
| 75 | // WithFetcher overrides the function used to fetch the catalog from the |
| 76 | // network. It is primarily a test seam: callers can stub the network out |
no outgoing calls