summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJörn Friedrich Dreyer <jfd@butonic.de>2015-04-02 11:28:10 +0200
committerJörn Friedrich Dreyer <jfd@butonic.de>2015-04-10 09:12:37 +0200
commita85bc5538fbc5013e386058f3b1caf191e94b148 (patch)
tree1270222324e292365c5f917aada0efaee656d6cc /tests
parentb069f33a72fde9ef0f0d502ca2e1c78f777155c7 (diff)
downloadnextcloud-server-a85bc5538fbc5013e386058f3b1caf191e94b148.tar.gz
nextcloud-server-a85bc5538fbc5013e386058f3b1caf191e94b148.zip
fix filesystem and encryption tests
Conflicts: apps/files_encryption/lib/util.php apps/files_encryption/tests/hooks.php
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/files/filesystem.php11
1 files changed, 4 insertions, 7 deletions
diff --git a/tests/lib/files/filesystem.php b/tests/lib/files/filesystem.php
index 98e96e0cc78..a01b15eb2df 100644
--- a/tests/lib/files/filesystem.php
+++ b/tests/lib/files/filesystem.php
@@ -22,6 +22,8 @@
namespace Test\Files;
+use OC\User\NoUserException;
+
class Filesystem extends \Test\TestCase {
/**
* @var array tmpDirs
@@ -259,19 +261,14 @@ class Filesystem extends \Test\TestCase {
}
/**
- * Tests that a local storage mount is used when passed user
- * does not exist.
+ * Tests that an exception is thrown when passed user does not exist.
+ * @expectedException \OC\User\NoUserException
*/
public function testLocalMountWhenUserDoesNotExist() {
$datadir = \OC_Config::getValue("datadirectory", \OC::$SERVERROOT . "/data");
$userId = $this->getUniqueID('user_');
\OC\Files\Filesystem::initMountPoints($userId);
-
- $homeMount = \OC\Files\Filesystem::getStorage('/' . $userId . '/');
-
- $this->assertTrue($homeMount->instanceOfStorage('\OC\Files\Storage\Local'));
- $this->assertEquals('local::' . $datadir . '/' . $userId . '/', $homeMount->getId());
}
/**