diff options
author | Robin Appelman <robin@icewind.nl> | 2018-06-21 16:00:58 +0200 |
---|---|---|
committer | Robin Appelman <robin@icewind.nl> | 2018-06-21 16:03:57 +0200 |
commit | 60816a2e4a9cb2b1906c07abcb80079aa21ce37a (patch) | |
tree | c6600277855eebfc72111a8d7d1a751881be13f0 | |
parent | 4a424f86db7ceeb9f90e925cd76d890c5487af64 (diff) | |
download | nextcloud-server-60816a2e4a9cb2b1906c07abcb80079aa21ce37a.tar.gz nextcloud-server-60816a2e4a9cb2b1906c07abcb80079aa21ce37a.zip |
use DAV instead of SMB for deletion tests
SMB storages can't be constructed on drone because of missing dependencies
Signed-off-by: Robin Appelman <robin@icewind.nl>
-rw-r--r-- | apps/files_external/tests/Service/StoragesServiceTest.php | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/apps/files_external/tests/Service/StoragesServiceTest.php b/apps/files_external/tests/Service/StoragesServiceTest.php index b875bcb55e6..44fa6c31b7d 100644 --- a/apps/files_external/tests/Service/StoragesServiceTest.php +++ b/apps/files_external/tests/Service/StoragesServiceTest.php @@ -134,6 +134,7 @@ abstract class StoragesServiceTest extends \Test\TestCase { $sftpBackend = $this->getBackendMock('\OCA\Files_External\Lib\Backend\SFTP', '\OCA\Files_External\Lib\Storage\SFTP'); $backends = [ + 'identifier:\OCA\Files_External\Lib\Backend\DAV' => $this->getBackendMock('\OCA\Files_External\Lib\Backend\DAV', '\OC\Files\Storage\DAV'), 'identifier:\OCA\Files_External\Lib\Backend\SMB' => $this->getBackendMock('\OCA\Files_External\Lib\Backend\SMB', '\OCA\Files_External\Lib\Storage\SMB'), 'identifier:\OCA\Files_External\Lib\Backend\SFTP' => $sftpBackend, 'identifier:sftp_alias' => $sftpBackend, @@ -269,25 +270,23 @@ abstract class StoragesServiceTest extends \Test\TestCase { // regular case, can properly delete the oc_storages entry [ [ - 'share' => 'share', 'host' => 'example.com', 'user' => 'test', 'password' => 'testPassword', 'root' => 'someroot', ], - 'smb::test@example.com//share//someroot/', + 'webdav::test@example.com//someroot/', 0 ], // special case with $user vars, cannot auto-remove the oc_storages entry [ [ - 'share' => 'share', 'host' => 'example.com', 'user' => '$user', 'password' => 'testPassword', 'root' => 'someroot', ], - 'smb::someone@example.com//share//someroot/', + 'webdav::someone@example.com//someroot/', 1 ], ]; @@ -297,7 +296,7 @@ abstract class StoragesServiceTest extends \Test\TestCase { * @dataProvider deleteStorageDataProvider */ public function testDeleteStorage($backendOptions, $rustyStorageId, $expectedCountAfterDeletion) { - $backend = $this->backendService->getBackend('identifier:\OCA\Files_External\Lib\Backend\SMB'); + $backend = $this->backendService->getBackend('identifier:\OCA\Files_External\Lib\Backend\DAV'); $authMechanism = $this->backendService->getAuthMechanism('identifier:\Auth\Mechanism'); $storage = new StorageConfig(255); $storage->setMountPoint('mountpoint'); |