mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 11:37:44 +00:00
tests/util: Do not trim stderr in CmdResult::stderr_is. Add method stderr_trimmed_is.
Fix tests assert whitespace instead of trimming it. Disable some tests in `test_tr` because `tr` produces too many newlines.
This commit is contained in:
parent
7c0ed0340b
commit
1fadeb43b2
40 changed files with 229 additions and 211 deletions
|
@ -321,13 +321,13 @@ fn test_include_exclude_same_type() {
|
|||
new_ucmd!()
|
||||
.args(&["-t", "ext4", "-x", "ext4"])
|
||||
.fails()
|
||||
.stderr_is("df: file system type 'ext4' both selected and excluded");
|
||||
.stderr_is("df: file system type 'ext4' both selected and excluded\n");
|
||||
new_ucmd!()
|
||||
.args(&["-t", "ext4", "-x", "ext4", "-t", "ext3", "-x", "ext3"])
|
||||
.fails()
|
||||
.stderr_is(
|
||||
"df: file system type 'ext4' both selected and excluded\n\
|
||||
df: file system type 'ext3' both selected and excluded",
|
||||
df: file system type 'ext3' both selected and excluded\n",
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -853,7 +853,7 @@ fn test_nonexistent_file() {
|
|||
new_ucmd!()
|
||||
.arg("does-not-exist")
|
||||
.fails()
|
||||
.stderr_only("df: does-not-exist: No such file or directory");
|
||||
.stderr_only("df: does-not-exist: No such file or directory\n");
|
||||
new_ucmd!()
|
||||
.args(&["--output=file", "does-not-exist", "."])
|
||||
.fails()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue