1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 03:27:44 +00:00

expr: coerce to string before comparing values

This commit is contained in:
Terts Diepraam 2023-12-18 22:11:04 +01:00
parent 92692c815d
commit 00b9cbe09e
2 changed files with 11 additions and 1 deletions

View file

@ -362,3 +362,11 @@ fn test_invalid_syntax() {
.stderr_contains("syntax error");
}
}
#[test]
fn test_num_str_comparison() {
new_ucmd!()
.args(&["1a", "<", "1", "+", "1"])
.succeeds()
.stdout_is("1\n");
}