@webship-js/bbpress-steps 0.0.0-stage → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,29 @@
1
+ @accessibility
2
+ Feature: The forums for every visitor
3
+ As a visitor who uses a screen reader or a keyboard
4
+ I want the pages of the forums I read to have no critical accessibility fault
5
+ So that I can follow the community like anybody else
6
+
7
+ # The pages a visitor reads. The pages with a search field of the forums are left out (the forum index, the
8
+ # search page, the page of a topic tag, the lists of a profile): the field has no accessible label, its label
9
+ # being hidden from every reader. So are the topic and reply forms, whose editor has none either. See "What the
10
+ # suite tests" in the README.
11
+ Scenario Outline: A page of the forums a visitor reads has no critical accessibility violation
12
+ Given I am an anonymous user
13
+ When I go to "<page>"
14
+ Then the page should have no critical accessibility violations
15
+
16
+ Examples:
17
+ | page |
18
+ | /forums/forum/community/ |
19
+ | /forums/forum/community/general-discussion/ |
20
+ | /forums/topic/welcome-to-the-forums/ |
21
+ | /forums/topic/a-long-conversation/page/2/ |
22
+ | /forums/view/popular/ |
23
+ | /forums/users/participant/ |
24
+
25
+ Scenario: A page of the forums declares its language and has one main heading
26
+ Given I am an anonymous user
27
+ When I open the topic "Welcome to the forums" in "General discussion"
28
+ Then the page should declare a language
29
+ And the page should have exactly one h1
@@ -0,0 +1,126 @@
1
+ @administration
2
+ Feature: The forums in the administration
3
+ As the keymaster of the forums
4
+ I want the lists, the settings and the tools of the forums
5
+ So that I can run them
6
+
7
+ Scenario: The screens of the forums open by their names
8
+ Given I am a logged in user with the "keymaster" user
9
+ When I go to the "Forums" admin screen
10
+ Then I should be on the "Forums" admin screen
11
+ When I go to the "Topics" admin screen
12
+ Then I should be on the "Topics" admin screen
13
+ When I go to the "Replies" admin screen
14
+ Then I should be on the "Replies" admin screen
15
+ When I go to the "Topic Tags" admin screen
16
+ Then I should be on the "Topic Tags" admin screen
17
+ When I go to the "Forums settings" admin screen
18
+ Then I should be on the "Forums settings" admin screen
19
+ When I go to the "Forum tools" admin screen
20
+ Then I should be on the "Forum tools" admin screen
21
+
22
+ Scenario: The lists of the administration hold the forums, the topics and the replies
23
+ Given I am a logged in user with the "keymaster" user
24
+ Then the forums list should include "General discussion"
25
+ And the forums list should include "Staff room"
26
+ And the forums list should not include "Webship test forum"
27
+ And the topics list should include "Welcome to the forums"
28
+ And the topics list should not include "Webship test topic that is not there"
29
+ And the replies list should include "Reply To: Welcome to the forums"
30
+ And the topic "The spring meetup is over" should be closed in the topics list
31
+ And the topic "Welcome to the forums" should be sticky in the topics list
32
+ And the topic "A community garden in spring" should be open in the topics list
33
+ And the topic "A community garden in spring" should not be sticky in the topics list
34
+ And the forum "Archive" should be closed in the forums list
35
+ And the forum "Showcase" should be open in the forums list
36
+
37
+ Scenario: A moderator works on a topic from the topics list
38
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
39
+ And I am a logged in user with the "moderator" user
40
+ When I close the topic "Webship test topic" from the topics list
41
+ Then I should see a success notice "successfully closed"
42
+ And the topic "Webship test topic" should be closed in the topics list
43
+ When I open the topic "Webship test topic" from the topics list
44
+ Then the topic "Webship test topic" should be open in the topics list
45
+ When I stick the topic "Webship test topic" from the topics list
46
+ Then the topic "Webship test topic" should be sticky in the topics list
47
+ When I unstick the topic "Webship test topic" from the topics list
48
+ Then the topic "Webship test topic" should not be sticky in the topics list
49
+ When I unapprove the topic "Webship test topic" from the topics list
50
+ Then the topic "Webship test topic" should be pending in the topics list
51
+ When I approve the topic "Webship test topic" from the topics list
52
+ And I spam the topic "Webship test topic" from the topics list
53
+ Then the topic "Webship test topic" should be spam in the topics list
54
+ When I unspam the topic "Webship test topic" from the topics list
55
+ And I trash the topic "Webship test topic" from the topics list
56
+ Then the topic "Webship test topic" should be in the trash in the topics list
57
+ And the topics list should not include "Webship test topic"
58
+ When I restore the topic "Webship test topic" from the topics trash
59
+ Then the topics list should include "Webship test topic"
60
+ When I trash the topic "Webship test topic" from the topics list
61
+ And I delete the topic "Webship test topic" from the topics trash
62
+ Then the topics list should not include "Webship test topic"
63
+ And the topic "A community garden in spring" should not be in the trash in the topics list
64
+
65
+ Scenario: The keymaster closes a forum from the forums list and opens it again
66
+ Given I am a logged in user with the "keymaster" user
67
+ When I close the forum "Showcase" from the forums list
68
+ Then the forum "Showcase" should be closed in the forums list
69
+ Given I am a logged in user with the "participant" user
70
+ When I open the forum "Showcase"
71
+ Then I should not be able to start a topic
72
+ Given I am a logged in user with the "keymaster" user
73
+ When I open the forum "Showcase" from the forums list
74
+ Then the forum "Showcase" should be open in the forums list
75
+ Given I am a logged in user with the "participant" user
76
+ When I open the forum "Showcase"
77
+ Then I should be able to start a topic
78
+
79
+ Scenario: The settings of the forums
80
+ Given I am a logged in user with the "keymaster" user
81
+ When I go to the "Forums settings" admin screen
82
+ Then the forum feature "Favorites" should be on
83
+ And the forum feature "Subscriptions" should be on
84
+ And the forum feature "Topic tags" should be on
85
+ And the forum feature "Search" should be on
86
+ And the forum feature "Revisions" should be on
87
+ And the forum feature "Anonymous" should be off
88
+ And the forum feature "Reply Threading" should be off
89
+ And the "Forum Root" setting should be "forums"
90
+ And the "Topic Tag" setting should be "topic-tag"
91
+
92
+ Scenario: A feature turned off is gone from the forums, and comes back
93
+ Given I am a logged in user with the "keymaster" user
94
+ When I go to the "Forums settings" admin screen
95
+ And I turn the forum feature "Favorites" off
96
+ And I save the settings
97
+ Then I should see a success notice "Settings saved."
98
+ And the forum feature "Favorites" should be off
99
+ When I open my forum profile
100
+ Then the forum profile should not offer the page "Favorites"
101
+ When I go to the "Forums settings" admin screen
102
+ And I turn the forum feature "Favorites" on
103
+ And I save the settings
104
+ Then the forum feature "Favorites" should be on
105
+ When I open my forum profile
106
+ Then the forum profile should offer the page "Favorites"
107
+
108
+ Scenario: The repair tools of the forums
109
+ Given I am a logged in user with the "keymaster" user
110
+ When I run the forum repair tool "Recount topics in each forum"
111
+ Then I should see a success notice "Counting the number of topics in each forum"
112
+ When I run the forum repair tool "Recount replies in each topic"
113
+ Then I should see a success notice "Complete!"
114
+ When I go to the forum index
115
+ Then the forum "Showcase" should have 16 topics in the list
116
+
117
+ Scenario: The users screen shows the forum role of each account, and changes one
118
+ Given I am a logged in user with the "admin" user
119
+ Then the users screen should show the forum role "Keymaster" for "admin"
120
+ And the users screen should show the forum role "Moderator" for "moderator"
121
+ And the users screen should show the forum role "Blocked" for "blocked"
122
+ When I change the forum role of "spectator" to "Participant"
123
+ Then the users screen should show the forum role "Participant" for "spectator"
124
+ And the forum role of "spectator" should be "Participant"
125
+ When I change the forum role of "spectator" to "Spectator"
126
+ Then the users screen should show the forum role "Spectator" for "spectator"
@@ -0,0 +1,96 @@
1
+ @forums
2
+ Feature: The forum index and a forum
3
+ As a visitor of the site
4
+ I want to find my way through the forums and their topics
5
+ So that I can read what the community wrote
6
+
7
+ @critical
8
+ Scenario: A visitor sees the public forums, under their category
9
+ Given I am an anonymous user
10
+ And I am on the forum index
11
+ Then the forum index should list the forum "Community"
12
+ And the forum index should list the forum "General discussion" in the category "Community"
13
+ And the forum index should list the forum "Help and support" in the category "Community"
14
+ And the forum index should list the forum "Showcase"
15
+ And the forum index should list the forum "Archive"
16
+ But the forum index should not list the forum "Members lounge"
17
+ And the forum index should not list the forum "Staff room"
18
+ And the forum breadcrumbs should be "Home" and "Forums"
19
+
20
+ Scenario: The index counts the topics and the posts of each forum, and marks them
21
+ Given I am an anonymous user
22
+ When I go to the forum index
23
+ Then the forum "Community" should be a category in the list
24
+ And the forum "Community" should have 7 topics in the list
25
+ And the forum "Community" should have 30 posts in the list
26
+ And the forum "Showcase" should have 16 topics in the list
27
+ And the forum "Showcase" should not be a category in the list
28
+ And the forum "Archive" should be closed in the list
29
+ And the forum "Archive" should have 2 posts in the list
30
+ And the forum "Showcase" should not be closed in the list
31
+
32
+ Scenario: A category lists its forums
33
+ Given I am an anonymous user
34
+ When I open the forum "Community"
35
+ Then I should be in the forum "Community"
36
+ And the forum should list the subforum "General discussion"
37
+ And the forum should list the subforum "Help and support"
38
+ And the forum should not list the subforum "Showcase"
39
+ And the forum "General discussion" should have 4 topics in the list
40
+ And the forums should say "This category has 7 topics, 23 replies"
41
+ And I should not be able to start a topic
42
+
43
+ Scenario: A forum lists its topics: the sticky ones first, then by their last post
44
+ Given I am an anonymous user
45
+ When I open the forum "General discussion"
46
+ Then I should be in the forum "General discussion"
47
+ And the forum breadcrumbs should be "Home", "Forums", "Community" and "General discussion"
48
+ And the forums should say "This forum has 4 topics, 4 replies"
49
+ And the forum should have 4 topics
50
+ And the first topic of the forum should be "Forum rules"
51
+ And the topic "Forum rules" should be super sticky in the list
52
+ And the topic "Welcome to the forums" should be sticky in the list
53
+ And the topic "Welcome to the forums" should not be super sticky in the list
54
+ And the topic "A community garden in spring" should not be sticky in the list
55
+ And the topic "The spring meetup is over" should be closed in the list
56
+ And the topic "A community garden in spring" should not be closed in the list
57
+ And the forum should not list the topic "Showcase entry 01"
58
+
59
+ Scenario: The row of a topic names its author and counts its replies and voices
60
+ Given I am an anonymous user
61
+ When I open the forum "General discussion"
62
+ Then the topic "Welcome to the forums" should be by "keymaster" in the list
63
+ And the topic "Welcome to the forums" should have 2 replies in the list
64
+ And the topic "Welcome to the forums" should have 3 voices in the list
65
+ And the topic "Forum rules" should have 0 replies in the list
66
+ And the topic "A community garden in spring" should be by "participant" in the list
67
+ And the topic "A community garden in spring" should have 1 reply in the list
68
+
69
+ Scenario: A forum with more topics than a page shows has pages
70
+ Given I am an anonymous user
71
+ When I open the forum "Showcase"
72
+ # Its own sixteen topics, and the super sticky topic every forum lists.
73
+ Then the forum should have 17 topics
74
+ And I should be on page 1
75
+ And the first topic of the forum should be "Forum rules"
76
+ And the forum should list the topic "Showcase entry 16"
77
+ And the forum should not list the topic "Showcase entry 01"
78
+ When I go to page 2
79
+ Then I should be on page 2
80
+ And the forum should list the topic "Showcase entry 01"
81
+ And the forum should not list the topic "Showcase entry 16"
82
+ When I go to page 1
83
+ Then I should be on page 1
84
+
85
+ Scenario: A visitor reads a forum but is asked to log in before posting
86
+ Given I am an anonymous user
87
+ When I open the forum "Help and support"
88
+ Then I should not be able to start a topic
89
+ And the forums should say "You must be logged in to create new topics."
90
+
91
+ Scenario: A closed forum takes no new topics
92
+ Given I am a logged in user with the "participant" user
93
+ When I open the forum "Archive"
94
+ Then the forums should say "The forum ‘Archive’ is closed to new topics and replies."
95
+ And I should not be able to start a topic
96
+ And the forum should list the topic "The forums opened"
@@ -0,0 +1,88 @@
1
+ @roles
2
+ Feature: The forum roles
3
+ As the keymaster of the forums
4
+ I want each forum role to reach what it should and nothing more
5
+ So that the private and the hidden forums stay that way
6
+
7
+ Scenario: A participant reads the private forum, not the hidden one
8
+ Given I am a logged in user with the "participant" user
9
+ And I am on the forum index
10
+ Then the forum index should list the forum "Members lounge"
11
+ And the forum "Members lounge" should be private in the list
12
+ But the forum index should not list the forum "Staff room"
13
+ When I open the forum "Members lounge"
14
+ Then the forum should list the topic "Members only: the next meetup"
15
+ And I should be able to start a topic
16
+
17
+ @js-off
18
+ Scenario: The hidden forum is not found by a participant
19
+ Given I am a logged in user with the "participant" user
20
+ Then I should not be allowed to open "/forums/forum/staff-room/"
21
+
22
+ Scenario: A moderator and a keymaster read the hidden forum
23
+ Given I am a logged in user with the "moderator" user
24
+ And I am on the forum index
25
+ Then the forum index should list the forum "Staff room"
26
+ And the forum "Staff room" should be hidden in the list
27
+ And the forum "Staff room" should not be private in the list
28
+ When I open the forum "Staff room"
29
+ Then the forum should list the topic "Staff only: the moderation notes"
30
+ Given I am a logged in user with the "keymaster" user
31
+ When I open the forum "Staff room"
32
+ Then I should be in the forum "Staff room"
33
+ And I should be able to start a topic
34
+
35
+ @js-off
36
+ Scenario: A visitor does not find the private and the hidden forum
37
+ Given I am an anonymous user
38
+ Then I should not be allowed to open "/forums/forum/members-lounge/"
39
+ And I should not be allowed to open "/forums/forum/staff-room/"
40
+ And I should not be allowed to open "/forums/topic/members-only-the-next-meetup/"
41
+
42
+ @js-off
43
+ Scenario: A spectator reads the public forums and writes nothing
44
+ Given I am a logged in user with the "spectator" user
45
+ And I am on the forum index
46
+ Then the forum index should list the forum "Showcase"
47
+ But the forum index should not list the forum "Members lounge"
48
+ When I open the forum "General discussion"
49
+ Then I should not be able to start a topic
50
+ And the forums should say "You cannot create new topics."
51
+ When I open the topic "Welcome to the forums" in "General discussion"
52
+ Then I should not be able to reply
53
+ And the forums should say "You cannot reply to this topic."
54
+ And I should not see the moderator tools
55
+ And I should not be allowed to open "/forums/forum/members-lounge/"
56
+
57
+ @js-off
58
+ Scenario: A blocked account gets no forum at all
59
+ Given I am a logged in user with the "blocked" user
60
+ Then I should not be allowed to open "/forums/"
61
+ And I should not be allowed to open "/forums/forum/showcase/"
62
+ And I should not be allowed to open "/forums/topic/welcome-to-the-forums/"
63
+ And I should be logged in
64
+
65
+ Scenario: The keymaster may post where a forum is closed, a moderator may not
66
+ Given I am a logged in user with the "keymaster" user
67
+ When I open the forum "Archive"
68
+ Then I should be able to start a topic
69
+ And the forums should say "This forum is marked as closed to new topics, however your posting capabilities still allow you to create a topic."
70
+ Given I am a logged in user with the "moderator" user
71
+ When I open the forum "Archive"
72
+ Then I should not be able to start a topic
73
+
74
+ @js-off
75
+ Scenario: The administration of the forums by role
76
+ Given I am a logged in user with the "keymaster" user
77
+ When I go to the "Dashboard" admin screen
78
+ Then the admin menu should list "Forums"
79
+ And the admin menu should list "Topics"
80
+ And the admin menu should list "Replies"
81
+ Given I am a logged in user with the "moderator" user
82
+ When I go to the "Dashboard" admin screen
83
+ Then the admin menu should list "Topics"
84
+ And the admin menu should list "Replies"
85
+ But the admin menu should not list "Forums"
86
+ Given I am a logged in user with the "participant" user
87
+ Then I should not be allowed to open "/wp-admin/edit.php?post_type=topic"
88
+ And I should not be allowed to open "/wp-admin/options-general.php?page=bbpress"
@@ -0,0 +1,223 @@
1
+ @moderation
2
+ Feature: Moderation
3
+ As a moderator of the forums
4
+ I want to close, stick, hide, merge, split and move what the members post
5
+ So that the forums stay in order
6
+
7
+ Scenario: A participant has no moderator tools, a moderator has them
8
+ Given I am a logged in user with the "participant" user
9
+ When I open the topic "A community garden in spring" in "General discussion"
10
+ Then I should not see the moderator tools
11
+ And post 1 should offer the link "Edit"
12
+ And post 1 should not offer the link "Close"
13
+ And post 2 should not offer the link "Split"
14
+ Given I am a logged in user with the "moderator" user
15
+ When I open the topic "A community garden in spring" in "General discussion"
16
+ Then I should see the moderator tools
17
+ And post 1 should offer the link "Merge"
18
+ And post 1 should offer the link "Close"
19
+ And post 1 should offer the link "Stick"
20
+ And post 2 should offer the link "Move"
21
+ And post 2 should offer the link "Split"
22
+
23
+ Scenario: A moderator closes a topic and opens it again
24
+ Given there is a topic "Webship test topic" in "General discussion" by "moderator"
25
+ And I am a logged in user with the "moderator" user
26
+ When I open the topic "Webship test topic"
27
+ And I close the topic
28
+ Then the topic should be closed
29
+ And the forums should say "This topic is marked as closed to new replies, however your posting capabilities still allow you to reply."
30
+ Given I am a logged in user with the "participant" user
31
+ When I open the topic "Webship test topic" in "General discussion"
32
+ Then the topic should be closed
33
+ And I should not be able to reply
34
+ Given I am a logged in user with the "moderator" user
35
+ When I open the topic "Webship test topic" in "General discussion"
36
+ And I open the topic
37
+ Then the topic should be open
38
+ Given I am a logged in user with the "participant" user
39
+ When I open the topic "Webship test topic" in "General discussion"
40
+ Then I should be able to reply
41
+ And there is no topic "Webship test topic"
42
+
43
+ Scenario: A moderator sticks a topic to the top of its forum, then to the front of every forum
44
+ Given there is a topic "Webship test topic" in "Help and support" by "participant"
45
+ And I am a logged in user with the "moderator" user
46
+ When I open the topic "Webship test topic"
47
+ Then the topic should not be sticky
48
+ When I stick the topic
49
+ Then the topic should be sticky
50
+ When I open the forum "Help and support"
51
+ Then the topic "Webship test topic" should be sticky in the list
52
+ And the topic "Webship test topic" should not be super sticky in the list
53
+ When I open the forum "Showcase"
54
+ Then the forum should not list the topic "Webship test topic"
55
+ When I open the topic "Webship test topic" in "Help and support"
56
+ And I unstick the topic
57
+ Then the topic should not be sticky
58
+ When I stick the topic to the front
59
+ Then the topic should be sticky
60
+ When I open the forum "Showcase"
61
+ Then the forum should list the topic "Webship test topic"
62
+ And the topic "Webship test topic" should be super sticky in the list
63
+ When I open the topic "Webship test topic" in "Help and support"
64
+ And I unstick the topic
65
+ Then the topic should not be sticky
66
+ And there is no topic "Webship test topic"
67
+
68
+ Scenario: A topic a moderator unapproves is hidden from the members until it is approved
69
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
70
+ And I am a logged in user with the "moderator" user
71
+ When I open the topic "Webship test topic"
72
+ And I unapprove the topic
73
+ Then the topic should be pending
74
+ And the forums should say "This topic is pending moderation."
75
+ # The forum's list hides a pending topic from a moderator too, until it asks for it.
76
+ When I open the forum "General discussion"
77
+ Then the forum should not list the topic "Webship test topic"
78
+ And the forums should say "(+1 hidden)"
79
+ When I show the hidden topics
80
+ Then the topic "Webship test topic" should be pending in the list
81
+ Given I am an anonymous user
82
+ When I open the forum "General discussion"
83
+ Then the forum should not list the topic "Webship test topic"
84
+ Given I am a logged in user with the "moderator" user
85
+ When I open the forum "General discussion"
86
+ And I show the hidden topics
87
+ And I open the topic "Webship test topic"
88
+ And I approve the topic
89
+ Then the topic should be open
90
+ Given I am an anonymous user
91
+ When I open the forum "General discussion"
92
+ Then the forum should list the topic "Webship test topic"
93
+ And there is no topic "Webship test topic"
94
+
95
+ Scenario: A moderator marks a topic as spam and takes the mark away
96
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
97
+ And I am a logged in user with the "moderator" user
98
+ When I open the topic "Webship test topic"
99
+ And I spam the topic
100
+ Then the topic should be spam
101
+ And the forums should say "This topic is marked as spam."
102
+ When I unspam the topic
103
+ Then the topic should be open
104
+ And the topic should not be spam
105
+ And there is no topic "Webship test topic"
106
+
107
+ Scenario: A moderator trashes a topic, restores it, and deletes it for good
108
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
109
+ And "moderator" replied to the topic "Webship test topic" with "Webship test reply of the moderator."
110
+ And I am a logged in user with the "moderator" user
111
+ When I open the topic "Webship test topic"
112
+ And I trash the topic
113
+ Then the topic should be in the trash
114
+ And the forums should say "This topic is in the trash."
115
+ When I restore the topic
116
+ Then the topic should be open
117
+ And the topic should have 2 posts
118
+ When I delete the topic permanently
119
+ And I open the forum "General discussion"
120
+ Then the forum should not list the topic "Webship test topic"
121
+ And the forum should have 4 topics
122
+
123
+ Scenario: A moderator hides a reply, and deletes another
124
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
125
+ And "participant" replied to the topic "Webship test topic" with "Webship test: a first reply."
126
+ And "participant" replied to the topic "Webship test topic" with "Webship test: a second reply."
127
+ And I am a logged in user with the "moderator" user
128
+ When I open the topic "Webship test topic"
129
+ And I unapprove the last post
130
+ Then the last post should be pending
131
+ When I approve the last post
132
+ Then the last post should be published
133
+ When I spam the last post
134
+ Then the last post should be spam
135
+ And the forums should say "This topic has 1 reply (+1 hidden)"
136
+ Given I am an anonymous user
137
+ When I open the topic "Webship test topic" in "General discussion"
138
+ Then the topic should have 2 posts
139
+ And the last post should read "Webship test: a first reply."
140
+ Given I am a logged in user with the "moderator" user
141
+ When I open the topic "Webship test topic" in "General discussion"
142
+ # The forums hide the reply from a moderator too, until it asks for it.
143
+ Then the topic should have 2 posts
144
+ And the forums should say "(+1 hidden)"
145
+ When I show the hidden posts
146
+ Then the topic should have 3 posts
147
+ And the last post should be spam
148
+ And post 2 should not be spam
149
+ When I unspam the last post
150
+ Then the last post should be published
151
+ When I trash the last post
152
+ Then the last post should be in the trash
153
+ When I restore the last post
154
+ Then the last post should be published
155
+ When I delete the last post permanently
156
+ Then the topic should have 2 posts
157
+ And the last post should read "Webship test: a first reply."
158
+ And there is no topic "Webship test topic"
159
+
160
+ Scenario: A moderator splits a topic, moves a reply, and merges the topics again
161
+ Given there is no topic "Webship test split"
162
+ And there is a topic "Webship test topic" in "General discussion" by "participant"
163
+ And "participant" replied to the topic "Webship test topic" with "Webship test: a first reply."
164
+ And "moderator" replied to the topic "Webship test topic" with "Webship test: a second reply."
165
+ And "participant" replied to the topic "Webship test topic" with "Webship test: a third reply."
166
+ And I am a logged in user with the "moderator" user
167
+ When I open the topic "Webship test topic"
168
+ Then the topic should have 4 posts
169
+ When I split the topic from post 3 into "Webship test split"
170
+ Then I should be reading the topic "Webship test split"
171
+ And the topic should have 2 posts
172
+ And post 1 should read "Webship test: a second reply."
173
+ And post 1 should be by "moderator"
174
+ And post 2 should read "Webship test: a third reply."
175
+ When I open the topic "Webship test topic" in "General discussion"
176
+ Then the topic should have 2 posts
177
+ When I move the last post to the topic "Webship test split"
178
+ Then I should be reading the topic "Webship test split"
179
+ And the topic should have 3 posts
180
+ When I merge the topic into "Webship test topic"
181
+ Then I should be reading the topic "Webship test topic"
182
+ And the topic should have 4 posts
183
+ And post 1 should read "the first post of"
184
+ When I open the forum "General discussion"
185
+ Then the forum should not list the topic "Webship test split"
186
+ And there is no topic "Webship test topic"
187
+ And there is no topic "Webship test split"
188
+
189
+ Scenario: A moderator moves a reply into a topic of its own
190
+ Given there is no topic "Webship test: moved reply"
191
+ And there is a topic "Webship test topic" in "General discussion" by "participant"
192
+ And "participant" replied to the topic "Webship test topic" with "Webship test: a question of its own."
193
+ And I am a logged in user with the "moderator" user
194
+ When I open the topic "Webship test topic"
195
+ And I move the last post to a new topic "Webship test: moved reply"
196
+ Then I should be reading the topic "Webship test: moved reply"
197
+ And the topic should have 1 post
198
+ And post 1 should read "Webship test: a question of its own."
199
+ And post 1 should be by "participant"
200
+ And there is no topic "Webship test: moved reply"
201
+ And there is no topic "Webship test topic"
202
+
203
+ Scenario: A moderator moves a topic to another forum and edits it, with a reason
204
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
205
+ And I am a logged in user with the "moderator" user
206
+ When I open the topic "Webship test topic"
207
+ And I move the topic to "Help and support"
208
+ Then the forum breadcrumbs should be "Home", "Forums", "Community", "Help and support" and "Webship test topic"
209
+ When I open the forum "General discussion"
210
+ Then the forum should not list the topic "Webship test topic"
211
+ When I open the topic "Webship test topic" in "Help and support"
212
+ And I edit post 1
213
+ And I add " Webship test: the moderator added this." to the editor
214
+ And I choose the topic type "Sticky"
215
+ And I choose the topic status "Closed"
216
+ And I give the edit reason "Moved to the right forum"
217
+ And I submit the post
218
+ Then the topic should be closed
219
+ And the topic should be sticky
220
+ And post 1 should read "Webship test: the moderator added this."
221
+ And the edit log of post 1 should show "by moderator"
222
+ And the edit log of post 1 should show "Reason: Moved to the right forum"
223
+ And there is no topic "Webship test topic"
@@ -0,0 +1,43 @@
1
+ @notifications
2
+ Feature: The notifications of the forums
3
+ As a participant of the forums
4
+ I want an e-mail when somebody replies to a topic I follow
5
+ So that I do not have to look for the answer
6
+
7
+ Scenario: A subscriber of a topic is notified of a reply, its author is not
8
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
9
+ And I am a logged in user with the "participant" user
10
+ And I have no subscriptions
11
+ When I open the topic "Webship test topic"
12
+ And I subscribe to the topic
13
+ Then the topic should be subscribed to
14
+ Given "moderator" replied to the topic "Webship test topic" with "Webship test reply of the moderator."
15
+ Then a forum notification with the subject "[General discussion] Webship test topic" should be sent to "participant"
16
+ And the forum notification with the subject "Webship test topic" to "participant" should contain "moderator wrote:"
17
+ And the forum notification with the subject "Webship test topic" to "participant" should contain "Webship test reply of the moderator."
18
+ And the forum notification with the subject "Webship test topic" to "participant" should contain "Post Link:"
19
+ And the forum notification with the subject "Webship test topic" to "participant" should contain "You are receiving this email because you subscribed to a forum topic."
20
+ But no forum notification should be sent to "moderator"
21
+ And there is no topic "Webship test topic"
22
+
23
+ Scenario: A subscriber of a forum is notified of a new topic
24
+ Given there is no topic "Webship test question"
25
+ And I am a logged in user with the "participant" user
26
+ And I have no subscriptions
27
+ When I open the forum "Help and support"
28
+ And I subscribe to the forum
29
+ Then the forum should be subscribed to
30
+ Given there is a topic "Webship test question" in "Help and support" by "moderator"
31
+ Then a forum notification with the subject "[Help and support] Webship test question" should be sent to "participant"
32
+ And the forum notification with the subject "Webship test question" to "participant" should contain "Topic Link:"
33
+ And the forum notification with the subject "Webship test question" to "participant" should contain "You are receiving this email because you subscribed to a forum."
34
+ Given I am a logged in user with the "participant" user
35
+ And I have no subscriptions
36
+ And there is no topic "Webship test question"
37
+
38
+ Scenario: Nobody is notified of a reply to a topic nobody follows
39
+ Given there is a topic "Webship test topic" in "General discussion" by "participant"
40
+ And "moderator" replied to the topic "Webship test topic" with "Webship test reply of the moderator."
41
+ Then no forum notification should be sent to "participant"
42
+ And no forum notification should be sent to "moderator"
43
+ And there is no topic "Webship test topic"