1 |
efrain |
1 |
@mod @mod_assign
|
|
|
2 |
Feature: Assign group override
|
|
|
3 |
In order to grant a group special access to an assignment
|
|
|
4 |
As a teacher
|
|
|
5 |
I need to create an override for that group.
|
|
|
6 |
|
|
|
7 |
Background:
|
|
|
8 |
Given the following "users" exist:
|
|
|
9 |
| username | firstname | lastname | email |
|
|
|
10 |
| teacher1 | Tina | Teacher1 | teacher1@example.com |
|
|
|
11 |
| student1 | Sam1 | Student1 | student1@example.com |
|
|
|
12 |
| student2 | Sam2 | Student2 | student2@example.com |
|
|
|
13 |
| student3 | Sam3 | Student3 | student3@example.com |
|
|
|
14 |
And the following "courses" exist:
|
|
|
15 |
| fullname | shortname | category |
|
|
|
16 |
| Course 1 | C1 | 0 |
|
|
|
17 |
And the following "course enrolments" exist:
|
|
|
18 |
| user | course | role |
|
|
|
19 |
| teacher1 | C1 | editingteacher |
|
|
|
20 |
| student1 | C1 | student |
|
|
|
21 |
| student2 | C1 | student |
|
|
|
22 |
| student3 | C1 | student |
|
|
|
23 |
And the following "groups" exist:
|
|
|
24 |
| name | course | idnumber |
|
|
|
25 |
| Group 1 | C1 | G1 |
|
|
|
26 |
| Group 2 | C1 | G2 |
|
|
|
27 |
Given the following "group members" exist:
|
|
|
28 |
| user | group |
|
|
|
29 |
| student1 | G1 |
|
|
|
30 |
| student2 | G2 |
|
|
|
31 |
| student3 | G1 |
|
|
|
32 |
And the following "activities" exist:
|
|
|
33 |
| activity | name | intro | course | assignsubmission_onlinetext_enabled |
|
|
|
34 |
| assign | Test assignment name | Submit your online text | C1 | 1 |
|
|
|
35 |
|
1441 |
ariadna |
36 |
@javascript
|
1 |
efrain |
37 |
Scenario: Add, modify then delete a group override
|
|
|
38 |
Given I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
39 |
When I navigate to "Overrides" in current page administration
|
|
|
40 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
41 |
And I press "Add group override"
|
|
|
42 |
And I set the following fields to these values:
|
|
|
43 |
| Override group | Group 1 |
|
|
|
44 |
| Due date | ##1 Jan 2020 08:00## |
|
|
|
45 |
And I press "Save"
|
|
|
46 |
Then I should see "Wednesday, 1 January 2020, 8:00"
|
|
|
47 |
And I click on "Edit" "link" in the "Group 1" "table_row"
|
|
|
48 |
And I set the following fields to these values:
|
|
|
49 |
| Due date | ##1 Jan 2030 08:00## |
|
|
|
50 |
And I press "Save"
|
|
|
51 |
And I should see "Tuesday, 1 January 2030, 8:00"
|
|
|
52 |
And I click on "Delete" "link"
|
|
|
53 |
And I press "Continue"
|
|
|
54 |
And I should not see "Group 1"
|
|
|
55 |
|
|
|
56 |
Scenario: Duplicate a user override
|
|
|
57 |
Given I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
58 |
When I navigate to "Overrides" in current page administration
|
|
|
59 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
60 |
And I press "Add group override"
|
|
|
61 |
And I set the following fields to these values:
|
|
|
62 |
| Override group | Group 1 |
|
|
|
63 |
| Due date | ##1 Jan 2020 08:00## |
|
|
|
64 |
And I press "Save"
|
|
|
65 |
Then I should see "Wednesday, 1 January 2020, 8:00"
|
|
|
66 |
And I click on "copy" "link"
|
|
|
67 |
And I set the following fields to these values:
|
|
|
68 |
| Override group | Group 2 |
|
|
|
69 |
| Due date | ##1 Jan 2030 08:00## |
|
|
|
70 |
And I press "Save"
|
|
|
71 |
And I should see "Tuesday, 1 January 2030, 8:00"
|
|
|
72 |
And I should see "Group 2"
|
|
|
73 |
|
|
|
74 |
Scenario: Allow a group to have a different due date
|
|
|
75 |
Given I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
76 |
When I navigate to "Settings" in current page administration
|
|
|
77 |
And I set the following fields to these values:
|
|
|
78 |
| Allow submissions from | disabled |
|
|
|
79 |
| Due date | ##1 Jan 2000 08:00## |
|
|
|
80 |
| Cut-off date | disabled |
|
|
|
81 |
And I press "Save and display"
|
|
|
82 |
And I navigate to "Overrides" in current page administration
|
|
|
83 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
84 |
And I press "Add group override"
|
|
|
85 |
And I set the following fields to these values:
|
|
|
86 |
| Override group | Group 1 |
|
|
|
87 |
| Due date | ##1 Jan 2020 08:00## |
|
|
|
88 |
And I press "Save"
|
|
|
89 |
And I should see "Wednesday, 1 January 2020, 8:00"
|
|
|
90 |
And I log out
|
|
|
91 |
And I am on the "Test assignment name" Activity page logged in as student2
|
|
|
92 |
Then the activity date in "Test assignment name" should contain "Due: Saturday, 1 January 2000, 8:00"
|
|
|
93 |
And I log out
|
|
|
94 |
And I am on the "Test assignment name" Activity page logged in as student1
|
|
|
95 |
And the activity date in "Test assignment name" should contain "Due: Wednesday, 1 January 2020, 8:00"
|
|
|
96 |
|
|
|
97 |
Scenario: Allow a group to have a different cut off date
|
|
|
98 |
Given I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
99 |
When I navigate to "Settings" in current page administration
|
|
|
100 |
And I set the following fields to these values:
|
|
|
101 |
| Due date | disabled |
|
|
|
102 |
| Allow submissions from | disabled |
|
|
|
103 |
| Cut-off date | ##1 Jan 2000 08:00## |
|
|
|
104 |
And I press "Save and display"
|
|
|
105 |
And I navigate to "Overrides" in current page administration
|
|
|
106 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
107 |
And I press "Add group override"
|
|
|
108 |
And I set the following fields to these values:
|
|
|
109 |
| Override group | Group 1 |
|
|
|
110 |
| Cut-off date | ##1 Jan 2030 08:00## |
|
|
|
111 |
And I press "Save"
|
|
|
112 |
And I should see "Tuesday, 1 January 2030, 8:00"
|
|
|
113 |
And I log out
|
|
|
114 |
And I am on the "Test assignment name" Activity page logged in as student2
|
|
|
115 |
Then I should not see "You have not made a submission yet."
|
|
|
116 |
And I log out
|
|
|
117 |
And I am on the "Test assignment name" Activity page logged in as student1
|
|
|
118 |
And I should see "No submissions have been made yet"
|
|
|
119 |
|
|
|
120 |
Scenario: Allow a group to have a different start date
|
|
|
121 |
Given I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
122 |
When I navigate to "Settings" in current page administration
|
|
|
123 |
And I set the following fields to these values:
|
|
|
124 |
| Due date | disabled |
|
|
|
125 |
| Allow submissions from | ##1 January 2030 08:00## |
|
|
|
126 |
| Cut-off date | disabled |
|
|
|
127 |
And I press "Save and display"
|
|
|
128 |
And I navigate to "Overrides" in current page administration
|
|
|
129 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
130 |
And I press "Add group override"
|
|
|
131 |
And I set the following fields to these values:
|
|
|
132 |
| Override group | Group 1 |
|
|
|
133 |
| Allow submissions from | ##1 Jan 2015 08:00## |
|
|
|
134 |
And I press "Save"
|
|
|
135 |
And I should see "Thursday, 1 January 2015, 8:00"
|
|
|
136 |
And I log out
|
|
|
137 |
And I am on the "Test assignment name" Activity page logged in as student2
|
|
|
138 |
Then the activity date in "Test assignment name" should contain "Opens: Tuesday, 1 January 2030, 8:00"
|
|
|
139 |
And I should not see "Add submission"
|
|
|
140 |
And I log out
|
|
|
141 |
And I am on the "Test assignment name" Activity page logged in as student1
|
|
|
142 |
And I should not see "Tuesday, 1 January 2030, 8:00"
|
|
|
143 |
|
|
|
144 |
@javascript
|
|
|
145 |
Scenario: Add both a user and group override and verify that both are applied correctly
|
|
|
146 |
Given I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
147 |
When I navigate to "Settings" in current page administration
|
|
|
148 |
And I set the following fields to these values:
|
|
|
149 |
| Due date | disabled |
|
|
|
150 |
| Allow submissions from | ##1 January 2040 08:00## |
|
|
|
151 |
| Cut-off date | disabled |
|
|
|
152 |
| Group mode | Visible groups |
|
|
|
153 |
And I press "Save and display"
|
|
|
154 |
And I navigate to "Overrides" in current page administration
|
|
|
155 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
156 |
And I press "Add group override"
|
|
|
157 |
And I set the following fields to these values:
|
|
|
158 |
| Override group | Group 1 |
|
|
|
159 |
| Allow submissions from | ##1 January 2030 08:00## |
|
|
|
160 |
And I press "Save"
|
|
|
161 |
And I should see "Tuesday, 1 January 2030, 8:00"
|
|
|
162 |
And I am on the "Test assignment name" Activity page
|
|
|
163 |
And I navigate to "Overrides" in current page administration
|
|
|
164 |
And I press "Add user override"
|
|
|
165 |
And I set the following fields to these values:
|
|
|
166 |
| Override user | Student1 |
|
|
|
167 |
| Allow submissions from | ##1 January 2031 08:00## |
|
|
|
168 |
And I press "Save"
|
|
|
169 |
And I should see "Wednesday, 1 January 2031, 8:00"
|
|
|
170 |
And I log out
|
|
|
171 |
And I am on the "Test assignment name" Activity page logged in as student1
|
|
|
172 |
And the activity date in "Test assignment name" should contain "Opens: Wednesday, 1 January 2031, 8:00"
|
|
|
173 |
And I log out
|
|
|
174 |
And I am on the "Test assignment name" Activity page logged in as student2
|
|
|
175 |
And the activity date in "Test assignment name" should contain "Opens: Sunday, 1 January 2040, 8:00"
|
|
|
176 |
And I log out
|
|
|
177 |
And I am on the "Test assignment name" Activity page logged in as student3
|
|
|
178 |
And the activity date in "Test assignment name" should contain "Opens: Tuesday, 1 January 2030, 8:00"
|
|
|
179 |
|
|
|
180 |
Scenario: Override a group when teacher is in no group, and does not have accessallgroups permission, and the activity's group mode is "separate groups"
|
|
|
181 |
Given the following "permission overrides" exist:
|
|
|
182 |
| capability | permission | role | contextlevel | reference |
|
|
|
183 |
| moodle/site:accessallgroups | Prevent | editingteacher | Course | C1 |
|
|
|
184 |
And the following "activities" exist:
|
|
|
185 |
| activity | name | intro | course | groupmode |
|
|
|
186 |
| assign | Assignment 2 | Assignment 2 description | C1 | 1 |
|
|
|
187 |
And I am on the "Assignment 2" Activity page logged in as teacher1
|
|
|
188 |
When I navigate to "Overrides" in current page administration
|
|
|
189 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
190 |
Then I should see "No groups you can access."
|
|
|
191 |
And the "Add group override" "button" should be disabled
|
|
|
192 |
|
|
|
193 |
Scenario: A teacher without accessallgroups permission should only be able to add group override for groups that he/she is a member of,
|
|
|
194 |
when the activity's group mode is "separate groups"
|
|
|
195 |
Given the following "permission overrides" exist:
|
|
|
196 |
| capability | permission | role | contextlevel | reference |
|
|
|
197 |
| moodle/site:accessallgroups | Prevent | editingteacher | Course | C1 |
|
|
|
198 |
And the following "activities" exist:
|
|
|
199 |
| activity | name | intro | course | groupmode |
|
|
|
200 |
| assign | Assignment 2 | Assignment 2 description | C1 | 1 |
|
|
|
201 |
And the following "group members" exist:
|
|
|
202 |
| user | group |
|
|
|
203 |
| teacher1 | G1 |
|
|
|
204 |
And I am on the "Assignment 2" Activity page logged in as teacher1
|
|
|
205 |
When I navigate to "Overrides" in current page administration
|
|
|
206 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
207 |
And I press "Add group override"
|
|
|
208 |
Then the "Override group" select box should contain "Group 1"
|
|
|
209 |
And the "Override group" select box should not contain "Group 2"
|
|
|
210 |
|
|
|
211 |
Scenario: A teacher without accessallgroups permission should only be able to see the group overrides for groups that he/she is a member of,
|
|
|
212 |
when the activity's group mode is "separate groups"
|
|
|
213 |
Given the following "permission overrides" exist:
|
|
|
214 |
| capability | permission | role | contextlevel | reference |
|
|
|
215 |
| moodle/site:accessallgroups | Prevent | editingteacher | Course | C1 |
|
|
|
216 |
And the following "activities" exist:
|
|
|
217 |
| activity | name | intro | course | groupmode |
|
|
|
218 |
| assign | Assignment 2 | Assignment 2 description | C1 | 1 |
|
|
|
219 |
And the following "group members" exist:
|
|
|
220 |
| user | group |
|
|
|
221 |
| teacher1 | G1 |
|
|
|
222 |
And I am on the "Assignment 2" Activity page logged in as admin
|
|
|
223 |
And I navigate to "Overrides" in current page administration
|
|
|
224 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
225 |
And I press "Add group override"
|
|
|
226 |
And I set the following fields to these values:
|
|
|
227 |
| Override group | Group 1 |
|
|
|
228 |
| Allow submissions from | ##1 January 2020 08:00## |
|
|
|
229 |
And I press "Save and enter another override"
|
|
|
230 |
And I set the following fields to these values:
|
|
|
231 |
| Override group | Group 2 |
|
|
|
232 |
| Allow submissions from | ##1 January 2020 08:00## |
|
|
|
233 |
And I press "Save"
|
|
|
234 |
And I log out
|
|
|
235 |
|
|
|
236 |
When I am on the "Assignment 2" Activity page logged in as teacher1
|
|
|
237 |
And I navigate to "Overrides" in current page administration
|
|
|
238 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
239 |
Then I should see "Group 1" in the ".generaltable" "css_element"
|
|
|
240 |
And I should not see "Group 2" in the ".generaltable" "css_element"
|
|
|
241 |
|
|
|
242 |
Scenario: "Not visible" groups should not be available for group overrides
|
|
|
243 |
Given the following "groups" exist:
|
|
|
244 |
| name | course | idnumber | visibility | participation |
|
|
|
245 |
| Visible to everyone/Participation | C1 | VP | 0 | 1 |
|
|
|
246 |
| Only visible to members/Participation | C1 | MP | 1 | 1 |
|
|
|
247 |
| Only see own membership | C1 | O | 2 | 0 |
|
|
|
248 |
| Not visible | C1 | N | 3 | 0 |
|
|
|
249 |
| Visible to everyone/Non-Participation | C1 | VN | 0 | 0 |
|
|
|
250 |
| Only visible to members/Non-Participation | C1 | MN | 1 | 0 |
|
|
|
251 |
When I am on the "Test assignment name" Activity page logged in as teacher1
|
|
|
252 |
And I navigate to "Overrides" in current page administration
|
|
|
253 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
254 |
And I press "Add group override"
|
|
|
255 |
Then I should see "Visible to everyone/Participation" in the "Override group" "select"
|
|
|
256 |
And I should see "Visible to everyone/Non-Participation" in the "Override group" "select"
|
|
|
257 |
And I should see "Only visible to members" in the "Override group" "select"
|
|
|
258 |
And I should see "Only visible to members/Non-Participation" in the "Override group" "select"
|
|
|
259 |
And I should see "Only see own membership" in the "Override group" "select"
|
|
|
260 |
And I should not see "Not visible" in the "Override group" "select"
|
1441 |
ariadna |
261 |
|
|
|
262 |
@javascript
|
|
|
263 |
Scenario: Teachers can trigger grade penalty recalculation when modifying or deleting group overrides
|
|
|
264 |
Given I enable grade penalties for assignment
|
|
|
265 |
And the following "activity" exists:
|
|
|
266 |
| activity | assign |
|
|
|
267 |
| course | C1 |
|
|
|
268 |
| name | Test assignment penalty |
|
|
|
269 |
| intro | Test assignment description |
|
|
|
270 |
| grade | 100 |
|
|
|
271 |
| duedate | ##tomorrow## |
|
|
|
272 |
| gradepenalty | 1 |
|
|
|
273 |
| assignsubmission_onlinetext_enabled | 1 |
|
|
|
274 |
| submissiondrafts | 0 |
|
|
|
275 |
And the following "mod_assign > submissions" exist:
|
|
|
276 |
| assign | user | onlinetext |
|
|
|
277 |
| Test assignment name | student1 | I'm the student first submission |
|
|
|
278 |
# Add a group override with a due date set in the future.
|
|
|
279 |
And I am on the "Test assignment penalty" Activity page logged in as teacher1
|
|
|
280 |
And I navigate to "Overrides" in current page administration
|
|
|
281 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
282 |
And I press "Add group override"
|
|
|
283 |
And I set the following fields to these values:
|
|
|
284 |
| Override group | Group 1 |
|
|
|
285 |
| Due date | ##tomorrow +1day## |
|
|
|
286 |
And I press "Save"
|
|
|
287 |
And I change window size to "large"
|
|
|
288 |
And I go to "Sam1 Student1" "Test assignment penalty" activity advanced grading page
|
|
|
289 |
And I set the field "Grade out of 100" to "90"
|
|
|
290 |
And I set the field "Notify student" to "0"
|
|
|
291 |
And I press "Save changes"
|
|
|
292 |
And I follow "View all submissions"
|
|
|
293 |
And "Sam1 Student1" row "Grade" column of "submissions" table should contain "90.00"
|
|
|
294 |
And "Sam1 Student1" row "Final grade" column of "submissions" table should contain "90.00"
|
|
|
295 |
# Modify the group override by changing the due date to a past date.
|
|
|
296 |
And I navigate to "Overrides" in current page administration
|
|
|
297 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
298 |
And I click on "Edit" "link" in the "Group 1" "table_row"
|
|
|
299 |
When I set the following fields to these values:
|
|
|
300 |
| Recalculate penalty | Yes |
|
|
|
301 |
| Due date | ##yesterday## |
|
|
|
302 |
And I press "Save"
|
|
|
303 |
And I navigate to "Submissions" in current page administration
|
|
|
304 |
Then "Sam1 Student1" row "Grade" column of "submissions" table should contain "90.00"
|
|
|
305 |
And "Sam1 Student1" row "Final grade" column of "submissions" table should contain "80.00"
|
|
|
306 |
# Delete the group override.
|
|
|
307 |
And I navigate to "Overrides" in current page administration
|
|
|
308 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
309 |
And I click on "Delete" "link" in the "Group 1" "table_row"
|
|
|
310 |
And I click on "Recalculate penalty for user(s) in the override" "checkbox" in the "Confirm" "dialogue"
|
|
|
311 |
And I click on "Continue" "button" in the "Confirm" "dialogue"
|
|
|
312 |
And I navigate to "Submissions" in current page administration
|
|
|
313 |
And "Sam1 Student1" row "Grade" column of "submissions" table should contain "90.00"
|
|
|
314 |
And "Sam1 Student1" row "Final grade" column of "submissions" table should contain "90.00"
|
|
|
315 |
|
|
|
316 |
@javascript
|
|
|
317 |
Scenario: Assign activity group overrides are displayed on the timeline block
|
|
|
318 |
Given the following "group members" exist:
|
|
|
319 |
| user | group |
|
|
|
320 |
| student1 | G2 |
|
|
|
321 |
And I am on the "Test assignment name" "assign activity editing" page logged in as teacher1
|
|
|
322 |
And I set the following fields to these values:
|
|
|
323 |
| allowsubmissionsfromdate[enabled] | 1 |
|
|
|
324 |
| duedate[enabled] | 1 |
|
|
|
325 |
| allowsubmissionsfromdate | ##today## |
|
|
|
326 |
| duedate | ##tomorrow## |
|
|
|
327 |
And I press "Save and display"
|
|
|
328 |
When I log in as "student1"
|
|
|
329 |
Then I should see "##tomorrow##%A, %d %B %Y##" in the "Timeline" "block"
|
|
|
330 |
And I am on the "Test assignment name" "assign activity" page logged in as teacher1
|
|
|
331 |
And I navigate to "Overrides" in current page administration
|
|
|
332 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
333 |
And I press "Add group override"
|
|
|
334 |
And I set the following fields to these values:
|
|
|
335 |
| Override group | Group 1 |
|
|
|
336 |
| Allow submissions from | ##tomorrow## |
|
|
|
337 |
| Due date | ##tomorrow +1day## |
|
|
|
338 |
And I press "Save"
|
|
|
339 |
And I log in as "student1"
|
|
|
340 |
And I should see "##tomorrow +1day##%A, %d %B %Y##" in the "Timeline" "block"
|
|
|
341 |
And I am on the "Test assignment name" "assign activity" page logged in as teacher1
|
|
|
342 |
And I navigate to "Overrides" in current page administration
|
|
|
343 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
344 |
And I press "Add group override"
|
|
|
345 |
And I set the following fields to these values:
|
|
|
346 |
| Override group | Group 2 |
|
|
|
347 |
| Allow submissions from | ##tomorrow +1day## |
|
|
|
348 |
| Due date | ##tomorrow +3days## |
|
|
|
349 |
And I press "Save"
|
|
|
350 |
And I click on "Move up" "link" in the "Group 2" "table_row"
|
|
|
351 |
And I log in as "student1"
|
|
|
352 |
And I should see "##tomorrow +3days##%A, %d %B %Y##" in the "Timeline" "block"
|
|
|
353 |
|
|
|
354 |
@javascript
|
|
|
355 |
Scenario: Assign activity user override is displayed even if group override exists on the timeline block
|
|
|
356 |
Given the following "group members" exist:
|
|
|
357 |
| user | group |
|
|
|
358 |
| student1 | G2 |
|
|
|
359 |
And I am on the "Test assignment name" "assign activity editing" page logged in as teacher1
|
|
|
360 |
And I set the following fields to these values:
|
|
|
361 |
| allowsubmissionsfromdate[enabled] | 1 |
|
|
|
362 |
| duedate[enabled] | 1 |
|
|
|
363 |
| allowsubmissionsfromdate | ##today## |
|
|
|
364 |
| duedate | ##tomorrow## |
|
|
|
365 |
And I press "Save and display"
|
|
|
366 |
And I navigate to "Overrides" in current page administration
|
|
|
367 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
368 |
And I press "Add group override"
|
|
|
369 |
And I set the following fields to these values:
|
|
|
370 |
| Override group | Group 1 |
|
|
|
371 |
| Allow submissions from | ##tomorrow## |
|
|
|
372 |
| Due date | ##tomorrow +1day## |
|
|
|
373 |
And I press "Save"
|
|
|
374 |
And I press "Add group override"
|
|
|
375 |
And I set the following fields to these values:
|
|
|
376 |
| Override group | Group 2 |
|
|
|
377 |
| Allow submissions from | ##tomorrow +1day## |
|
|
|
378 |
| Due date | ##tomorrow +3days## |
|
|
|
379 |
And I navigate to "Overrides > Add user override" in current page administration
|
|
|
380 |
And I set the following fields to these values:
|
|
|
381 |
| Override user | Sam1 Student1 |
|
|
|
382 |
| allowsubmissionsfromdate | ##tomorrow## |
|
|
|
383 |
| duedate | ##tomorrow noon## |
|
|
|
384 |
And I press "Save"
|
|
|
385 |
When I log in as "student1"
|
|
|
386 |
Then I should see "##tomorrow noon##%A, %d %B %Y##" in the "Timeline" "block"
|
|
|
387 |
|
|
|
388 |
@javascript
|
|
|
389 |
Scenario: Assign activity override are not visible on timeline block when student is unenrolled
|
|
|
390 |
Given the following "group members" exist:
|
|
|
391 |
| user | group |
|
|
|
392 |
| student1 | G2 |
|
|
|
393 |
And I am on the "Test assignment name" "assign activity" page logged in as teacher1
|
|
|
394 |
And I navigate to "Overrides" in current page administration
|
|
|
395 |
And I select "Group overrides" from the "jump" singleselect
|
|
|
396 |
And I press "Add group override"
|
|
|
397 |
And I set the following fields to these values:
|
|
|
398 |
| Override group | Group 2 |
|
|
|
399 |
| Allow submissions from | ##tomorrow +1day## |
|
|
|
400 |
| Due date | ##tomorrow +3days## |
|
|
|
401 |
And I navigate to "Overrides > Add user override" in current page administration
|
|
|
402 |
And I set the following fields to these values:
|
|
|
403 |
| Override user | Sam1 Student1 |
|
|
|
404 |
| allowsubmissionsfromdate | ##tomorrow## |
|
|
|
405 |
| duedate | ##tomorrow noon## |
|
|
|
406 |
And I press "Save"
|
|
|
407 |
And I am on "Course 1" course homepage
|
|
|
408 |
And I navigate to course participants
|
|
|
409 |
And I click on "Unenrol" "icon" in the "student1" "table_row"
|
|
|
410 |
And I click on "Unenrol" "button" in the "Unenrol" "dialogue"
|
|
|
411 |
When I log in as "student1"
|
|
|
412 |
Then "Test assignment name" "link" should not exist in the "Timeline" "block"
|
|
|
413 |
And I should not see "##tomorrow noon##%A, %d %B %Y##" in the "Timeline" "block"
|