Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

Fix tests on Windows

Nick Craig-Woodda2e2544ee81
diff --git a/fstest/fstests/fstests.go b/fstest/fstests/fstests.go
index 44453089d..e2d66df2e 100644
--- a/fstest/fstests/fstests.go
+++ b/fstest/fstests/fstests.go
@@ -13,6 +13,7 @@ import (
"io/ioutil"
"os"
"path"
+ "path/filepath"
"sort"
"strings"
"testing"
@@ -147,9 +148,11 @@ func TestFsRoot(t *testing.T) {
name := remote.Name() + ":"
root := remote.Root()
if isLocalRemote {
- name = ""
+ // only check last path element on local
+ require.Equal(t, filepath.Base(subRemoteName), filepath.Base(root))
+ } else {
+ require.Equal(t, subRemoteName, name+root)
}
- require.Equal(t, subRemoteName, name+root)
}
// TestFsRmdirEmpty tests deleting an empty directory