Make match_suggestions compare all suggestions at once

This commit is contained in:
ysthakur 2024-06-23 21:39:20 -04:00
parent 8b15366457
commit 62c087baf3

View File

@ -149,9 +149,13 @@ pub fn match_suggestions(expected: Vec<String>, suggestions: Vec<Suggestion>) {
Expected: {expected:#?}\n" Expected: {expected:#?}\n"
) )
} }
expected.iter().zip(suggestions).for_each(|it| { assert_eq!(
assert_eq!(it.0, &it.1.value); expected,
}); suggestions
.into_iter()
.map(|it| it.value)
.collect::<Vec<_>>()
);
} }
// append the separator to the converted path // append the separator to the converted path