summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjoern Schiessle <schiessle@owncloud.com>2014-06-04 13:00:32 +0200
committerRobin Appelman <icewind@owncloud.com>2014-06-06 09:56:02 +0200
commit09970e1816644661d4ad1984793232c880aac1ac (patch)
tree8ddce4f188f3494382d123450a61fc9bcfa1584a
parent574de2d91b1bb913385e308d5e53b0e7faa29d8e (diff)
downloadnextcloud-server-09970e1816644661d4ad1984793232c880aac1ac.tar.gz
nextcloud-server-09970e1816644661d4ad1984793232c880aac1ac.zip
update unit tests and make sure that we return the right permissions for files within a shared folder and for the shared folder itself
-rw-r--r--apps/files_sharing/tests/permissions.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/files_sharing/tests/permissions.php b/apps/files_sharing/tests/permissions.php
index 5ac251b0527..0a222b08512 100644
--- a/apps/files_sharing/tests/permissions.php
+++ b/apps/files_sharing/tests/permissions.php
@@ -111,5 +111,10 @@ class Test_Files_Sharing_Permissions extends Test_Files_Sharing_Base {
$this->assertEquals(7, $contents[0]['permissions']);
$this->assertEquals('textfile1.txt', $contents[1]['name']);
$this->assertEquals(7, $contents[1]['permissions']);
+
+ // the share mount point should always have delete permissions to allow the user
+ // to unmount it
+ $restrictedShare = $this->secondView->getFileInfo('files/shareddirrestricted');
+ $this->assertEquals(7 | \OCP\PERMISSION_DELETE, $restrictedShare['permissions']);
}
}