summaryrefslogtreecommitdiffstats
path: root/apps/files_external/tests/smb.php
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2012-05-24 18:22:33 +0200
committerRobin Appelman <icewind@owncloud.com>2012-05-24 18:23:59 +0200
commit2f40f11c873b22881ad3ed21549253e53b6927ca (patch)
treed5bcbfab706363b5c151922dfd74417cfae9f990 /apps/files_external/tests/smb.php
parentbee724c53e243bda82c9490154fcd13079e41082 (diff)
downloadnextcloud-server-2f40f11c873b22881ad3ed21549253e53b6927ca.tar.gz
nextcloud-server-2f40f11c873b22881ad3ed21549253e53b6927ca.zip
smb filestorage backend
Diffstat (limited to 'apps/files_external/tests/smb.php')
-rw-r--r--apps/files_external/tests/smb.php30
1 files changed, 30 insertions, 0 deletions
diff --git a/apps/files_external/tests/smb.php b/apps/files_external/tests/smb.php
new file mode 100644
index 00000000000..52e1700b019
--- /dev/null
+++ b/apps/files_external/tests/smb.php
@@ -0,0 +1,30 @@
+<?php
+/**
+ * Copyright (c) 2012 Robin Appelman <icewind@owncloud.com>
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+ */
+
+$config=include('apps/files_external/tests/config.php');
+
+if(!is_array($config) or !isset($config['smb']) or !$config['smb']['run']){
+ abstract class Test_Filestorage_SMB extends Test_FileStorage{}
+ return;
+}else{
+ class Test_Filestorage_SMB extends Test_FileStorage {
+ private $config;
+ private $id;
+
+ public function setUp(){
+ $id=uniqid();
+ $this->config=include('apps/files_external/tests/config.php');
+ $this->config['smb']['root'].='/'.$id;//make sure we have an new empty folder to work in
+ $this->instance=new OC_Filestorage_SMB($this->config['smb']);
+ }
+
+ public function tearDown(){
+ OCP\Files::rmdirr($this->instance->constructUrl(''));
+ }
+ }
+}