Add scaffolding of the index usage test

This commit is contained in:
Cyryl Płotnicki 2018-10-06 22:15:03 +01:00
parent 46656418d9
commit 65900c95e8
2 changed files with 15 additions and 2 deletions

View file

@ -47,3 +47,16 @@ impl<'a> Engine<'a> {
Ok(())
}
}
#[cfg(test)]
mod should {
#[test]
fn store_file_where_index_tells_it() {
// fake index, all files stores at the same path
// backup
// see if repo contains one file at the faked path
assert!(false);
}
}

View file

@ -35,7 +35,7 @@ impl<'a> Index<'a> {
fn new() -> Self {
Self {
file_hashes: HashMap::new(),
file_paths: HashMap::new()
file_paths: HashMap::new(),
}
}
@ -78,7 +78,7 @@ impl<'a> Index<'a> {
source_paths.insert(source_path.to_string());
IndexHashEntry {
source_paths,
storage_path: old_entry.storage_path.clone()
storage_path: old_entry.storage_path.clone(),
}
},
)