-
Notifications
You must be signed in to change notification settings - Fork 156
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Tests-Only] Refactor webUISharingNotifications to use Shares folder
- Loading branch information
1 parent
2f6dae6
commit 7f1658b
Showing
8 changed files
with
129 additions
and
4 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
2 changes: 1 addition & 1 deletion
2
...ingNotifications/notificationLink.feature → ...ificationsToRoot/notificationLink.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
2 changes: 1 addition & 1 deletion
2
...ringNotifications/shareWithGroups.feature → ...tificationsToRoot/shareWithGroups.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
2 changes: 1 addition & 1 deletion
2
...aringNotifications/shareWithUsers.feature → ...otificationsToRoot/shareWithUsers.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
21 changes: 21 additions & 0 deletions
21
tests/acceptance/features/webUISharingNotificationsToShares/notificationLink.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,21 @@ | ||
@app-required @notifications-app-required @ocis-reva-issue-64 | ||
Feature: Display notifications when receiving a share and follow embedded links | ||
As a user | ||
I want to use the notification header as a link | ||
So that I will be redirected to the most appropriate screen | ||
|
||
Background: | ||
Given app "notifications" has been enabled | ||
And these users have been created with default attributes: | ||
| username | | ||
| user1 | | ||
| user2 | | ||
And user "user2" has logged in using the webUI | ||
|
||
@smokeTest | ||
@skip @yetToImplement | ||
Scenario: notification link redirection in case a share is pending | ||
Given the setting "Automatically accept new incoming local user shares" in the section "Sharing" has been disabled | ||
And user "user1" has shared folder "/simple-folder" with user "user2" | ||
When the user follows the link of the first notification on the webUI | ||
Then the user should be redirected to a webUI page with the title "Shared with you - %productname%" |
37 changes: 37 additions & 0 deletions
37
tests/acceptance/features/webUISharingNotificationsToShares/shareWithGroups.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,37 @@ | ||
@app-required @notifications-app-required @ocis-reva-issue-64 | ||
Feature: Sharing files and folders with internal groups | ||
As a user | ||
I want to share files and folders with groups | ||
So that those groups can access the files and folders | ||
|
||
Background: | ||
Given the setting "shareapi_auto_accept_share" of app "core" has been set to "no" | ||
And the administrator has set the default folder for received shares to "Shares" | ||
And app "notifications" has been enabled | ||
And these users have been created with default attributes: | ||
| username | | ||
| user1 | | ||
| user2 | | ||
| user3 | | ||
And these groups have been created: | ||
| groupname | | ||
| grp1 | | ||
And user "user1" has been added to group "grp1" | ||
And user "user2" has been added to group "grp1" | ||
And user "user2" has logged in using the webUI | ||
|
||
Scenario: notifications about new share is displayed | ||
Given user "user3" has shared folder "/simple-folder" with group "grp1" | ||
And user "user3" has shared folder "/data.zip" with group "grp1" | ||
When the user reloads the current page of the webUI | ||
Then the user should see the notification bell on the webUI | ||
And the user should see 2 notifications on the webUI with these details | ||
| title | | ||
| "User Three" shared "simple-folder" with you | | ||
| "User Three" shared "data.zip" with you | | ||
When the user re-logs in as "user1" using the webUI | ||
Then the user should see 2 notifications on the webUI with these details | ||
| title | | ||
| "User Three" shared "simple-folder" with you | | ||
| "User Three" shared "data.zip" with you | | ||
|
60 changes: 60 additions & 0 deletions
60
tests/acceptance/features/webUISharingNotificationsToShares/shareWithUsers.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,60 @@ | ||
@app-required @notifications-app-required @ocis-reva-issue-64 | ||
Feature: Sharing files and folders with internal users | ||
As a user | ||
I want to share files and folders with other users | ||
So that those users can access the files and folders | ||
|
||
Background: | ||
Given the setting "shareapi_auto_accept_share" of app "core" has been set to "no" | ||
And the administrator has set the default folder for received shares to "Shares" | ||
And app "notifications" has been enabled | ||
And these users have been created with default attributes: | ||
| username | | ||
| user1 | | ||
| user2 | | ||
|
||
@smokeTest | ||
Scenario: notifications about new share is displayed when auto-accepting is disabled | ||
Given user "user1" has shared folder "simple-folder" with user "user2" | ||
And user "user1" has shared folder "data.zip" with user "user2" | ||
When user "user2" logs in using the webUI | ||
Then the user should see the notification bell on the webUI | ||
And the user should see 2 notifications on the webUI with these details | ||
| title | | ||
| "User One" shared "simple-folder" with you | | ||
| "User One" shared "data.zip" with you | | ||
|
||
@smokeTest | ||
Scenario: Notification is gone after accepting a share | ||
Given user "user1" has shared folder "simple-folder" with user "user2" | ||
And user "user1" has shared folder "simple-empty-folder" with user "user2" | ||
When user "user2" logs in using the webUI | ||
And the user accepts all shares displayed in the notifications on the webUI | ||
Then the user should have no notifications | ||
|
||
@smokeTest | ||
Scenario: accept an offered share | ||
Given user "user1" has shared folder "simple-folder" with user "user2" | ||
And user "user1" has shared folder "simple-empty-folder" with user "user2" | ||
When user "user2" logs in using the webUI | ||
And the user accepts all shares displayed in the notifications on the webUI | ||
And the user reloads the current page of the webUI | ||
And the user browses to the folder "Shares" on the files page | ||
Then folder "simple-folder" should be listed on the webUI | ||
And folder "simple-empty-folder" should be listed on the webUI | ||
When the user browses to the shared-with-me page using the webUI | ||
Then folder "simple-folder" shared by "User One" should be in "Accepted" state on the webUI | ||
And folder "simple-empty-folder" shared by "User One" should be in "Accepted" state on the webUI | ||
|
||
@smokeTest | ||
Scenario: reject an offered share | ||
Given user "user1" has shared folder "simple-folder" with user "user2" | ||
And user "user1" has shared folder "simple-empty-folder" with user "user2" | ||
When user "user2" logs in using the webUI | ||
And the user declines all shares displayed in the notifications on the webUI | ||
Then folder "simple-folder (2)" should not be listed on the webUI | ||
And folder "simple-empty-folder (2)" should not be listed on the webUI | ||
When the user browses to the shared-with-me page using the webUI | ||
Then folder "simple-folder" shared by "User One" should be in "Declined" state on the webUI | ||
And folder "simple-empty-folder" shared by "User One" should be in "Declined" state on the webUI | ||
|
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