Merge pull request #1054 from matthiasbeyer/fix-testing

Fix Store loading in tests: Use in-memory store backend
This commit is contained in:
Matthias Beyer 2017-09-05 23:15:57 +02:00 committed by GitHub
commit 822cbb2b3a
3 changed files with 9 additions and 3 deletions

View file

@ -223,7 +223,9 @@ mod tests {
use chrono::naive::NaiveTime;
pub fn get_store() -> Store {
Store::new(PathBuf::from("/"), None).unwrap()
use libimagstore::store::InMemoryFileAbstraction;
let backend = Box::new(InMemoryFileAbstraction::new());
Store::new_with_backend(PathBuf::from("/"), None, backend).unwrap()
}
#[test]

View file

@ -67,7 +67,9 @@ mod tests {
}
fn get_store() -> Store {
Store::new(PathBuf::from("/"), None).unwrap()
use libimagstore::file_abstraction::InMemoryFileAbstraction;
let backend = Box::new(InMemoryFileAbstraction::new());
Store::new_with_backend(PathBuf::from("/"), None, backend).unwrap()
}
#[test]

View file

@ -800,7 +800,9 @@ mod test {
}
pub fn get_store() -> Store {
Store::new(PathBuf::from("/"), None).unwrap()
use libimagstore::file_abstraction::InMemoryFileAbstraction;
let backend = Box::new(InMemoryFileAbstraction::new());
Store::new_with_backend(PathBuf::from("/"), None, backend).unwrap()
}
#[test]