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:
parent
92692c815d
commit
00b9cbe09e
2 changed files with 11 additions and 1 deletions
|
@ -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");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue