mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
parent
95de5f6494
commit
e3cac647f6
2 changed files with 74 additions and 3 deletions
|
@ -263,3 +263,33 @@ fn test_tabs_with_too_large_size() {
|
|||
|
||||
new_ucmd!().arg(arg).fails().stderr_contains(expected_error);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_tabs_shortcut() {
|
||||
new_ucmd!()
|
||||
.args(&["-2", "-5", "-7"])
|
||||
.pipe_in("\ta\tb\tc")
|
||||
.succeeds()
|
||||
// 01234567890
|
||||
.stdout_is(" a b c");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_comma_separated_tabs_shortcut() {
|
||||
new_ucmd!()
|
||||
.args(&["-2,5", "-7"])
|
||||
.pipe_in("\ta\tb\tc")
|
||||
.succeeds()
|
||||
// 01234567890
|
||||
.stdout_is(" a b c");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_tabs_and_tabs_shortcut_mixed() {
|
||||
new_ucmd!()
|
||||
.args(&["-2", "--tabs=5", "-7"])
|
||||
.pipe_in("\ta\tb\tc")
|
||||
.succeeds()
|
||||
// 01234567890
|
||||
.stdout_is(" a b c");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue