From fdb7de8c93bf1c4c171cb9f4cb7f4767c921f2d0 Mon Sep 17 00:00:00 2001 From: nirajacharya2 <122071597+nirajacharya2@users.noreply.github.com> Date: Thu, 25 Apr 2024 12:26:07 +0545 Subject: [PATCH] adding test for listing permission of a project drive by a member with viewer permission (#8910) --- .../apiSharingNg/listPermissions.feature | 41 +++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/tests/acceptance/features/apiSharingNg/listPermissions.feature b/tests/acceptance/features/apiSharingNg/listPermissions.feature index 003b5ac0349..4cf7f7d6d55 100644 --- a/tests/acceptance/features/apiSharingNg/listPermissions.feature +++ b/tests/acceptance/features/apiSharingNg/listPermissions.feature @@ -1525,3 +1525,44 @@ Feature: List a sharing permissions | space | new-space | | sharee | Brian | | shareType | user | + + + + Scenario: try to list the permissions of a user's personal space by a different member + Given using spaces DAV path + And user "Brian" has been created with default attributes and without skeleton files + When user "Brian" tries to list the permissions of space "Personal" owned by "Alice" using permissions endpoint of the Graph API + Then the HTTP status code should be "404" + And the JSON data of the response should match + """ + { + "type": "object", + "required": ["error"], + "properties": { + "error": { + "type": "object", + "required": [ + "code", + "innererror", + "message" + ], + "properties": { + "code": { + "const": "itemNotFound" + }, + "innererror": { + "type": "object", + "required": [ + "date", + "request-id" + ] + }, + "message": { + "type": "string", + "pattern": "stat: error: not found: %file_id_pattern%$" + } + } + } + } + } + """ \ No newline at end of file