-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #39092 from owncloud/refactor-previews-tests
[tests-only] [full-ci] Refactor previews tests so they can run on oC10 or OCIS
- Loading branch information
Showing
3 changed files
with
58 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
tests/acceptance/features/apiWebdavPreviews/previewsAutoAdustedSizing.feature
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
@api @preview-extension-required | ||
Feature: sizing of previews of files downloaded through the webdav API | ||
As a user | ||
I want the aspect-ratio of previews to be preserved even when I ask for an unusual preview size | ||
So that the previews always have a similar look-and-feel to the original file | ||
|
||
This is optional behavior of an implementation. OCIS happens like this, | ||
but oC10 does not do this auto-fix of the aspect ratio. | ||
|
||
Background: | ||
Given user "Alice" has been created with default attributes and without skeleton files | ||
|
||
@skipOnOcV10 | ||
Scenario Outline: download different sizes of previews of file | ||
Given user "Alice" has uploaded file "filesForUpload/lorem.txt" to "/parent.txt" | ||
When user "Alice" downloads the preview of "/parent.txt" with width <request_width> and height <request_height> using the WebDAV API | ||
Then the HTTP status code should be "200" | ||
And the downloaded image should be <return_width> pixels wide and <return_height> pixels high | ||
Examples: | ||
| request_width | request_height | return_width | return_height | | ||
| 1 | 1 | 16 | 16 | | ||
| 32 | 32 | 32 | 32 | | ||
| 1024 | 1024 | 640 | 480 | | ||
| 1 | 1024 | 16 | 16 | | ||
| 1024 | 1 | 640 | 480 | |
25 changes: 25 additions & 0 deletions
25
tests/acceptance/features/apiWebdavPreviews/previewsExactSizing.feature
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
@api @preview-extension-required | ||
Feature: sizing of previews of files downloaded through the webdav API | ||
As a user | ||
I want previews to be the exact requested size even when I ask for an unusual preview size combination | ||
So that the previews always have the exact size that I want as a user/client. | ||
|
||
This is optional behavior of an implementation. oC10 happens like this, | ||
but OCIS does an auto-fix of the aspect ratio. | ||
|
||
Background: | ||
Given user "Alice" has been created with default attributes and without skeleton files | ||
|
||
@skipOnOcis | ||
Scenario Outline: download different sizes of previews of file | ||
Given user "Alice" has uploaded file "filesForUpload/lorem.txt" to "/parent.txt" | ||
When user "Alice" downloads the preview of "/parent.txt" with width <width> and height <height> using the WebDAV API | ||
Then the HTTP status code should be "200" | ||
And the downloaded image should be <width> pixels wide and <height> pixels high | ||
Examples: | ||
| width | height | | ||
| 1 | 1 | | ||
| 32 | 32 | | ||
| 1024 | 1024 | | ||
| 1 | 1024 | | ||
| 1024 | 1 | |