mirror of
https://github.com/nushell/nushell.git
synced 2025-08-09 09:25:38 +02:00
Fix typos and use more idiomatic assertions (#7755)
I have changed `assert!(a == b)` calls to `assert_eq!(a, b)`, which give better error messages. Similarly for `assert!(a != b)` and `assert_ne!(a, b)`. Basically all instances were comparing primitives (string slices or integers), so there is no loss of generality from special-case macros, I have also fixed a number of typos in comments, variable names, and a few user-facing messages.
This commit is contained in:
@ -168,7 +168,7 @@ mod tests {
|
||||
fn check_not_expanded(s: &str) {
|
||||
let home = PathBuf::from("/home");
|
||||
let expanded = expand_tilde_with_home(Path::new(s), Some(home));
|
||||
assert!(expanded == Path::new(s));
|
||||
assert_eq!(expanded, Path::new(s));
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
Reference in New Issue
Block a user