summaryrefslogtreecommitdiffstats
path: root/apps/files_encryption/tests/share.php
diff options
context:
space:
mode:
authorBjoern Schiessle <schiessle@owncloud.com>2013-08-17 13:15:22 +0200
committerBjoern Schiessle <schiessle@owncloud.com>2013-08-17 13:15:22 +0200
commitcabe92ef1240e171a812f5822ac69b4d7742fd71 (patch)
tree469e9089107d440da0c12c291abbd626d6d08b33 /apps/files_encryption/tests/share.php
parent7adfc27cafa6f94962a33c158af9c45e71e012c5 (diff)
parentd3e2f31adad5eeaf415154dd2fb88cb9fec0b3c1 (diff)
downloadnextcloud-server-cabe92ef1240e171a812f5822ac69b4d7742fd71.tar.gz
nextcloud-server-cabe92ef1240e171a812f5822ac69b4d7742fd71.zip
Merge branch 'master' into decrypt_files_again
Conflicts: apps/files_encryption/tests/keymanager.php
Diffstat (limited to 'apps/files_encryption/tests/share.php')
-rwxr-xr-xapps/files_encryption/tests/share.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/apps/files_encryption/tests/share.php b/apps/files_encryption/tests/share.php
index 0fe16976c4d..59d4adc6fee 100755
--- a/apps/files_encryption/tests/share.php
+++ b/apps/files_encryption/tests/share.php
@@ -884,8 +884,13 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase {
\OC_FileProxy::$enabled = $proxyStatus;
// share the file
- \OCP\Share::shareItem('file', $fileInfo['fileid'], \OCP\Share::SHARE_TYPE_GROUP, \Test_Encryption_Share::TEST_ENCRYPTION_SHARE_GROUP1, OCP\PERMISSION_ALL);
-
+ try {
+ \OCP\Share::shareItem('file', $fileInfo['fileid'], \OCP\Share::SHARE_TYPE_GROUP, \Test_Encryption_Share::TEST_ENCRYPTION_SHARE_GROUP1, OCP\PERMISSION_ALL);
+ } catch (Exception $e) {
+ $this->assertEquals(0, strpos($e->getMessage(), "Following users are not set up for encryption"));
+ }
+
+
// login as admin
\Test_Encryption_Util::loginHelper(\Test_Encryption_Share::TEST_ENCRYPTION_SHARE_USER1);