pub struct CacheManager;Expand description
Temp directory shared between the orchestrating process (cargo skipper)
and the test binaries: it holds the resolver handoff (cache.json) and one
JSON array of discovered test IDs per writer.
Implementations§
Source§impl CacheManager
impl CacheManager
Sourcepub fn write_resolver_cache(data: &[u8]) -> Result<PathBuf, Error>
pub fn write_resolver_cache(data: &[u8]) -> Result<PathBuf, Error>
Create skipper-* in the temp dir and write cache.json into it.
Point SKIPPER_WORKER_CACHE_FILE at the returned file and
SKIPPER_DISCOVERED_DIR at its parent.
Sourcepub fn write_discovered_ids(dir: &Path, ids: &[String]) -> Result<(), Error>
pub fn write_discovered_ids(dir: &Path, ids: &[String]) -> Result<(), Error>
Write ids to a uniquely named file in dir.
Sourcepub fn merge_discovered_ids(dir: &Path) -> Vec<String>
pub fn merge_discovered_ids(dir: &Path) -> Vec<String>
Merge every discovered-ID file (sorted by name), deduplicated on the exact string.
pub fn cleanup(dir: &Path)
Auto Trait Implementations§
impl Forget for CacheManager
impl Freeze for CacheManager
impl Move for CacheManager
impl RefUnwindSafe for CacheManager
impl Send for CacheManager
impl Sync for CacheManager
impl Unpin for CacheManager
impl UnsafeUnpin for CacheManager
impl UnwindSafe for CacheManager
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more