100-days-of-rust/Week-02/Day-08_Letter-Combinations-Of-A-Phone-Number/day8/tests/examples.rs
2024-08-02 21:50:37 +02:00

20 lines
332 B
Rust

use day8::combination;
#[test]
fn example1() {
assert_eq!(
combination("23"),
vec!["ad", "ae", "af", "bd", "be", "bf", "cd", "ce", "cf"]
);
}
#[test]
fn example2() {
assert_eq!(combination(""), vec![] as Vec<String>);
}
#[test]
fn example3() {
assert_eq!(combination("2"), vec!["a", "b", "c"]);
}