Skip to content

Commit 488fa5a

Browse files
disable email notifications
Signed-off-by: prashant-gurung899 <prasantgrg777@gmail.com>
1 parent aa3ccac commit 488fa5a

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

tests/acceptance/features/apiOcm/ocmNotifications.feature

+59
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,62 @@ Feature: ocm notifications
100100
Then the HTTP status code should be "200"
101101
And the notifications should be empty
102102
And user "Brian" should have "0" emails
103+
104+
@email
105+
Scenario: federated user disables email notification
106+
Given using server "LOCAL"
107+
And user "Alice" has uploaded file with content "ocm test" to "textfile.txt"
108+
And "Alice" has created the federation share invitation
109+
And using server "REMOTE"
110+
And "Brian" has accepted invitation
111+
When user "Brian" disables email notification using the settings API
112+
Then the HTTP status code should be "201"
113+
And the JSON data of the response should match
114+
"""
115+
{
116+
"type": "object",
117+
"required": ["value"],
118+
"properties": {
119+
"value": {
120+
"type": "object",
121+
"required": ["identifier","value"],
122+
"properties": {
123+
"identifier":{
124+
"type": "object",
125+
"required": ["extension","bundle","setting"],
126+
"properties": {
127+
"extension":{ "const": "ocis-accounts" },
128+
"bundle":{ "const": "profile" },
129+
"setting":{ "const": "disable-email-notifications" }
130+
}
131+
},
132+
"value":{
133+
"type": "object",
134+
"required": ["id","bundleId","settingId","accountUuid","resource"],
135+
"properties":{
136+
"id":{ "pattern": "%uuidv4_pattern%" },
137+
"bundleId":{ "pattern":"%uuidv4_pattern%" },
138+
"settingId":{ "pattern":"%uuidv4_pattern%" },
139+
"accountUuid":{ "pattern":"%uuidv4_pattern%" },
140+
"resource":{
141+
"type": "object",
142+
"required":["type"],
143+
"properties": {
144+
"type":{ "const": "TYPE_USER" }
145+
}
146+
}
147+
}
148+
}
149+
}
150+
}
151+
}
152+
}
153+
"""
154+
And using server "LOCAL"
155+
And user "Alice" has sent the following resource share invitation to federated user:
156+
| resource | textfile.txt |
157+
| space | Personal |
158+
| sharee | Brian |
159+
| shareType | user |
160+
| permissionsRole | Viewer |
161+
And user "Brian" should have "0" emails

0 commit comments

Comments
 (0)