Adapt to new libimagstore::iter::Entries API

Use Entries::into_storeid_iter() for transforming iterator into right
type.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
This commit is contained in:
Matthias Beyer 2019-01-05 01:09:12 +01:00
parent 207fd88c3d
commit 972cba7c31

View file

@ -232,7 +232,6 @@ mod tests {
use super::*; use super::*;
use std::path::PathBuf; use std::path::PathBuf;
use std::sync::Arc;
use libimagstore::store::Store; use libimagstore::store::Store;
use libimagentrylink::internal::InternalLinker; use libimagentrylink::internal::InternalLinker;
@ -399,7 +398,7 @@ mod tests {
let entries = store.entries(); let entries = store.entries();
assert!(entries.is_ok()); assert!(entries.is_ok());
let entries : Vec<_> = entries.unwrap().without_store().collect(); let entries : Vec<_> = entries.unwrap().into_storeid_iter().collect();
assert_eq!(2, entries.len(), "Expected 2 links, got: {:?}", entries); assert_eq!(2, entries.len(), "Expected 2 links, got: {:?}", entries);
@ -438,7 +437,7 @@ mod tests {
let entries = store.entries(); let entries = store.entries();
assert!(entries.is_ok()); assert!(entries.is_ok());
let entries : Vec<_> = entries.unwrap().without_store().collect(); let entries : Vec<_> = entries.unwrap().into_storeid_iter().collect();
assert_eq!(2, entries.len(), "Expected 2 links, got: {:?}", entries); assert_eq!(2, entries.len(), "Expected 2 links, got: {:?}", entries);
debug!("{:?}", entries); debug!("{:?}", entries);
@ -471,7 +470,7 @@ mod tests {
let entries = store.entries(); let entries = store.entries();
assert!(entries.is_ok()); assert!(entries.is_ok());
let entries : Vec<_> = entries.unwrap().without_store().collect(); let entries : Vec<_> = entries.unwrap().into_storeid_iter().collect();
assert_eq!(3, entries.len(), "Expected 3 links, got: {:?}", entries); assert_eq!(3, entries.len(), "Expected 3 links, got: {:?}", entries);
debug!("{:?}", entries); debug!("{:?}", entries);
@ -504,7 +503,7 @@ mod tests {
let entries = store.entries(); let entries = store.entries();
assert!(entries.is_ok()); assert!(entries.is_ok());
let entries : Vec<_> = entries.unwrap().without_store().collect(); let entries : Vec<_> = entries.unwrap().into_storeid_iter().collect();
assert_eq!(1, entries.len(), "Expected 1 entries, got: {:?}", entries); assert_eq!(1, entries.len(), "Expected 1 entries, got: {:?}", entries);
debug!("{:?}", entries); debug!("{:?}", entries);
@ -532,7 +531,7 @@ mod tests {
let entries = store.entries(); let entries = store.entries();
assert!(entries.is_ok()); assert!(entries.is_ok());
let entries : Vec<_> = entries.unwrap().without_store().collect(); let entries : Vec<_> = entries.unwrap().into_storeid_iter().collect();
assert_eq!(1, entries.len(), "Expected 1 entries, got: {:?}", entries); assert_eq!(1, entries.len(), "Expected 1 entries, got: {:?}", entries);
} }