summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJörn Friedrich Dreyer <jfd@butonic.de>2015-10-01 13:23:30 +0200
committerMorris Jobke <hey@morrisjobke.de>2015-10-09 12:35:37 +0200
commitc8640cdcb02868e5d9766806000e3785ba2ae0ad (patch)
tree2e4e969ec2be6a4f86647ed2cd649faae92e567c /tests
parent020bb33150ddaab4463b63799774f144a3448263 (diff)
downloadnextcloud-server-c8640cdcb02868e5d9766806000e3785ba2ae0ad.tar.gz
nextcloud-server-c8640cdcb02868e5d9766806000e3785ba2ae0ad.zip
adjust filesystem tests to objectstore
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/files/filesystem.php15
1 files changed, 12 insertions, 3 deletions
diff --git a/tests/lib/files/filesystem.php b/tests/lib/files/filesystem.php
index cc01ed70b5d..15a7c235405 100644
--- a/tests/lib/files/filesystem.php
+++ b/tests/lib/files/filesystem.php
@@ -325,8 +325,14 @@ class Filesystem extends \Test\TestCase {
$homeMount = \OC\Files\Filesystem::getStorage('/' . $userId . '/');
- $this->assertTrue($homeMount->instanceOfStorage('\OC\Files\Storage\Home'));
- $this->assertEquals('home::' . $userId, $homeMount->getId());
+ $this->assertTrue($homeMount->instanceOfStorage('\OCP\Files\IHomeStorage'));
+ if (getenv('RUN_OBJECTSTORE_TESTS')) {
+ $this->assertTrue($homeMount->instanceOfStorage('\OC\Files\ObjectStore\HomeObjectStoreStorage'));
+ $this->assertEquals('object::user:' . $userId, $homeMount->getId());
+ } else {
+ $this->assertTrue($homeMount->instanceOfStorage('\OC\Files\Storage\Home'));
+ $this->assertEquals('home::' . $userId, $homeMount->getId());
+ }
\OC_User::deleteUser($userId);
}
@@ -336,6 +342,9 @@ class Filesystem extends \Test\TestCase {
* for the user's mount point
*/
public function testLegacyHomeMount() {
+ if (getenv('RUN_OBJECTSTORE_TESTS')) {
+ $this->markTestSkipped('legacy storage unrelated to objectstore environments');
+ }
$datadir = \OC_Config::getValue("datadirectory", \OC::$SERVERROOT . "/data");
$userId = $this->getUniqueID('user_');
@@ -380,7 +389,7 @@ class Filesystem extends \Test\TestCase {
\OC\Files\Filesystem::getMountPoint('/' . $userId . '/cache')
);
list($storage, $internalPath) = \OC\Files\Filesystem::resolvePath('/' . $userId . '/cache');
- $this->assertTrue($storage->instanceOfStorage('\OC\Files\Storage\Home'));
+ $this->assertTrue($storage->instanceOfStorage('\OCP\Files\IHomeStorage'));
$this->assertEquals('cache', $internalPath);
\OC_User::deleteUser($userId);