Skip to content

Commit

Permalink
add test to upload via TUS by federated user
Browse files Browse the repository at this point in the history
Signed-off-by: prashant-gurung899 <[email protected]>
  • Loading branch information
prashant-gurung899 committed Oct 25, 2024
1 parent 84a9da5 commit 35308d7
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions tests/acceptance/features/apiOcm/share.feature
Original file line number Diff line number Diff line change
Expand Up @@ -618,3 +618,30 @@ Feature: an user shares resources using ScienceMesh application
}
}
"""

@issue-10285
Scenario: federated user upload file to a shared folder via TUS
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 created a folder "FOLDER" in space "Personal"
And user "Alice" has sent the following resource share invitation to federated user:
| resource | FOLDER |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | Viewer |
| federatedServer | @federation-ocis-server:10200 |
And using server "REMOTE"
And user "Brian" has created a new TUS resource on the WebDAV API with these headers:
| Upload-Length | 10 |
# L0ZPTERFUi90ZXh0RmlsZS50eHQ= is the base64 encode of /FOLDER/textFile.txt
| Upload-Metadata | filename L0ZPTERFUi90ZXh0RmlsZS50eHQ= |
| Tus-Resumable | 1.0.0 |
When user "Brian" sends a chunk to the last created TUS Location with offset "0" and data "123" using the WebDAV API
And user "Brian" sends a chunk to the last created TUS Location with offset "0" and data "000" using the WebDAV API
And user "Brian" sends a chunk to the last created TUS Location with offset "3" and data "4567890" using the WebDAV API
Then the HTTP status code should be "204"
And the content of file "/file.txt" for user "Brian" should be "1234567890"

0 comments on commit 35308d7

Please sign in to comment.