thing-testkit: store::create pulls before writing
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
81f0d1bf3d
commit
32205f8b2b
1 changed files with 3 additions and 0 deletions
|
|
@ -20,6 +20,9 @@ pub fn create(path: &Path) -> CultCache {
|
|||
let _ = std::fs::remove_file(path);
|
||||
let mut cache = memory();
|
||||
cache.add_generic_backing_store(SingleFileMessagePackBackingStore::new(path)).unwrap();
|
||||
// From cultcache-rs 0.4 a cache that attached a store refuses writes until it pulls; the file
|
||||
// was just removed, so the pull is empty.
|
||||
cache.pull_all_backing_stores().unwrap();
|
||||
cache
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue