mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
tail: handle file NotFound error correctly
This commit is contained in:
parent
1f24b1f59c
commit
a727b2e666
2 changed files with 35 additions and 14 deletions
|
@ -288,6 +288,22 @@ fn test_multiple_input_files() {
|
|||
.stdout_is_fixture("foobar_follow_multiple.expected");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_multiple_input_files_missing() {
|
||||
new_ucmd!()
|
||||
.arg(FOOBAR_TXT)
|
||||
.arg("missing1")
|
||||
.arg(FOOBAR_2_TXT)
|
||||
.arg("missing2")
|
||||
.run()
|
||||
.stdout_is_fixture("foobar_follow_multiple.expected")
|
||||
.stderr_is(
|
||||
"tail: cannot open 'missing1': No such file or directory\n\
|
||||
tail: cannot open 'missing2': No such file or directory",
|
||||
)
|
||||
.code_is(1);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_multiple_input_files_with_suppressed_headers() {
|
||||
new_ucmd!()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue