Lints
This commit is contained in:
parent
5108ddf7a3
commit
001f0e2dfc
17
src/lib.rs
17
src/lib.rs
@ -59,7 +59,7 @@ impl MusicBrainz {
|
|||||||
}
|
}
|
||||||
|
|
||||||
match url.path_segments().and_then(|mut ps| ps.nth(1)) {
|
match url.path_segments().and_then(|mut ps| ps.nth(1)) {
|
||||||
Some(segment) => Uuid::try_parse(&segment)?,
|
Some(segment) => Uuid::try_parse(segment)?,
|
||||||
None => return Err(Self::invalid_url_error(url).into()),
|
None => return Err(Self::invalid_url_error(url).into()),
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -788,7 +788,10 @@ mod tests {
|
|||||||
let mut music_hoard = MusicHoard::new(library, database);
|
let mut music_hoard = MusicHoard::new(library, database);
|
||||||
|
|
||||||
music_hoard.rescan_library().unwrap();
|
music_hoard.rescan_library().unwrap();
|
||||||
assert_eq!(music_hoard.get_collection(), &clean_collection(COLLECTION.to_owned()));
|
assert_eq!(
|
||||||
|
music_hoard.get_collection(),
|
||||||
|
&clean_collection(COLLECTION.to_owned())
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
@ -812,7 +815,10 @@ mod tests {
|
|||||||
let mut music_hoard = MusicHoard::new(library, database);
|
let mut music_hoard = MusicHoard::new(library, database);
|
||||||
|
|
||||||
music_hoard.rescan_library().unwrap();
|
music_hoard.rescan_library().unwrap();
|
||||||
assert_eq!(music_hoard.get_collection(), &clean_collection(COLLECTION.to_owned()));
|
assert_eq!(
|
||||||
|
music_hoard.get_collection(),
|
||||||
|
&clean_collection(COLLECTION.to_owned())
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
@ -884,7 +890,10 @@ mod tests {
|
|||||||
let mut music_hoard = MusicHoard::new(library, database);
|
let mut music_hoard = MusicHoard::new(library, database);
|
||||||
|
|
||||||
music_hoard.rescan_library().unwrap();
|
music_hoard.rescan_library().unwrap();
|
||||||
assert_eq!(music_hoard.get_collection(), &clean_collection(COLLECTION.to_owned()));
|
assert_eq!(
|
||||||
|
music_hoard.get_collection(),
|
||||||
|
&clean_collection(COLLECTION.to_owned())
|
||||||
|
);
|
||||||
music_hoard.save_to_database().unwrap();
|
music_hoard.save_to_database().unwrap();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user