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] check HTTP status code in favorite tests #37543

Merged
merged 1 commit into from
Jun 17, 2020
Merged
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
27 changes: 18 additions & 9 deletions tests/acceptance/features/apiFavorites/favorites.feature
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ Feature: favorite
Scenario Outline: Favorite a folder
Given using <dav_version> DAV path
When user "Alice" favorites element "/FOLDER" using the WebDAV API
Then as user "Alice" folder "/FOLDER" should be favorited
Then the HTTP status code should be "207"
And as user "Alice" folder "/FOLDER" should be favorited
When user "Alice" gets the following properties of folder "/FOLDER" using the WebDAV API
| propertyName |
| oc:favorite |
Expand All @@ -30,7 +31,8 @@ Feature: favorite
Given using <dav_version> DAV path
When user "Alice" favorites element "/FOLDER" using the WebDAV API
And user "Alice" unfavorites element "/FOLDER" using the WebDAV API
Then as user "Alice" folder "/FOLDER" should not be favorited
Then the HTTP status code should be "207"
And as user "Alice" folder "/FOLDER" should not be favorited
When user "Alice" gets the following properties of folder "/FOLDER" using the WebDAV API
| propertyName |
| oc:favorite |
Expand All @@ -44,7 +46,8 @@ Feature: favorite
Scenario Outline: Favorite a file
Given using <dav_version> DAV path
When user "Alice" favorites element "/textfile0.txt" using the WebDAV API
Then as user "Alice" file "/textfile0.txt" should be favorited
Then the HTTP status code should be "207"
And as user "Alice" file "/textfile0.txt" should be favorited
When user "Alice" gets the following properties of file "/textfile0.txt" using the WebDAV API
| propertyName |
| oc:favorite |
Expand All @@ -59,7 +62,8 @@ Feature: favorite
Given using <dav_version> DAV path
When user "Alice" favorites element "/textfile0.txt" using the WebDAV API
And user "Alice" unfavorites element "/textfile0.txt" using the WebDAV API
Then as user "Alice" file "/textfile0.txt" should not be favorited
Then the HTTP status code should be "207"
And as user "Alice" file "/textfile0.txt" should not be favorited
When user "Alice" gets the following properties of file "/textfile0.txt" using the WebDAV API
| propertyName |
| oc:favorite |
Expand All @@ -76,7 +80,8 @@ Feature: favorite
When user "Alice" favorites element "/FOLDER" using the WebDAV API
And user "Alice" favorites element "/textfile0.txt" using the WebDAV API
And user "Alice" favorites element "/textfile1.txt" using the WebDAV API
Then user "Alice" in folder "/" should have favorited the following elements
Then the HTTP status code should be "207"
And user "Alice" in folder "/" should have favorited the following elements
| /FOLDER |
| /textfile0.txt |
| /textfile1.txt |
Expand All @@ -96,7 +101,8 @@ Feature: favorite
And user "Alice" favorites element "/subfolder/textfile1.txt" using the WebDAV API
And user "Alice" favorites element "/subfolder/textfile2.txt" using the WebDAV API
And user "Alice" unfavorites element "/subfolder/textfile1.txt" using the WebDAV API
Then user "Alice" in folder "/subfolder" should have favorited the following elements
Then the HTTP status code should be "207"
And user "Alice" in folder "/subfolder" should have favorited the following elements
| /subfolder/textfile0.txt |
| /subfolder/textfile2.txt |
And user "Alice" in folder "/subfolder" should not have favorited the following elements
Expand Down Expand Up @@ -183,7 +189,8 @@ Feature: favorite
And user "Alice" has moved file "/textfile0.txt" to "/favoriteFile.txt"
And user "Alice" has shared file "/favoriteFile.txt" with user "Brian"
When user "Alice" favorites element "/favoriteFile.txt" using the WebDAV API
Then as user "Brian" file "/favoriteFile.txt" should not be favorited
Then the HTTP status code should be "207"
And as user "Brian" file "/favoriteFile.txt" should not be favorited
Examples:
| dav_version |
| old |
Expand All @@ -197,7 +204,8 @@ Feature: favorite
And user "Alice" has moved file "/textfile0.txt" to "/favoriteFile.txt"
And user "Alice" has shared file "/favoriteFile.txt" with user "Brian"
When user "Brian" favorites element "/favoriteFile.txt" using the WebDAV API
Then as user "Alice" file "/favoriteFile.txt" should not be favorited
Then the HTTP status code should be "207"
And as user "Alice" file "/favoriteFile.txt" should not be favorited
Examples:
| dav_version |
| old |
Expand All @@ -208,7 +216,8 @@ Feature: favorite
Given using <dav_version> DAV path
When user "Alice" favorites element "/PARENT/parent.txt" using the WebDAV API
And user "Alice" favorites element "/PARENT" using the WebDAV API
Then user "Alice" in folder "/" should have favorited the following elements
Then the HTTP status code should be "207"
And user "Alice" in folder "/" should have favorited the following elements
| /PARENT |
| /PARENT/parent.txt |
Examples:
Expand Down