mirror of
https://github.com/uutils/coreutils
synced 2024-10-15 04:14:44 +00:00
tests: delete 'error:' prefix from the tests
This commit is contained in:
parent
898d2eb489
commit
071899d24d
|
@ -98,7 +98,7 @@ fn test_wrap_bad_arg() {
|
|||
.arg(wrap_param)
|
||||
.arg("b")
|
||||
.fails()
|
||||
.stderr_only("base32: error: Invalid wrap size: ‘b’: invalid digit found in string\n");
|
||||
.stderr_only("base32: Invalid wrap size: ‘b’: invalid digit found in string\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -109,7 +109,7 @@ fn test_base32_extra_operand() {
|
|||
.arg("a.txt")
|
||||
.arg("a.txt")
|
||||
.fails()
|
||||
.stderr_only("base32: error: extra operand ‘a.txt’");
|
||||
.stderr_only("base32: extra operand ‘a.txt’");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -117,5 +117,5 @@ fn test_base32_file_not_found() {
|
|||
new_ucmd!()
|
||||
.arg("a.txt")
|
||||
.fails()
|
||||
.stderr_only("base32: error: a.txt: No such file or directory");
|
||||
.stderr_only("base32: a.txt: No such file or directory");
|
||||
}
|
||||
|
|
|
@ -88,7 +88,7 @@ fn test_wrap_bad_arg() {
|
|||
.arg(wrap_param)
|
||||
.arg("b")
|
||||
.fails()
|
||||
.stderr_only("base64: error: Invalid wrap size: ‘b’: invalid digit found in string\n");
|
||||
.stderr_only("base64: Invalid wrap size: ‘b’: invalid digit found in string\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -99,7 +99,7 @@ fn test_base64_extra_operand() {
|
|||
.arg("a.txt")
|
||||
.arg("a.txt")
|
||||
.fails()
|
||||
.stderr_only("base64: error: extra operand ‘a.txt’");
|
||||
.stderr_only("base64: extra operand ‘a.txt’");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -107,5 +107,5 @@ fn test_base64_file_not_found() {
|
|||
new_ucmd!()
|
||||
.arg("a.txt")
|
||||
.fails()
|
||||
.stderr_only("base64: error: a.txt: No such file or directory");
|
||||
.stderr_only("base64: a.txt: No such file or directory");
|
||||
}
|
||||
|
|
|
@ -109,7 +109,7 @@ fn test_no_args() {
|
|||
fn test_no_args_output() {
|
||||
new_ucmd!()
|
||||
.fails()
|
||||
.stderr_is("basename: error: missing operand\nTry 'basename --help' for more information.");
|
||||
.stderr_is("basename: missing operand\nTry 'basename --help' for more information.");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -119,9 +119,10 @@ fn test_too_many_args() {
|
|||
|
||||
#[test]
|
||||
fn test_too_many_args_output() {
|
||||
new_ucmd!().args(&["a", "b", "c"]).fails().stderr_is(
|
||||
"basename: error: extra operand 'c'\nTry 'basename --help' for more information.",
|
||||
);
|
||||
new_ucmd!()
|
||||
.args(&["a", "b", "c"])
|
||||
.fails()
|
||||
.stderr_is("basename: extra operand 'c'\nTry 'basename --help' for more information.");
|
||||
}
|
||||
|
||||
#[cfg(any(unix, target_os = "redox"))]
|
||||
|
|
|
@ -338,7 +338,7 @@ fn test_chmod_preserve_root() {
|
|||
.arg("755")
|
||||
.arg("/")
|
||||
.fails()
|
||||
.stderr_contains(&"chmod: error: it is dangerous to operate recursively on '/'");
|
||||
.stderr_contains(&"chmod: it is dangerous to operate recursively on '/'");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -21,7 +21,7 @@ fn test_enter_chroot_fails() {
|
|||
|
||||
assert!(result
|
||||
.stderr_str()
|
||||
.starts_with("chroot: error: cannot chroot to jail: Operation not permitted (os error 1)"));
|
||||
.starts_with("chroot: cannot chroot to jail: Operation not permitted (os error 1)"));
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -32,7 +32,7 @@ fn test_no_such_directory() {
|
|||
|
||||
ucmd.arg("a")
|
||||
.fails()
|
||||
.stderr_is("chroot: error: cannot change root directory to `a`: no such directory");
|
||||
.stderr_is("chroot: cannot change root directory to `a`: no such directory");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -43,9 +43,7 @@ fn test_invalid_user_spec() {
|
|||
|
||||
let result = ucmd.arg("a").arg("--userspec=ARABA:").fails();
|
||||
|
||||
assert!(result
|
||||
.stderr_str()
|
||||
.starts_with("chroot: error: invalid userspec"));
|
||||
assert!(result.stderr_str().starts_with("chroot: invalid userspec"));
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -66,7 +66,7 @@ fn test_invalid_file() {
|
|||
.arg(folder_name)
|
||||
.fails()
|
||||
.no_stdout()
|
||||
.stderr_contains("cksum: error: 'asdf' No such file or directory");
|
||||
.stderr_contains("cksum: 'asdf' No such file or directory");
|
||||
|
||||
// Then check when the file is of an invalid type
|
||||
at.mkdir(folder_name);
|
||||
|
@ -74,7 +74,7 @@ fn test_invalid_file() {
|
|||
.arg(folder_name)
|
||||
.fails()
|
||||
.no_stdout()
|
||||
.stderr_contains("cksum: error: 'asdf' Is a directory");
|
||||
.stderr_contains("cksum: 'asdf' Is a directory");
|
||||
}
|
||||
|
||||
// Make sure crc is correct for files larger than 32 bytes
|
||||
|
|
|
@ -208,7 +208,7 @@ fn test_up_to_match_repeat_over() {
|
|||
ucmd.args(&["numbers50.txt", "/9$/", "{50}"])
|
||||
.fails()
|
||||
.stdout_is("16\n29\n30\n30\n30\n6\n")
|
||||
.stderr_is("csplit: error: '/9$/': match not found on repetition 5");
|
||||
.stderr_is("csplit: '/9$/': match not found on repetition 5");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -219,7 +219,7 @@ fn test_up_to_match_repeat_over() {
|
|||
ucmd.args(&["numbers50.txt", "/9$/", "{50}", "-k"])
|
||||
.fails()
|
||||
.stdout_is("16\n29\n30\n30\n30\n6\n")
|
||||
.stderr_is("csplit: error: '/9$/': match not found on repetition 5");
|
||||
.stderr_is("csplit: '/9$/': match not found on repetition 5");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -365,7 +365,7 @@ fn test_option_keep() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["-k", "numbers50.txt", "/20/", "/nope/"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/nope/': match not found")
|
||||
.stderr_is("csplit: '/nope/': match not found")
|
||||
.stdout_is("48\n93\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -541,7 +541,7 @@ fn test_up_to_match_context_overflow() {
|
|||
ucmd.args(&["numbers50.txt", "/45/+10"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/45/+10': line number out of range");
|
||||
.stderr_is("csplit: '/45/+10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -552,7 +552,7 @@ fn test_up_to_match_context_overflow() {
|
|||
ucmd.args(&["numbers50.txt", "/45/+10", "-k"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/45/+10': line number out of range");
|
||||
.stderr_is("csplit: '/45/+10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -567,7 +567,7 @@ fn test_skip_to_match_context_underflow() {
|
|||
ucmd.args(&["numbers50.txt", "%5%-10"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '%5%-10': line number out of range");
|
||||
.stderr_is("csplit: '%5%-10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -578,7 +578,7 @@ fn test_skip_to_match_context_underflow() {
|
|||
ucmd.args(&["numbers50.txt", "%5%-10", "-k"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '%5%-10': line number out of range");
|
||||
.stderr_is("csplit: '%5%-10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -592,7 +592,7 @@ fn test_skip_to_match_context_overflow() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%45%+10"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%45%+10': line number out of range");
|
||||
.stderr_only("csplit: '%45%+10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -602,7 +602,7 @@ fn test_skip_to_match_context_overflow() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%45%+10", "-k"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%45%+10': line number out of range");
|
||||
.stderr_only("csplit: '%45%+10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -616,7 +616,7 @@ fn test_up_to_no_match1() {
|
|||
ucmd.args(&["numbers50.txt", "/4/", "/nope/"])
|
||||
.fails()
|
||||
.stdout_is("6\n135\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -627,7 +627,7 @@ fn test_up_to_no_match1() {
|
|||
ucmd.args(&["numbers50.txt", "/4/", "/nope/", "-k"])
|
||||
.fails()
|
||||
.stdout_is("6\n135\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -643,7 +643,7 @@ fn test_up_to_no_match2() {
|
|||
ucmd.args(&["numbers50.txt", "/4/", "/nope/", "{50}"])
|
||||
.fails()
|
||||
.stdout_is("6\n135\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -654,7 +654,7 @@ fn test_up_to_no_match2() {
|
|||
ucmd.args(&["numbers50.txt", "/4/", "/nope/", "{50}", "-k"])
|
||||
.fails()
|
||||
.stdout_is("6\n135\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -670,7 +670,7 @@ fn test_up_to_no_match3() {
|
|||
ucmd.args(&["numbers50.txt", "/0$/", "{50}"])
|
||||
.fails()
|
||||
.stdout_is("18\n30\n30\n30\n30\n3\n")
|
||||
.stderr_is("csplit: error: '/0$/': match not found on repetition 5");
|
||||
.stderr_is("csplit: '/0$/': match not found on repetition 5");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -681,7 +681,7 @@ fn test_up_to_no_match3() {
|
|||
ucmd.args(&["numbers50.txt", "/0$/", "{50}", "-k"])
|
||||
.fails()
|
||||
.stdout_is("18\n30\n30\n30\n30\n3\n")
|
||||
.stderr_is("csplit: error: '/0$/': match not found on repetition 5");
|
||||
.stderr_is("csplit: '/0$/': match not found on repetition 5");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -701,7 +701,7 @@ fn test_up_to_no_match4() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/", "/4/"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -712,7 +712,7 @@ fn test_up_to_no_match4() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/", "/4/", "-k"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -741,7 +741,7 @@ fn test_up_to_no_match6() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/-5"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/-5': match not found");
|
||||
.stderr_is("csplit: '/nope/-5': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -752,7 +752,7 @@ fn test_up_to_no_match6() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/-5", "-k"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/-5': match not found");
|
||||
.stderr_is("csplit: '/nope/-5': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -767,7 +767,7 @@ fn test_up_to_no_match7() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/+5"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/+5': match not found");
|
||||
.stderr_is("csplit: '/nope/+5': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -778,7 +778,7 @@ fn test_up_to_no_match7() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/+5", "-k"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/+5': match not found");
|
||||
.stderr_is("csplit: '/nope/+5': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -792,7 +792,7 @@ fn test_skip_to_no_match1() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%nope%"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%nope%': match not found");
|
||||
.stderr_only("csplit: '%nope%': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -805,7 +805,7 @@ fn test_skip_to_no_match2() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%nope%", "{50}"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%nope%': match not found");
|
||||
.stderr_only("csplit: '%nope%': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -818,7 +818,7 @@ fn test_skip_to_no_match3() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%0$%", "{50}"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%0$%': match not found on repetition 5");
|
||||
.stderr_only("csplit: '%0$%': match not found on repetition 5");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -831,7 +831,7 @@ fn test_skip_to_no_match4() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%nope%", "/4/"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%nope%': match not found");
|
||||
.stderr_only("csplit: '%nope%': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -858,7 +858,7 @@ fn test_skip_to_no_match6() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%nope%-5"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%nope%-5': match not found");
|
||||
.stderr_only("csplit: '%nope%-5': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -871,7 +871,7 @@ fn test_skip_to_no_match7() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%nope%+5"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%nope%+5': match not found");
|
||||
.stderr_only("csplit: '%nope%+5': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -884,7 +884,7 @@ fn test_no_match() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "%nope%"])
|
||||
.fails()
|
||||
.stderr_only("csplit: error: '%nope%': match not found");
|
||||
.stderr_only("csplit: '%nope%': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -895,7 +895,7 @@ fn test_no_match() {
|
|||
ucmd.args(&["numbers50.txt", "/nope/"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '/nope/': match not found");
|
||||
.stderr_is("csplit: '/nope/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -992,7 +992,7 @@ fn test_too_small_linenum_repeat() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "/20/", "10", "{*}"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '10': line number out of range on repetition 5")
|
||||
.stderr_is("csplit: '10': line number out of range on repetition 5")
|
||||
.stdout_is("48\n0\n0\n30\n30\n30\n3\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1003,7 +1003,7 @@ fn test_too_small_linenum_repeat() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "/20/", "10", "{*}", "-k"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '10': line number out of range on repetition 5")
|
||||
.stderr_is("csplit: '10': line number out of range on repetition 5")
|
||||
.stdout_is("48\n0\n0\n30\n30\n30\n3\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1025,7 +1025,7 @@ fn test_linenum_out_of_range1() {
|
|||
ucmd.args(&["numbers50.txt", "100"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '100': line number out of range");
|
||||
.stderr_is("csplit: '100': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1036,7 +1036,7 @@ fn test_linenum_out_of_range1() {
|
|||
ucmd.args(&["numbers50.txt", "100", "-k"])
|
||||
.fails()
|
||||
.stdout_is("141\n")
|
||||
.stderr_is("csplit: error: '100': line number out of range");
|
||||
.stderr_is("csplit: '100': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1051,7 +1051,7 @@ fn test_linenum_out_of_range2() {
|
|||
ucmd.args(&["numbers50.txt", "10", "100"])
|
||||
.fails()
|
||||
.stdout_is("18\n123\n")
|
||||
.stderr_is("csplit: error: '100': line number out of range");
|
||||
.stderr_is("csplit: '100': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1062,7 +1062,7 @@ fn test_linenum_out_of_range2() {
|
|||
ucmd.args(&["numbers50.txt", "10", "100", "-k"])
|
||||
.fails()
|
||||
.stdout_is("18\n123\n")
|
||||
.stderr_is("csplit: error: '100': line number out of range");
|
||||
.stderr_is("csplit: '100': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1078,7 +1078,7 @@ fn test_linenum_out_of_range3() {
|
|||
ucmd.args(&["numbers50.txt", "40", "{2}"])
|
||||
.fails()
|
||||
.stdout_is("108\n33\n")
|
||||
.stderr_is("csplit: error: '40': line number out of range on repetition 1");
|
||||
.stderr_is("csplit: '40': line number out of range on repetition 1");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1089,7 +1089,7 @@ fn test_linenum_out_of_range3() {
|
|||
ucmd.args(&["numbers50.txt", "40", "{2}", "-k"])
|
||||
.fails()
|
||||
.stdout_is("108\n33\n")
|
||||
.stderr_is("csplit: error: '40': line number out of range on repetition 1");
|
||||
.stderr_is("csplit: '40': line number out of range on repetition 1");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1105,7 +1105,7 @@ fn test_linenum_out_of_range4() {
|
|||
ucmd.args(&["numbers50.txt", "40", "{*}"])
|
||||
.fails()
|
||||
.stdout_is("108\n33\n")
|
||||
.stderr_is("csplit: error: '40': line number out of range on repetition 1");
|
||||
.stderr_is("csplit: '40': line number out of range on repetition 1");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1116,7 +1116,7 @@ fn test_linenum_out_of_range4() {
|
|||
ucmd.args(&["numbers50.txt", "40", "{*}", "-k"])
|
||||
.fails()
|
||||
.stdout_is("108\n33\n")
|
||||
.stderr_is("csplit: error: '40': line number out of range on repetition 1");
|
||||
.stderr_is("csplit: '40': line number out of range on repetition 1");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1132,7 +1132,7 @@ fn test_skip_to_match_negative_offset_before_a_match() {
|
|||
ucmd.args(&["numbers50.txt", "/20/-10", "/15/"])
|
||||
.fails()
|
||||
.stdout_is("18\n123\n")
|
||||
.stderr_is("csplit: error: '/15/': match not found");
|
||||
.stderr_is("csplit: '/15/': match not found");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("there should be splits created")
|
||||
|
@ -1177,7 +1177,7 @@ fn test_corner_case2() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "/10/-5", "/10/"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/10/': match not found")
|
||||
.stderr_is("csplit: '/10/': match not found")
|
||||
.stdout_is("8\n133\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1191,7 +1191,7 @@ fn test_corner_case3() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "/15/-3", "14", "/15/"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/15/': match not found")
|
||||
.stderr_is("csplit: '/15/': match not found")
|
||||
.stdout_is("24\n6\n111\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1223,7 +1223,7 @@ fn test_up_to_match_context_underflow() {
|
|||
ucmd.args(&["numbers50.txt", "/5/-10"])
|
||||
.fails()
|
||||
.stdout_is("0\n141\n")
|
||||
.stderr_is("csplit: error: '/5/-10': line number out of range");
|
||||
.stderr_is("csplit: '/5/-10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -1234,7 +1234,7 @@ fn test_up_to_match_context_underflow() {
|
|||
ucmd.args(&["numbers50.txt", "/5/-10", "-k"])
|
||||
.fails()
|
||||
.stdout_is("0\n141\n")
|
||||
.stderr_is("csplit: error: '/5/-10': line number out of range");
|
||||
.stderr_is("csplit: '/5/-10': line number out of range");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
.expect("counting splits")
|
||||
|
@ -1251,7 +1251,7 @@ fn test_linenum_range_with_up_to_match1() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "10", "/12/-5"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/12/-5': line number out of range")
|
||||
.stderr_is("csplit: '/12/-5': line number out of range")
|
||||
.stdout_is("18\n0\n123\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1262,7 +1262,7 @@ fn test_linenum_range_with_up_to_match1() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "10", "/12/-5", "-k"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/12/-5': line number out of range")
|
||||
.stderr_is("csplit: '/12/-5': line number out of range")
|
||||
.stdout_is("18\n0\n123\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1281,7 +1281,7 @@ fn test_linenum_range_with_up_to_match2() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "10", "/12/-15"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/12/-15': line number out of range")
|
||||
.stderr_is("csplit: '/12/-15': line number out of range")
|
||||
.stdout_is("18\n0\n123\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1292,7 +1292,7 @@ fn test_linenum_range_with_up_to_match2() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "10", "/12/-15", "-k"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/12/-15': line number out of range")
|
||||
.stderr_is("csplit: '/12/-15': line number out of range")
|
||||
.stdout_is("18\n0\n123\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
@ -1310,7 +1310,7 @@ fn test_linenum_range_with_up_to_match3() {
|
|||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
ucmd.args(&["numbers50.txt", "10", "/10/", "-k"])
|
||||
.fails()
|
||||
.stderr_is("csplit: error: '/10/': match not found")
|
||||
.stderr_is("csplit: '/10/': match not found")
|
||||
.stdout_is("18\n123\n");
|
||||
|
||||
let count = glob(&at.plus_as_string("xx*"))
|
||||
|
|
|
@ -149,11 +149,11 @@ fn test_directory_and_no_such_file() {
|
|||
ucmd.arg("-b1")
|
||||
.arg("some")
|
||||
.run()
|
||||
.stderr_is("cut: error: some: Is a directory\n");
|
||||
.stderr_is("cut: some: Is a directory\n");
|
||||
|
||||
new_ucmd!()
|
||||
.arg("-b1")
|
||||
.arg("some")
|
||||
.run()
|
||||
.stderr_is("cut: error: some: No such file or directory\n");
|
||||
.stderr_is("cut: some: No such file or directory\n");
|
||||
}
|
||||
|
|
|
@ -76,7 +76,7 @@ fn test_du_basics_bad_name() {
|
|||
new_ucmd!()
|
||||
.arg("bad_name")
|
||||
.succeeds() // TODO: replace with ".fails()" once `du` is fixed
|
||||
.stderr_only("du: error: bad_name: No such file or directory\n");
|
||||
.stderr_only("du: bad_name: No such file or directory\n");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -17,11 +17,11 @@ fn test_complex_arithmetic() {
|
|||
.args(&["9223372036854775807", "+", "9223372036854775807"])
|
||||
.run();
|
||||
run.stdout_is("");
|
||||
run.stderr_is("expr: error: +: Numerical result out of range");
|
||||
run.stderr_is("expr: +: Numerical result out of range");
|
||||
|
||||
let run = new_ucmd!().args(&["9", "/", "0"]).run();
|
||||
run.stdout_is("");
|
||||
run.stderr_is("expr: error: division by zero");
|
||||
run.stderr_is("expr: division by zero");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -30,7 +30,7 @@ fn test_fmt_w_too_big() {
|
|||
//.stdout_is_fixture("call_graph.expected");
|
||||
assert_eq!(
|
||||
result.stderr_str().trim(),
|
||||
"fmt: error: invalid width: '2501': Numerical result out of range"
|
||||
"fmt: invalid width: '2501': Numerical result out of range"
|
||||
);
|
||||
}
|
||||
#[test]
|
||||
|
|
|
@ -7,7 +7,7 @@ use crate::common::util::*;
|
|||
// From the Logs: "Build (ubuntu-18.04, x86_64-unknown-linux-gnu, feat_os_unix, use-cross)"
|
||||
// stderr: "whoami: cannot find name for user ID 1001"
|
||||
// Maybe: "adduser --uid 1001 username" can put things right?
|
||||
// stderr = id: error: Could not find uid 1001: No such id: 1001
|
||||
// stderr = id: Could not find uid 1001: No such id: 1001
|
||||
fn skipping_test_is_okay(result: &CmdResult, needle: &str) -> bool {
|
||||
if !result.succeeded() {
|
||||
println!("result.stdout = {}", result.stdout_str());
|
||||
|
|
|
@ -301,7 +301,7 @@ fn test_install_target_new_file_with_group() {
|
|||
.arg(format!("{}/{}", dir, file))
|
||||
.run();
|
||||
|
||||
if is_ci() && result.stderr_str().contains("error: no such group:") {
|
||||
if is_ci() && result.stderr_str().contains("no such group:") {
|
||||
// In the CI, some server are failing to return the group.
|
||||
// As seems to be a configuration issue, ignoring it
|
||||
return;
|
||||
|
|
|
@ -148,7 +148,7 @@ fn multitab_character() {
|
|||
.arg("-t")
|
||||
.arg("э")
|
||||
.fails()
|
||||
.stderr_is("join: error: multi-character tab э");
|
||||
.stderr_is("join: multi-character tab э");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -211,7 +211,7 @@ fn empty_format() {
|
|||
.arg("-o")
|
||||
.arg("")
|
||||
.fails()
|
||||
.stderr_is("join: error: invalid file number in field spec: ''");
|
||||
.stderr_is("join: invalid file number in field spec: ''");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -23,7 +23,7 @@ fn test_link_no_circular() {
|
|||
|
||||
ucmd.args(&[link, link])
|
||||
.fails()
|
||||
.stderr_is("link: error: No such file or directory (os error 2)\n");
|
||||
.stderr_is("link: No such file or directory (os error 2)\n");
|
||||
assert!(!at.file_exists(link));
|
||||
}
|
||||
|
||||
|
@ -35,7 +35,7 @@ fn test_link_nonexistent_file() {
|
|||
|
||||
ucmd.args(&[file, link])
|
||||
.fails()
|
||||
.stderr_is("link: error: No such file or directory (os error 2)\n");
|
||||
.stderr_is("link: No such file or directory (os error 2)\n");
|
||||
assert!(!at.file_exists(file));
|
||||
assert!(!at.file_exists(link));
|
||||
}
|
||||
|
|
|
@ -409,7 +409,7 @@ fn test_symlink_missing_destination() {
|
|||
at.touch(file);
|
||||
|
||||
ucmd.args(&["-s", "-T", file]).fails().stderr_is(format!(
|
||||
"ln: error: missing destination file operand after '{}'",
|
||||
"ln: missing destination file operand after '{}'",
|
||||
file
|
||||
));
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@ fn test_normal() {
|
|||
for (key, value) in env::vars() {
|
||||
println!("{}: {}", key, value);
|
||||
}
|
||||
if (is_ci() || uucore::os::is_wsl_1()) && result.stderr_str().contains("error: no login name") {
|
||||
if (is_ci() || uucore::os::is_wsl_1()) && result.stderr_str().contains("no login name") {
|
||||
// ToDO: investigate WSL failure
|
||||
// In the CI, some server are failing to return logname.
|
||||
// As seems to be a configuration issue, ignoring it
|
||||
|
|
|
@ -167,7 +167,7 @@ fn test_ls_width() {
|
|||
.ucmd()
|
||||
.args(&option.split(" ").collect::<Vec<_>>())
|
||||
.fails()
|
||||
.stderr_only("ls: error: invalid line width: ‘1a’");
|
||||
.stderr_only("ls: invalid line width: ‘1a’");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -875,7 +875,7 @@ fn test_ls_files_dirs() {
|
|||
.ucmd()
|
||||
.arg("doesntexist")
|
||||
.fails()
|
||||
.stderr_contains(&"error: 'doesntexist': No such file or directory");
|
||||
.stderr_contains(&"'doesntexist': No such file or directory");
|
||||
|
||||
// One exists, the other doesn't
|
||||
scene
|
||||
|
@ -883,7 +883,7 @@ fn test_ls_files_dirs() {
|
|||
.arg("a")
|
||||
.arg("doesntexist")
|
||||
.fails()
|
||||
.stderr_contains(&"error: 'doesntexist': No such file or directory")
|
||||
.stderr_contains(&"'doesntexist': No such file or directory")
|
||||
.stdout_contains(&"a:");
|
||||
}
|
||||
|
||||
|
|
|
@ -2,9 +2,7 @@ use crate::common::util::*;
|
|||
|
||||
#[test]
|
||||
fn test_create_fifo_missing_operand() {
|
||||
new_ucmd!()
|
||||
.fails()
|
||||
.stderr_is("mkfifo: error: missing operand");
|
||||
new_ucmd!().fails().stderr_is("mkfifo: missing operand");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -43,5 +41,5 @@ fn test_create_one_fifo_already_exists() {
|
|||
.arg("abcdef")
|
||||
.arg("abcdef")
|
||||
.fails()
|
||||
.stderr_is("mkfifo: error: cannot create fifo 'abcdef': File exists");
|
||||
.stderr_is("mkfifo: cannot create fifo 'abcdef': File exists");
|
||||
}
|
||||
|
|
|
@ -120,7 +120,7 @@ fn test_mktemp_mktemp_t() {
|
|||
.arg(TEST_TEMPLATE8)
|
||||
.fails()
|
||||
.no_stdout()
|
||||
.stderr_contains("error: suffix cannot contain any path separators");
|
||||
.stderr_contains("suffix cannot contain any path separators");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -472,7 +472,7 @@ fn test_mv_overwrite_nonempty_dir() {
|
|||
at.touch(dummy);
|
||||
// Not same error as GNU; the error message is a rust builtin
|
||||
// TODO: test (and implement) correct error message (or at least decide whether to do so)
|
||||
// Current: "mv: error: couldn't rename path (Directory not empty; from=a; to=b)"
|
||||
// Current: "mv: couldn't rename path (Directory not empty; from=a; to=b)"
|
||||
// GNU: "mv: cannot move ‘a’ to ‘b’: Directory not empty"
|
||||
|
||||
// Verbose output for the move should not be shown on failure
|
||||
|
@ -539,7 +539,7 @@ fn test_mv_errors() {
|
|||
.arg(dir)
|
||||
.fails()
|
||||
.stderr_is(format!(
|
||||
"mv: error: cannot overwrite directory ‘{}’ with non-directory\n",
|
||||
"mv: cannot overwrite directory ‘{}’ with non-directory\n",
|
||||
dir
|
||||
));
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ fn test_adjustment_with_no_command_should_error() {
|
|||
new_ucmd!()
|
||||
.args(&["-n", "19"])
|
||||
.run()
|
||||
.stderr_is("nice: error: A command must be given with an adjustment.\nTry \"nice --help\" for more information.\n");
|
||||
.stderr_is("nice: A command must be given with an adjustment.\nTry \"nice --help\" for more information.\n");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -258,7 +258,7 @@ fn test_rm_no_operand() {
|
|||
let mut ucmd = new_ucmd!();
|
||||
|
||||
ucmd.fails()
|
||||
.stderr_is("rm: error: missing an argument\nrm: error: for help, try 'rm --help'\n");
|
||||
.stderr_is("rm: missing an argument\nrm: for help, try 'rm --help'\n");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -39,7 +39,7 @@ fn test_rmdir_nonempty_directory_no_parents() {
|
|||
assert!(at.file_exists(file));
|
||||
|
||||
ucmd.arg(dir).fails().stderr_is(
|
||||
"rmdir: error: failed to remove 'test_rmdir_nonempty_no_parents': Directory not \
|
||||
"rmdir: failed to remove 'test_rmdir_nonempty_no_parents': Directory not \
|
||||
empty\n",
|
||||
);
|
||||
|
||||
|
@ -59,9 +59,9 @@ fn test_rmdir_nonempty_directory_with_parents() {
|
|||
assert!(at.file_exists(file));
|
||||
|
||||
ucmd.arg("-p").arg(dir).fails().stderr_is(
|
||||
"rmdir: error: failed to remove 'test_rmdir_nonempty/with/parents': Directory not \
|
||||
empty\nrmdir: error: failed to remove 'test_rmdir_nonempty/with': Directory not \
|
||||
empty\nrmdir: error: failed to remove 'test_rmdir_nonempty': Directory not \
|
||||
"rmdir: failed to remove 'test_rmdir_nonempty/with/parents': Directory not \
|
||||
empty\nrmdir: failed to remove 'test_rmdir_nonempty/with': Directory not \
|
||||
empty\nrmdir: failed to remove 'test_rmdir_nonempty': Directory not \
|
||||
empty\n",
|
||||
);
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ fn test_invalid_buffer_size() {
|
|||
.arg(invalid_buffer_size)
|
||||
.fails()
|
||||
.stderr_only(format!(
|
||||
"sort: error: failed to parse buffer size `{}`: invalid digit found in string",
|
||||
"sort: failed to parse buffer size `{}`: invalid digit found in string",
|
||||
invalid_buffer_size
|
||||
));
|
||||
}
|
||||
|
@ -471,7 +471,7 @@ fn test_keys_invalid_field() {
|
|||
new_ucmd!()
|
||||
.args(&["-k", "1."])
|
||||
.fails()
|
||||
.stderr_only("sort: error: failed to parse character index for key `1.`: cannot parse integer from empty string");
|
||||
.stderr_only("sort: failed to parse character index for key `1.`: cannot parse integer from empty string");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -479,7 +479,7 @@ fn test_keys_invalid_field_option() {
|
|||
new_ucmd!()
|
||||
.args(&["-k", "1.1x"])
|
||||
.fails()
|
||||
.stderr_only("sort: error: invalid option for key: `x`");
|
||||
.stderr_only("sort: invalid option for key: `x`");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -487,14 +487,15 @@ fn test_keys_invalid_field_zero() {
|
|||
new_ucmd!()
|
||||
.args(&["-k", "0.1"])
|
||||
.fails()
|
||||
.stderr_only("sort: error: field index was 0");
|
||||
.stderr_only("sort: field index was 0");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_keys_invalid_char_zero() {
|
||||
new_ucmd!().args(&["-k", "1.0"]).fails().stderr_only(
|
||||
"sort: error: invalid character index 0 in `1.0` for the start position of a field",
|
||||
);
|
||||
new_ucmd!()
|
||||
.args(&["-k", "1.0"])
|
||||
.fails()
|
||||
.stderr_only("sort: invalid character index 0 in `1.0` for the start position of a field");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -26,7 +26,7 @@ fn test_stdbuf_line_buffered_stdout() {
|
|||
#[test]
|
||||
fn test_stdbuf_no_buffer_option_fails() {
|
||||
new_ucmd!().args(&["head"]).fails().stderr_is(
|
||||
"error: The following required arguments were not provided:\n \
|
||||
"The following required arguments were not provided:\n \
|
||||
--error <MODE>\n \
|
||||
--input <MODE>\n \
|
||||
--output <MODE>\n\n\
|
||||
|
@ -49,10 +49,9 @@ fn test_stdbuf_trailing_var_arg() {
|
|||
#[cfg(not(target_os = "windows"))]
|
||||
#[test]
|
||||
fn test_stdbuf_line_buffering_stdin_fails() {
|
||||
new_ucmd!()
|
||||
.args(&["-i", "L", "head"])
|
||||
.fails()
|
||||
.stderr_is("stdbuf: error: line buffering stdin is meaningless\nTry 'stdbuf --help' for more information.");
|
||||
new_ucmd!().args(&["-i", "L", "head"]).fails().stderr_is(
|
||||
"stdbuf: line buffering stdin is meaningless\nTry 'stdbuf --help' for more information.",
|
||||
);
|
||||
}
|
||||
|
||||
#[cfg(not(target_os = "windows"))]
|
||||
|
@ -61,5 +60,5 @@ fn test_stdbuf_invalid_mode_fails() {
|
|||
new_ucmd!()
|
||||
.args(&["-i", "1024R", "head"])
|
||||
.fails()
|
||||
.stderr_is("stdbuf: error: invalid mode 1024R\nTry 'stdbuf --help' for more information.");
|
||||
.stderr_is("stdbuf: invalid mode 1024R\nTry 'stdbuf --help' for more information.");
|
||||
}
|
||||
|
|
|
@ -59,9 +59,7 @@ fn test_invalid_file() {
|
|||
|
||||
at.mkdir("a");
|
||||
|
||||
ucmd.arg("a")
|
||||
.fails()
|
||||
.stderr_is("sum: error: 'a' Is a directory");
|
||||
ucmd.arg("a").fails().stderr_is("sum: 'a' Is a directory");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -70,5 +68,5 @@ fn test_invalid_metadata() {
|
|||
|
||||
ucmd.arg("b")
|
||||
.fails()
|
||||
.stderr_is("sum: error: 'b' No such file or directory");
|
||||
.stderr_is("sum: 'b' No such file or directory");
|
||||
}
|
||||
|
|
|
@ -145,7 +145,7 @@ fn test_invalid_utf8() {
|
|||
.arg("not-utf8-sequence.txt")
|
||||
.run()
|
||||
.failure()
|
||||
.stderr_only("uniq: error: invalid utf-8 sequence of 1 bytes from index 0");
|
||||
.stderr_only("uniq: invalid utf-8 sequence of 1 bytes from index 0");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -22,7 +22,7 @@ fn test_unlink_multiple_files() {
|
|||
at.touch(file_b);
|
||||
|
||||
ucmd.arg(file_a).arg(file_b).fails().stderr_is(
|
||||
"unlink: error: extra operand: 'test_unlink_multiple_file_b'\nTry 'unlink --help' \
|
||||
"unlink: extra operand: 'test_unlink_multiple_file_b'\nTry 'unlink --help' \
|
||||
for more information.\n",
|
||||
);
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ fn test_unlink_directory() {
|
|||
at.mkdir(dir);
|
||||
|
||||
ucmd.arg(dir).fails().stderr_is(
|
||||
"unlink: error: cannot unlink 'test_unlink_empty_directory': Not a regular file \
|
||||
"unlink: cannot unlink 'test_unlink_empty_directory': Not a regular file \
|
||||
or symlink\n",
|
||||
);
|
||||
}
|
||||
|
@ -45,7 +45,7 @@ fn test_unlink_nonexistent() {
|
|||
let file = "test_unlink_nonexistent";
|
||||
|
||||
new_ucmd!().arg(file).fails().stderr_is(
|
||||
"unlink: error: Cannot stat 'test_unlink_nonexistent': No such file or directory \
|
||||
"unlink: Cannot stat 'test_unlink_nonexistent': No such file or directory \
|
||||
(os error 2)\n",
|
||||
);
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@ use crate::common::util::*;
|
|||
// considered okay. If we are not inside the CI this calls assert!(result.success).
|
||||
//
|
||||
// From the Logs: "Build (ubuntu-18.04, x86_64-unknown-linux-gnu, feat_os_unix, use-cross)"
|
||||
// stderr: "whoami: error: failed to get username"
|
||||
// stderr: "whoami: failed to get username"
|
||||
// Maybe: "adduser --uid 1001 username" can put things right?
|
||||
fn skipping_test_is_okay(result: &CmdResult, needle: &str) -> bool {
|
||||
if !result.succeeded() {
|
||||
|
|
Loading…
Reference in a new issue