mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 06:30:08 +02:00
Fix cp bug (#5642)
This commit is contained in:
@ -318,3 +318,16 @@ fn copy_dir_symlink_file_body_not_changed() {
|
||||
assert!(actual.contains("hello_data"));
|
||||
});
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn copy_identical_file() {
|
||||
Playground::setup("cp_test_15", |_dirs, sandbox| {
|
||||
sandbox.with_files(vec![EmptyFile("same.txt")]);
|
||||
|
||||
let actual = nu!(
|
||||
cwd: sandbox.cwd(),
|
||||
"cp same.txt same.txt",
|
||||
);
|
||||
assert!(actual.err.contains("Copy aborted"));
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user