#[test] fn empty_list() { let mut items = willdo::config::read("[]".as_bytes(), "urn:reader").into_iter(); assert!(items.next().is_none()); } #[test] fn fail_not_found() { let mut items = willdo::config::read("[nonexistent]".as_bytes(), "file:///tmp/").into_iter(); assert!(items.next().expect("err").is_err()); } #[test] fn fail_invalid() { let mut items = willdo::config::read("[badurl]".as_bytes(), "urn:invalid").into_iter(); assert!(items.next().expect("err").is_err()); }