allow cross folder renaming if the underlying resource is the same

this was only allowed for the local filesystem before this change

Signed-off-by: Nicola Murino <nicola.murino@gmail.com>
This commit is contained in:
Nicola Murino
2022-08-15 21:39:04 +02:00
parent c86db09cd8
commit ced4206c5f
18 changed files with 558 additions and 70 deletions

View File

@@ -198,8 +198,9 @@ func TestHTTPFsVirtualFolder(t *testing.T) {
Provider: sdk.HTTPFilesystemProvider,
HTTPConfig: vfs.HTTPFsConfig{
BaseHTTPFsConfig: sdk.BaseHTTPFsConfig{
Endpoint: fmt.Sprintf("http://127.0.0.1:%d/api/v1", httpFsPort),
Username: defaultHTTPFsUsername,
Endpoint: fmt.Sprintf("http://127.0.0.1:%d/api/v1", httpFsPort),
Username: defaultHTTPFsUsername,
EqualityCheckMode: 1,
},
},
},
@@ -240,6 +241,7 @@ func TestHTTPFsVirtualFolder(t *testing.T) {
func TestHTTPFsWalk(t *testing.T) {
user := getTestUserWithHTTPFs(false)
user.FsConfig.HTTPConfig.EqualityCheckMode = 1
httpFs, err := user.GetFilesystem("")
require.NoError(t, err)
basePath := filepath.Join(os.TempDir(), "httpfs", user.FsConfig.HTTPConfig.Username)