mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
tr/dirname: fix clap short_alias
This commit is contained in:
parent
b89978a4c9
commit
45dd9d4e96
4 changed files with 71 additions and 25 deletions
|
@ -16,6 +16,21 @@ fn test_path_without_trailing_slashes() {
|
|||
.stdout_is("/root/alpha/beta/gamma/delta/epsilon\n");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_path_without_trailing_slashes_and_zero() {
|
||||
new_ucmd!()
|
||||
.arg("-z")
|
||||
.arg("/root/alpha/beta/gamma/delta/epsilon/omega")
|
||||
.succeeds()
|
||||
.stdout_is("/root/alpha/beta/gamma/delta/epsilon\u{0}");
|
||||
|
||||
new_ucmd!()
|
||||
.arg("--zero")
|
||||
.arg("/root/alpha/beta/gamma/delta/epsilon/omega")
|
||||
.succeeds()
|
||||
.stdout_is("/root/alpha/beta/gamma/delta/epsilon\u{0}");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_root() {
|
||||
new_ucmd!().arg("/").run().stdout_is("/\n");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue