mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 11:37:44 +00:00
cp: modify archive flag to copy dir contents rather than dir
This commit is contained in:
parent
bc0273f48f
commit
fe4da2b8e5
2 changed files with 12 additions and 1 deletions
|
@ -2532,3 +2532,14 @@ fn test_src_base_dot() {
|
|||
.no_stdout();
|
||||
assert!(!at.dir_exists("y/x"));
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(not(windows))]
|
||||
fn test_cp_archive_on_directory_ending_dot() {
|
||||
let (at, mut ucmd) = at_and_ucmd!();
|
||||
at.mkdir("dir1");
|
||||
at.mkdir("dir2");
|
||||
at.touch("dir1/file");
|
||||
ucmd.args(&["-a", "dir1/.", "dir2"]).succeeds();
|
||||
assert!(at.file_exists("dir2/file"));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue