-
Notifications
You must be signed in to change notification settings - Fork 190
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding test for disabling mail and in-app notifications
- Loading branch information
1 parent
c0772c0
commit 112ab53
Showing
2 changed files
with
153 additions
and
9 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
50 changes: 50 additions & 0 deletions
50
tests/acceptance/features/apiNotification/notificationSetting.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,50 @@ | ||
Feature: Notification Settings | ||
As a user | ||
I want to manage my notification settings | ||
So that i am not bothered by unimportant events | ||
|
||
|
||
Scenario: disable mail and in-app notification | ||
Given these users have been created with default attributes: | ||
| username | | ||
| Alice | | ||
| Brian | | ||
And user "Alice" has uploaded file with content "other data" to "textfile.txt" | ||
And user "Alice" has uploaded file with content "other data" to "textfile1.txt" | ||
And user "Alice" has sent the following resource share invitation: | ||
| resource | textfile.txt | | ||
| space | Personal | | ||
| sharee | Brian | | ||
| shareType | user | | ||
| permissionsRole | Viewer | | ||
When user "Brian" updates following notification settings: | ||
| mail | false | | ||
| in-app | false | | ||
Then the HTTP status code should be "201" | ||
And user "Alice" has sent the following resource share invitation: | ||
| resource | textfile1.txt | | ||
| space | Personal | | ||
| sharee | Brian | | ||
| shareType | user | | ||
| permissionsRole | Viewer | | ||
And user "Brian" should have received the following email from user "Alice" | ||
""" | ||
Hello Brian Murphy | ||
%displayname% has shared "textfile.txt" with you. | ||
Click here to view it: %base_url%/files/shares/with-me | ||
""" | ||
And user "Brian" should not have received the following email from user "Alice" | ||
""" | ||
Hello Brian Murphy | ||
%displayname% has shared "textfile1.txt" with you. | ||
Click here to view it: %base_url%/files/shares/with-me | ||
""" | ||
And user "Brian" should have a notification with subject "Resource shared" and message: | ||
| message | | ||
| Alice Hansen shared textfile.txt with you | | ||
But user "Brian" should not have a notification related to resource "textfile1.txt" with subject "Resource shared" |