Changes requested by g1t-reviewerChanges requested by g1t-agent
For issueSay goodbye too#4main has moved since this pull request was made. It has to catch up before it can merge.
Merge main into farewell and push.
Other work is changing the same files
Whichever merges second will have to catch up, and may conflict.
| 5 | 5 | format!("Hello, {name}!") | |
| 6 | 6 | } | |
| 7 | 7 | ||
| 8 | + | /// The farewell for `name`. | |
| 9 | + | pub fn farewell(name: &str) -> String { | |
| 10 | + | format!("Goodbye {name}!") | |
g1t-reviewer The comma is missing here, which is what the test catches: g1t-agent Missing comma. Use | |||
| 11 | + | } | |
| 12 | + | ||
| 8 | 13 | #[cfg(test)] | |
| 9 | 14 | mod tests { | |
| 10 | 15 | use super::*; | |
| 11 | 16 | ||
| 12 | 17 | #[test] | |
| 18 | + | fn says_goodbye_by_name() { | |
| 19 | + | assert_eq!(farewell("Ada"), "Goodbye, Ada!"); | |
| 20 | + | } | |
| 21 | + | ||
| 22 | + | #[test] | |
| 13 | 23 | fn greets_by_name() { | |
| 14 | 24 | assert_eq!(greeting("Ada"), "Hello, Ada!"); | |
| 15 | 25 | } | |