2017-10-03 03:29:23 +08:00
|
|
|
// Test Webdav filesystem interface
|
2022-05-20 17:06:55 +08:00
|
|
|
package webdav
|
2017-10-03 03:29:23 +08:00
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
2022-05-20 17:06:55 +08:00
|
|
|
"github.com/rclone/rclone/fs"
|
2019-10-04 23:51:07 +08:00
|
|
|
"github.com/rclone/rclone/fstest"
|
2019-07-29 01:47:38 +08:00
|
|
|
"github.com/rclone/rclone/fstest/fstests"
|
2017-10-03 03:29:23 +08:00
|
|
|
)
|
|
|
|
|
2018-04-08 01:48:11 +08:00
|
|
|
// TestIntegration runs integration tests against the remote
|
|
|
|
func TestIntegration(t *testing.T) {
|
|
|
|
fstests.Run(t, &fstests.Opt{
|
Spelling fixes
Fix spelling of: above, already, anonymous, associated,
authentication, bandwidth, because, between, blocks, calculate,
candidates, cautious, changelog, cleaner, clipboard, command,
completely, concurrently, considered, constructs, corrupt, current,
daemon, dependencies, deprecated, directory, dispatcher, download,
eligible, ellipsis, encrypter, endpoint, entrieslist, essentially,
existing writers, existing, expires, filesystem, flushing, frequently,
hierarchy, however, implementation, implements, inaccurate,
individually, insensitive, longer, maximum, metadata, modified,
multipart, namedirfirst, nextcloud, obscured, opened, optional,
owncloud, pacific, passphrase, password, permanently, persimmon,
positive, potato, protocol, quota, receiving, recommends, referring,
requires, revisited, satisfied, satisfies, satisfy, semver,
serialized, session, storage, strategies, stringlist, successful,
supported, surprise, temporarily, temporary, transactions, unneeded,
update, uploads, wrapped
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-09 08:17:24 +08:00
|
|
|
RemoteName: "TestWebdavNextcloud:",
|
2022-05-20 17:06:55 +08:00
|
|
|
NilObject: (*Object)(nil),
|
|
|
|
ChunkedUpload: fstests.ChunkedUploadConfig{
|
|
|
|
MinChunkSize: 1 * fs.Mebi,
|
|
|
|
},
|
2019-10-04 23:51:07 +08:00
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// TestIntegration runs integration tests against the remote
|
|
|
|
func TestIntegration2(t *testing.T) {
|
|
|
|
if *fstest.RemoteName != "" {
|
|
|
|
t.Skip("skipping as -remote is set")
|
|
|
|
}
|
|
|
|
fstests.Run(t, &fstests.Opt{
|
|
|
|
RemoteName: "TestWebdavOwncloud:",
|
2022-05-20 17:06:55 +08:00
|
|
|
NilObject: (*Object)(nil),
|
|
|
|
ChunkedUpload: fstests.ChunkedUploadConfig{
|
|
|
|
Skip: true,
|
|
|
|
},
|
2019-10-04 23:51:07 +08:00
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// TestIntegration runs integration tests against the remote
|
|
|
|
func TestIntegration3(t *testing.T) {
|
|
|
|
if *fstest.RemoteName != "" {
|
|
|
|
t.Skip("skipping as -remote is set")
|
|
|
|
}
|
|
|
|
fstests.Run(t, &fstests.Opt{
|
|
|
|
RemoteName: "TestWebdavRclone:",
|
2022-05-20 17:06:55 +08:00
|
|
|
NilObject: (*Object)(nil),
|
|
|
|
ChunkedUpload: fstests.ChunkedUploadConfig{
|
|
|
|
Skip: true,
|
|
|
|
},
|
2018-04-08 01:48:11 +08:00
|
|
|
})
|
2017-10-03 03:29:23 +08:00
|
|
|
}
|
2019-01-17 20:35:30 +08:00
|
|
|
|
|
|
|
// TestIntegration runs integration tests against the remote
|
|
|
|
func TestIntegration4(t *testing.T) {
|
|
|
|
if *fstest.RemoteName != "" {
|
|
|
|
t.Skip("skipping as -remote is set")
|
|
|
|
}
|
|
|
|
fstests.Run(t, &fstests.Opt{
|
|
|
|
RemoteName: "TestWebdavNTLM:",
|
2022-05-20 17:06:55 +08:00
|
|
|
NilObject: (*Object)(nil),
|
2019-01-17 20:35:30 +08:00
|
|
|
})
|
|
|
|
}
|
2022-05-20 17:06:55 +08:00
|
|
|
|
|
|
|
func (f *Fs) SetUploadChunkSize(cs fs.SizeSuffix) (fs.SizeSuffix, error) {
|
|
|
|
return f.setUploadChunkSize(cs)
|
|
|
|
}
|