diff options
author | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-04-23 23:19:11 +0200 |
---|---|---|
committer | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-04-23 23:19:11 +0200 |
commit | c5d3f09262dac29703b33112571a1e067dc27a4e (patch) | |
tree | ab5d927747c2583a2d5b2dc896a28b3d1da9e4d3 /apps/files_external/tests | |
parent | cfbf81f97836e35fdfbebb9f6c5f44534a09383b (diff) | |
download | nextcloud-server-c5d3f09262dac29703b33112571a1e067dc27a4e.tar.gz nextcloud-server-c5d3f09262dac29703b33112571a1e067dc27a4e.zip |
test case for iRODS storage added
Diffstat (limited to 'apps/files_external/tests')
-rw-r--r-- | apps/files_external/tests/irods.php | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/apps/files_external/tests/irods.php b/apps/files_external/tests/irods.php new file mode 100644 index 00000000000..614e5bc7c3a --- /dev/null +++ b/apps/files_external/tests/irods.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. + */ + +namespace Test\Files\Storage; + +class iRODS extends Storage { + + private $config; + + public function setUp() { + $id = uniqid(); + $this->config = include('files_external/tests/config.php'); + if ( ! is_array($this->config) or ! isset($this->config['irods']) or ! $this->config['irods']['run']) { + $this->markTestSkipped('irods backend not configured'); + } + $this->config['irods']['root'] .= $id; //make sure we have an new empty folder to work in + $this->instance = new \OC\Files\Storage\iRODS($this->config['irods']); + } + + public function tearDown() { + if ($this->instance) { + \OCP\Files::rmdirr($this->instance->constructUrl('')); + } + } +} |