From 4c82b1f3c68a908920ba8a4bef979950ad9d3478 Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Mon, 16 Mar 2020 14:05:49 +0000 Subject: [PATCH] operations: fix --max-transfer test with jottacloud Jottacloud was deduplicating the uploads, so make a different upload each time --- fs/operations/operations_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/operations/operations_test.go b/fs/operations/operations_test.go index e084f90f1..20d00e4af 100644 --- a/fs/operations/operations_test.go +++ b/fs/operations/operations_test.go @@ -44,6 +44,7 @@ import ( "github.com/rclone/rclone/fs/hash" "github.com/rclone/rclone/fs/operations" "github.com/rclone/rclone/fstest" + "github.com/rclone/rclone/lib/random" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) @@ -1545,7 +1546,7 @@ func TestCopyFileMaxTransfer(t *testing.T) { const sizeCutoff = 2048 file1 := r.WriteFile("file1", "file1 contents", t1) - file2 := r.WriteFile("file2", "file2 contents"+string(make([]byte, sizeCutoff)), t2) + file2 := r.WriteFile("file2", "file2 contents"+random.String(sizeCutoff), t2) rfile1 := file1 rfile1.Path = "sub/file1"