blob: 26a3130421f12f3dd9cc9c97561744c7c7546b53 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
|
Feature: conversation/avatar
Background:
Given user "participant1" exists
Given user "participant2" exists
And guest accounts can be created
And user "user-guest@example.com" is a guest account user
Scenario: Misteps
Given user "participant1" creates room "room1" (v4)
| roomType | 3 |
| roomName | room1 |
Then user "participant1" uploads file "invalid" as avatar of room "room1" with 400
And user "participant2" uploads file "/img/favicon.png" as avatar of room "room1" with 404
And user "participant2" delete the avatar of room "room1" with 404
Scenario: Define an image as avatar with success
Given user "participant1" creates room "room2" (v4)
| roomType | 3 |
| roomName | room2 |
When user "participant1" uploads file "/img/favicon.png" as avatar of room "room2" with 200
Then user "participant1" gets room "room2" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 1 |
And the room "room2" has not an svg as avatar with 200
And user "participant1" sees the following system messages in room "room2" with 200
| room | actorType | actorId | systemMessage | message |
| room2 | users | participant1 | avatar_set | You set the conversation picture |
| room2 | users | participant1 | conversation_created | You created the conversation |
When user "participant1" delete the avatar of room "room2" with 200
Then user "participant1" sees the following system messages in room "room2" with 200
| room | actorType | actorId | systemMessage | message |
| room2 | users | participant1 | avatar_removed | You removed the conversation picture |
| room2 | users | participant1 | avatar_set | You set the conversation picture |
| room2 | users | participant1 | conversation_created | You created the conversation |
And user "participant1" gets room "room2" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
Then the room "room2" has an avatar with 200
Scenario: Get avatar of conversation without custom avatar (fallback)
Given user "participant1" creates room "room3" (v4)
| roomType | 3 |
| roomName | room3 |
Then the room "room3" has an avatar with 200
And user "participant1" gets room "room3" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
Scenario: Get avatar of conversation without being a participant
Given user "participant1" creates room "room3" (v4)
| roomType | 3 |
| roomName | room3 |
Then the room "room3" has an avatar with 200
And user "participant1" gets room "room3" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
And as user "participant2"
And the room "room3" has an avatar with 404
And as user "user-guest@example.com"
And the room "room3" has an avatar with 404
And as user "guest"
And the room "room3" has an avatar with 404
When user "participant1" allows listing room "room3" for "users" with 200 (v4)
And as user "participant2"
And the room "room3" has an avatar with 200
And as user "user-guest@example.com"
And the room "room3" has an avatar with 404
And as user "guest"
And the room "room3" has an avatar with 404
When user "participant1" allows listing room "room3" for "all" with 200 (v4)
And as user "participant2"
And the room "room3" has an avatar with 200
And as user "user-guest@example.com"
And the room "room3" has an avatar with 200
And as user "guest"
And the room "room3" has an avatar with 404
Scenario: Get avatar of one2one without custom avatar (fallback)
When user "participant1" creates room "one2one" (v4)
| roomType | 1 |
| invite | participant2 |
Then the room "one2one" has an avatar with 200
And user "participant1" gets room "one2one" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
Scenario: Try to change avatar of one2one without success
When user "participant1" creates room "one2one" (v4)
| roomType | 1 |
| invite | participant2 |
Then user "participant1" uploads file "/img/favicon.png" as avatar of room "one2one" with 400
And user "participant1" gets room "one2one" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
Then user "participant1" sets emoji "👋" with color "123456" as avatar of room "one2one" with 400 (v1)
And user "participant1" gets room "one2one" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
Scenario: Conversation that the name start with emoji dont need to have custom avatar
Given user "participant1" creates room "room1" (v4)
| roomType | 3 |
| roomName | room1 |
And the room "room1" has an svg as avatar with 200
And user "participant1" gets room "room1" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
| displayName | room1 |
And user "participant1" renames room "room1" to "💙room2" with 200 (v4)
Then user "participant1" gets room "room1" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
| displayName | 💙room2 |
And the room "room1" has an svg as avatar with 200
And the avatar svg of room "room1" contains the string "💙"
When user "participant1" renames room "room1" to "room1" with 200 (v4)
Then user "participant1" gets room "room1" with 200 (v4)
| avatarVersion | NOT_EMPTY |
| isCustomAvatar | 0 |
| displayName | room1 |
And the room "room1" has an svg as avatar with 200
Scenario: User should receive the room avatar when see a rich object at media tab
Given user "participant1" creates room "public room" (v4)
| roomType | 3 |
| roomName | public room |
And user "participant1" uploads file "/img/favicon.png" as avatar of room "public room" with 200
When user "participant1" shares rich-object "call" "R4nd0mT0k3n" '{"name":"Another room","call-type":"group"}' to room "public room" with 201 (v1)
Then user "participant1" sees the following shared other in room "public room" with 200
| room | actorType | actorId | actorDisplayName | message |
|