mirror of
https://github.com/rclone/rclone.git
synced 2025-08-13 23:38:51 +02:00
committed by
Nick Craig-Wood
parent
1be1fc073e
commit
cc0800a72e
@ -64,6 +64,20 @@ func TestCopy(t *testing.T) {
|
||||
fstest.CheckItems(t, r.Fremote, file1)
|
||||
}
|
||||
|
||||
func TestCopyMissingDirectory(t *testing.T) {
|
||||
r := fstest.NewRun(t)
|
||||
defer r.Finalise()
|
||||
r.Mkdir(context.Background(), r.Fremote)
|
||||
|
||||
nonExistingFs, err := fs.NewFs("/non-existing")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
err = CopyDir(context.Background(), r.Fremote, nonExistingFs, false)
|
||||
require.Error(t, err)
|
||||
}
|
||||
|
||||
// Now with --no-traverse
|
||||
func TestCopyNoTraverse(t *testing.T) {
|
||||
r := fstest.NewRun(t)
|
||||
|
Reference in New Issue
Block a user