mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
nl: add test for "--number-separator"
and replace "match" with "if let"
This commit is contained in:
parent
5d2a2954be
commit
20b1f11daa
2 changed files with 13 additions and 5 deletions
|
@ -156,3 +156,14 @@ fn test_invalid_number_width() {
|
|||
.stderr_contains("invalid value 'invalid'");
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_number_separator() {
|
||||
for arg in ["-s:-:", "--number-separator=:-:"] {
|
||||
new_ucmd!()
|
||||
.arg(arg)
|
||||
.pipe_in("test")
|
||||
.succeeds()
|
||||
.stdout_is(" 1:-:test\n");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue