mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-04 11:19:39 -06:00
Merge pull request #9969 from owncloud/test-different-view-mode
[tests-only][full-ci] test: add test coverage for opening file using /app/open-with-web endpoint with different view mode
This commit is contained in:
@@ -466,3 +466,30 @@ Feature: collaboration (wopi)
|
||||
| app-endpoint | url-query |
|
||||
| /app/open-with-web?file_id=<<FILEID>>&app_name=FakeOffice | app=FakeOffice& |
|
||||
| /app/open-with-web?file_id=<<FILEID>> | |
|
||||
|
||||
|
||||
Scenario Outline: open file with .odt extension with different view mode (open-with-web)
|
||||
Given user "Alice" has uploaded file "filesForUpload/simple.odt" to "simple.odt"
|
||||
And we save it into "FILEID"
|
||||
When user "Alice" sends HTTP method "POST" to URL "<app-endpoint>"
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"uri"
|
||||
],
|
||||
"properties": {
|
||||
"uri": {
|
||||
"type": "string",
|
||||
"pattern": "%base_url%/external\\?app=FakeOffice&contextRouteName=files-spaces-personal&fileId=%uuidv4_pattern%%24%uuidv4_pattern%%21%uuidv4_pattern%$"
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| app-endpoint |
|
||||
| /app/open-with-web?file_id=<<FILEID>>&app_name=FakeOffice&view_mode=view |
|
||||
| /app/open-with-web?file_id=<<FILEID>>&app_name=FakeOffice&view_mode=read |
|
||||
| /app/open-with-web?file_id=<<FILEID>>&app_name=FakeOffice&view_mode=write |
|
||||
|
||||
Reference in New Issue
Block a user