truncate: add test for -r and -s options together

Add a test for when the reference file is not found and both `-r` and
`-s` options are given on the command-line.
This commit is contained in:
Jeffrey Finkelstein
2021-05-29 15:11:27 +02:00
committed by Jan Scheer
parent 17b0939dee
commit 4e73b919e9
+8
View File
@@ -262,3 +262,11 @@ fn test_reference_file_not_found() {
.fails()
.stderr_contains("cannot stat 'a': No such file or directory");
}
#[test]
fn test_reference_with_size_file_not_found() {
new_ucmd!()
.args(&["-r", "a", "-s", "+1", "b"])
.fails()
.stderr_contains("cannot stat 'a': No such file or directory");
}