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-22 23:45:05 -04:00
parent 70e65c419f
commit a746e37dc7
+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");
}