This commit is contained in:
Rob Ede 2022-01-25 16:05:15 +00:00
parent 405663cf48
commit f264a8ace3
No known key found for this signature in database
GPG Key ID: 97C636207D3EF933
1 changed files with 7 additions and 3 deletions

View File

@ -66,7 +66,11 @@ impl PathBufWrap {
// make sure we agree with stdlib parser // make sure we agree with stdlib parser
for (i, component) in buf.components().enumerate() { for (i, component) in buf.components().enumerate() {
assert!(matches!(component, Component::Normal(_))); assert!(
matches!(component, Component::Normal(_)),
"component `{:?}` is not normal",
component
);
assert!(i < segment_count); assert!(i < segment_count);
} }
@ -168,8 +172,8 @@ mod tests {
); );
assert_eq!( assert_eq!(
PathBufWrap::parse_path("C:../whatever", false).unwrap().0, PathBufWrap::parse_path("D:../whatever", false).unwrap().0,
PathBuf::from_iter(vec!["C:../whatever"]) PathBuf::from_iter(vec!["D:../whatever"])
); );
} }
} }