Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[tests-only][full-ci] adding test for editing shared file(OCM) by the share receiver #10523

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions tests/acceptance/features/apiOcm/share.feature
Original file line number Diff line number Diff line change
Expand Up @@ -618,3 +618,24 @@ Feature: an user shares resources using ScienceMesh application
}
}
"""

@issue-9898
Scenario: user lists permissions of a resource shared to a federated user
Given using server "LOCAL"
And "Alice" has created the federation share invitation
And using server "REMOTE"
And "Brian" has accepted invitation
And using server "LOCAL"
And user "Alice" has uploaded file with content "ocm test" to "/textfile.txt"
And user "Alice" has sent the following resource share invitation to federated user:
| resource | textfile.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
| federatedServer | @federation-ocis-server:10200 |
And using server "REMOTE"
And for user "Brian" the content of the file "/textfile.txt" of the space "Shares" should be "ocm test"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please, refer to #10536
and you will need to do something like

if ($server === 'REMOTE' && $spaceName === 'Shares') {
$credentials = $this->featureContext->graphContext->getAdminOrUserCredentials($user);
$response = GraphHelper::getSharesSharedWithMe(
$this->featureContext->getBaseUrl(),
done (WIP) in #10415

When user "Brian" uploads a file inside space "Shares" with content "this is a new content" to "/textfile.txt" using the WebDAV API
Then the HTTP status code should be "201"
And for user "Brian" the content of the file "/textfile.txt" of the space "Shares" should be "this is a new content"