2 Feature: We can use calculated grade totals
3 In order to calculate grade totals
5 I need to add aggregate columns to the gradebook
8 Given the following "courses" exist:
9 | fullname | shortname | category | groupmode |
10 | Course 1 | C1 | 0 | 1 |
11 And the following "users" exist:
12 | username | firstname | lastname | email | idnumber |
13 | teacher1 | Teacher | 1 | teacher1@example.com | t1 |
14 | student1 | Student | 1 | student1@example.com | s1 |
15 And the following "course enrolments" exist:
16 | user | course | role |
17 | teacher1 | C1 | editingteacher |
18 | student1 | C1 | student |
19 And the following "grade categories" exist:
21 | Sub category 1 | C1 |
22 | Sub category 2 | C1 |
23 And the following "activities" exist:
24 | activity | course | idnumber | name | intro | grade |
25 | assign | C1 | a1 | Test assignment one | Submit something! | 300 |
26 | assign | C1 | a2 | Test assignment two | Submit something! | 100 |
27 | assign | C1 | a3 | Test assignment three | Submit something! | 150 |
28 | assign | C1 | a4 | Test assignment four | Submit nothing! | 150 |
29 And the following "activities" exist:
30 | activity | course | idnumber | name | intro | gradecategory | grade |
31 | assign | C1 | a5 | Test assignment five | Submit something! | Sub category 1 | 20 |
32 | assign | C1 | a6 | Test assignment six | Submit something! | Sub category 1 | 10 |
33 | assign | C1 | a7 | Test assignment seven | Submit nothing! | Sub category 1 | 15 |
34 And the following "activities" exist:
35 | activity | course | idnumber | name | intro | gradecategory | grade |
36 | assign | C1 | a8 | Test assignment eight | Submit something! | Sub category 2 | 20 |
37 | assign | C1 | a9 | Test assignment nine | Submit something! | Sub category 2 | 10 |
38 | assign | C1 | 10 | Test assignment ten | Submit nothing! | Sub category 2 | 15 |
39 And I log in as "admin"
40 And I set the following administration settings values:
41 | grade_aggregations_visible | Mean of grades,Weighted mean of grades,Simple weighted mean of grades,Mean of grades (with extra credits),Median of grades,Lowest grade,Highest grade,Mode of grades,Natural |
43 And I log in as "teacher1"
44 And I follow "Course 1"
45 And I navigate to "Grades" node in "Course administration"
46 And I turn editing mode on
47 And I give the grade "60.00" to the user "Student 1" for the grade item "Test assignment one"
48 And I give the grade "20.00" to the user "Student 1" for the grade item "Test assignment two"
49 And I give the grade "40.00" to the user "Student 1" for the grade item "Test assignment three"
50 And I give the grade "10.00" to the user "Student 1" for the grade item "Test assignment five"
51 And I give the grade "5.00" to the user "Student 1" for the grade item "Test assignment six"
52 And I give the grade "10.00" to the user "Student 1" for the grade item "Test assignment eight"
53 And I give the grade "5.00" to the user "Student 1" for the grade item "Test assignment nine"
54 And I press "Save changes"
55 And I set the following settings for grade item "Test assignment two":
57 And I set the following settings for grade item "Test assignment five":
59 And I set the following settings for grade item "Test assignment eight":
61 And I navigate to "Course grade settings" node in "Grade administration > Setup"
62 And I set the field "Grade display type" to "Real (percentage)"
63 And I press "Save changes"
65 Scenario: Mean of grades aggregation
66 And I set the following settings for grade item "Course 1":
67 | Aggregation | Mean of grades |
68 And I set the following settings for grade item "Sub category 1":
69 | Aggregation | Mean of grades |
70 And I set the following settings for grade item "Sub category 2":
71 | Aggregation | Mean of grades |
72 | Exclude empty grades | 0 |
73 And I turn editing mode off
74 Then I should see "30.00 (30.00 %)" in the ".course" "css_element"
75 And I navigate to "Course grade settings" node in "Grade administration > Setup"
76 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
77 And I press "Save changes"
79 And I log in as "student1"
80 And I follow "Grades" in the user menu
81 And I should see "30.42 (30.42 %)" in the "overview-grade" "table"
83 Scenario: Weighted mean of grades aggregation
84 And I set the following settings for grade item "Course 1":
85 | Aggregation | Weighted mean of grades |
86 And I set the following settings for grade item "Sub category 1":
87 | Aggregation | Weighted mean of grades |
89 And I set the following settings for grade item "Sub category 2":
90 | Aggregation | Weighted mean of grades |
92 | Exclude empty grades | 0 |
93 And I set the following settings for grade item "Test assignment one":
95 And I turn editing mode off
96 Then I should see "27.14 (27.14 %)" in the ".course" "css_element"
97 And I navigate to "Course grade settings" node in "Grade administration > Setup"
98 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
99 And I press "Save changes"
101 And I log in as "student1"
102 And I follow "Grades" in the user menu
103 And I should see "26.94 (26.94 %)" in the "overview-grade" "table"
105 Scenario: Simple weighted mean of grades aggregation
106 And I set the following settings for grade item "Course 1":
107 | Aggregation | Simple weighted mean of grades |
108 And I set the following settings for grade item "Sub category 1":
109 | Aggregation | Simple weighted mean of grades |
110 And I set the following settings for grade item "Sub category 2":
111 | Aggregation | Simple weighted mean of grades |
112 | Exclude empty grades | 0 |
113 And I set the following settings for grade item "Test assignment one":
115 And I turn editing mode off
116 Then I should see "45.19 (45.19 %)" in the ".course" "css_element"
117 And I navigate to "Course grade settings" node in "Grade administration > Setup"
118 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
119 And I press "Save changes"
121 And I log in as "student1"
122 And I follow "Grades" in the user menu
123 And I should see "48.57 (48.57 %)" in the "overview-grade" "table"
125 Scenario: Mean of grades (with extra credits) aggregation
126 And I set the following settings for grade item "Course 1":
127 | Aggregation | Mean of grades (with extra credits) |
128 And I set the following settings for grade item "Sub category 1":
129 | Aggregation | Mean of grades (with extra credits) |
130 And I set the following settings for grade item "Sub category 2":
131 | Aggregation | Mean of grades (with extra credits) |
132 | Exclude empty grades | 0 |
133 And I set the following settings for grade item "Test assignment one":
134 | Extra credit weight | 2 |
135 And I turn editing mode off
136 Then I should see "42.50 (42.50 %)" in the ".course" "css_element"
137 And I navigate to "Course grade settings" node in "Grade administration > Setup"
138 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
139 And I press "Save changes"
141 And I log in as "student1"
142 And I follow "Grades" in the user menu
143 And I should see "47.22 (47.22 %)" in the "overview-grade" "table"
145 Scenario: Median of grades aggregation
146 And I set the following settings for grade item "Course 1":
147 | Aggregation | Median of grades |
148 And I set the following settings for grade item "Sub category 1":
149 | Aggregation | Median of grades |
150 And I set the following settings for grade item "Sub category 2":
151 | Aggregation | Median of grades |
152 | Exclude empty grades | 0 |
153 And I turn editing mode off
154 Then I should see "26.67 (26.67 %)" in the ".course" "css_element"
155 And I navigate to "Course grade settings" node in "Grade administration > Setup"
156 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
157 And I press "Save changes"
159 And I log in as "student1"
160 And I follow "Grades" in the user menu
161 And I should see "25.83 (25.83 %)" in the "overview-grade" "table"
163 Scenario: Lowest grade aggregation
164 And I set the following settings for grade item "Course 1":
165 | Aggregation | Lowest grade |
166 And I set the following settings for grade item "Sub category 1":
167 | Aggregation | Lowest grade |
168 And I set the following settings for grade item "Sub category 2":
169 | Aggregation | Lowest grade |
170 | Exclude empty grades | 0 |
171 And I set the following settings for grade item "Test assignment five":
173 And I set the following settings for grade item "Test assignment four":
175 And I turn editing mode off
176 Then I should see "0.00 (0.00 %)" in the ".course" "css_element"
177 And I navigate to "Course grade settings" node in "Grade administration > Setup"
178 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
179 And I press "Save changes"
181 And I log in as "student1"
182 And I follow "Grades" in the user menu
183 And I should see "0.00 (0.00 %)" in the "overview-grade" "table"
185 Scenario: Highest grade aggregation
186 And I set the following settings for grade item "Course 1":
187 | Aggregation | Highest grade |
188 And I set the following settings for grade item "Sub category 1":
189 | Aggregation | Highest grade |
190 And I set the following settings for grade item "Sub category 2":
191 | Aggregation | Highest grade |
192 | Exclude empty grades | 0 |
193 And I set the following settings for grade item "Test assignment one":
195 And I turn editing mode off
196 Then I should see "50.00 (50.00 %)" in the ".course" "css_element"
197 And I navigate to "Course grade settings" node in "Grade administration > Setup"
198 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
199 And I press "Save changes"
201 And I log in as "student1"
202 And I follow "Grades" in the user menu
203 And I should see "50.00 (50.00 %)" in the "overview-grade" "table"
205 Scenario: Mode of grades aggregation
206 And I set the following settings for grade item "Course 1":
207 | Aggregation | Mode of grades |
208 And I set the following settings for grade item "Sub category 1":
209 | Aggregation | Mode of grades |
210 And I set the following settings for grade item "Sub category 1":
211 | Aggregation | Mode of grades |
212 | Exclude empty grades | 0 |
213 And I set the following settings for grade item "Test assignment one":
215 And I turn editing mode off
216 Then I should see "50.00 (50.00 %)" in the ".course" "css_element"
217 And I navigate to "Course grade settings" node in "Grade administration > Setup"
218 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
219 And I press "Save changes"
221 And I log in as "student1"
222 And I follow "Grades" in the user menu
223 And I should see "50.00 (50.00 %)" in the "overview-grade" "table"
225 Scenario: Natural aggregation on outcome items with natural weights
226 And the following config values are set as admin:
227 | enableoutcomes | 1 |
228 And the following "scales" exist:
230 | Test Scale | Disappointing, Good, Very good, Excellent |
231 And the following "grade outcomes" exist:
232 | fullname | shortname | course | scale |
233 | Outcome 1 | OT1 | C1 | Test Scale |
234 And the following "grade items" exist:
235 | itemname | course | outcome | gradetype | scale |
236 | Test outcome item one | C1 | OT1 | Scale | Test Scale |
237 And I expand "Setup" node
238 And I follow "Categories and items"
239 And I set the following settings for grade item "Course 1":
240 | Aggregation | Natural |
241 | Include outcomes in aggregation | 1 |
242 | Exclude empty grades | 0 |
243 And I follow "Grader report"
244 And I give the grade "Excellent" to the user "Student 1" for the grade item "Test outcome item one"
245 And I press "Save changes"
246 And I navigate to "Course grade settings" node in "Grade administration > Setup"
247 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
248 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
249 And I press "Save changes"
251 And I log in as "student1"
252 And I follow "Grades" in the user menu
253 Then I should see "114.82 (18.27 %)" in the "overview-grade" "table"
254 And I follow "Course 1"
255 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
257 And I log in as "teacher1"
258 And I follow "Course 1"
259 And I navigate to "Grades" node in "Course administration"
260 And I expand "Setup" node
261 And I follow "Categories and items"
262 And I set the following settings for grade item "Test outcome item one":
265 And I log in as "student1"
266 And I follow "Grades" in the user menu
267 Then I should see "114.00 (18.39 %)" in the "overview-grade" "table"
268 And I follow "Course 1"
269 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
271 And I log in as "teacher1"
272 And I follow "Course 1"
273 And I navigate to "Grades" node in "Course administration"
274 And I expand "Setup" node
275 And I follow "Categories and items"
276 And I set the following settings for grade item "Course 1":
277 | Aggregation | Natural |
278 | Include outcomes in aggregation | 0 |
280 And I log in as "student1"
281 And I follow "Grades" in the user menu
282 Then I should see "110.00 (17.74 %)" in the "overview-grade" "table"
283 And I follow "Course 1"
284 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
286 Scenario: Natural aggregation on outcome items with modified weights
287 And the following config values are set as admin:
288 | enableoutcomes | 1 |
289 And the following "scales" exist:
291 | Test Scale | Disappointing, Good, Very good, Excellent |
292 And the following "grade outcomes" exist:
293 | fullname | shortname | course | scale |
294 | Outcome 1 | OT1 | C1 | Test Scale |
295 And the following "grade items" exist:
296 | itemname | course | outcome | gradetype | scale |
297 | Test outcome item one | C1 | OT1 | Scale | Test Scale |
298 And I navigate to "Grades" node in "Course administration"
299 And I expand "Setup" node
300 And I follow "Categories and items"
301 And I set the following settings for grade item "Course 1":
302 | Aggregation | Natural |
303 | Include outcomes in aggregation | 1 |
304 | Exclude empty grades | 0 |
305 And I set the following settings for grade item "Test outcome item one":
306 | Weight adjusted | 1 |
307 | aggregationcoef2 | 100 |
308 And I follow "Grader report"
309 And I give the grade "Excellent" to the user "Student 1" for the grade item "Test outcome item one"
310 And I press "Save changes"
311 And I navigate to "Course grade settings" node in "Grade administration > Setup"
312 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
313 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
314 And I press "Save changes"
316 And I log in as "student1"
317 And I follow "Grades" in the user menu
318 Then I should see "4.00 (100.00 %)" in the "overview-grade" "table"
319 And I follow "Course 1"
320 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
322 Scenario: Natural aggregation
323 And I set the following settings for grade item "Sub category 1":
324 | Aggregation | Natural |
325 | Exclude empty grades | 0 |
326 And I set the following settings for grade item "Sub category 2":
327 | Aggregation | Natural |
328 | Exclude empty grades | 1 |
329 And I set the following settings for grade item "Course 1":
330 | Aggregation | Natural |
331 | Exclude empty grades | 0 |
332 And I set the following settings for grade item "Test assignment six":
333 | Weight adjusted | 1 |
334 | aggregationcoef2 | 50 |
335 And I set the following settings for grade item "Test assignment three":
337 And I turn editing mode off
338 Then I should see "152.68 (24.43 %)" in the ".course" "css_element"
339 And I navigate to "Course grade settings" node in "Grade administration > Setup"
340 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
341 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
342 And I set the field "Show contribution to course total" to "Show"
343 And I set the field "Show weightings" to "Show"
344 And I press "Save changes"
345 And I select "User report" from the "Grade report" singleselect
346 And I select "Student 1" from the "Select all or one user" singleselect
347 And the following should exist in the "user-grade" table:
348 | Grade item | Calculated weight | Grade | Range | Contribution to course total |
349 | Test assignment five | 28.57 % | 10.00 (50.00 %) | 0–20 | 1.03 % |
350 | Test assignment six | 50.00 % | 5.00 (50.00 %) | 0–10 | 1.80 % |
351 | Test assignment seven | 21.43 % | - | 0–15 | 0.00 % |
352 | Test assignment eight | 66.67 % | 10.00 (50.00 %) | 0–20 | 1.60 % |
353 | Test assignment nine | 33.33 % | 5.00 (50.00 %) | 0–10 | 0.80 % |
354 | Test assignment ten | 0.00 %( Empty ) | - | 0–15 | 0.00 % |
355 | Test assignment one | 48.00 % | 60.00 (20.00 %) | 0–300 | 9.60 % |
356 | Test assignment two | 16.00 % | 20.00 (20.00 %) | 0–100 | 3.20 % |
357 | Test assignment three | 24.00 %( Extra credit ) | 40.00 (26.67 %) | 0–150 | 6.40 % |
358 | Test assignment four | 24.00 % | - | 0–150 | 0.00 % |
360 And I log in as "student1"
361 And I follow "Grades" in the user menu
362 And I should see "113.75 (23.45 %)" in the "overview-grade" "table"
363 And I follow "Course 1"
364 And the following should exist in the "user-grade" table:
365 | Grade item | Calculated weight | Grade | Range | Contribution to course total |
366 | Test assignment six | 70.00 % | 5.00 (50.00 %) | 0–10 | 1.80 % |
367 | Test assignment seven | 30.00 % | - | 0–15 | 0.00 % |
368 | Test assignment nine | 100.00 % | 5.00 (50.00 %) | 0–10 | 1.03 % |
369 | Test assignment ten | -( Empty ) | - | 0–15 | - |
370 | Test assignment one | 61.86 % | 60.00 (20.00 %) | 0–300 | 12.37 % |
371 | Test assignment three | 30.93 %( Extra credit ) | 40.00 (26.67 %) | 0–150 | 8.25 % |
372 | Test assignment four | 30.93 % | - | 0–150 | 0.00 % |
374 Scenario: Natural aggregation with drop lowest
376 And I log in as "admin"
377 And I am on site homepage
378 And I follow "Course 1"
379 And I navigate to "Grades" node in "Course administration"
380 And I turn editing mode on
381 And I set the following settings for grade item "Sub category 1":
382 | Aggregation | Natural |
383 | Exclude empty grades | 0 |
384 And I set the following settings for grade item "Sub category 2":
385 | Aggregation | Natural |
386 | Exclude empty grades | 0 |
387 And I set the following settings for grade item "Course 1":
388 | Aggregation | Natural |
389 | Exclude empty grades | 0 |
390 And I navigate to "Categories and items" node in "Grade administration > Setup"
391 And I press "Add category"
392 And I set the following fields to these values:
393 | Category name | Sub category 3 |
394 | Aggregation | Natural |
395 | Drop the lowest | 1 |
396 And I press "Save changes"
397 And I press "Add grade item"
398 And I set the following fields to these values:
399 | Item name | Manual item 1 |
400 | Grade category | Sub category 3 |
401 And I press "Save changes"
402 And I press "Add grade item"
403 And I set the following fields to these values:
404 | Item name | Manual item 2 |
405 | Grade category | Sub category 3 |
406 And I press "Save changes"
407 And I press "Add grade item"
408 And I set the following fields to these values:
409 | Item name | Manual item 3 |
410 | Grade category | Sub category 3 |
411 And I press "Save changes"
412 And I follow "Grader report"
413 And I give the grade "60.00" to the user "Student 1" for the grade item "Manual item 1"
414 And I give the grade "20.00" to the user "Student 1" for the grade item "Manual item 2"
415 And I give the grade "40.00" to the user "Student 1" for the grade item "Manual item 3"
416 And I press "Save changes"
417 And I turn editing mode off
418 Then I should see "250.00 (25.25 %)" in the ".course" "css_element"
419 And I turn editing mode on
420 And I set the following settings for grade item "Manual item 2":
422 And I turn editing mode off
423 And I should see "270.00 (27.27 %)" in the ".course" "css_element"
424 And I turn editing mode on
425 And I set the following settings for grade item "Manual item 2":
427 | Maximum grade | 200 |
428 And I give the grade "21.00" to the user "Student 1" for the grade item "Manual item 2"
429 And I press "Save changes"
430 And I give the grade "20.00" to the user "Student 1" for the grade item "Manual item 2"
431 And I press "Save changes"
432 And I turn editing mode off
433 And I should see "270.00 (22.69 %)" in the ".course" "css_element"
434 And I turn editing mode on
435 And I set the following settings for grade item "Manual item 2":
437 | Maximum grade | 100 |
438 And I give the grade "21.00" to the user "Student 1" for the grade item "Manual item 2"
439 And I press "Save changes"
440 And I give the grade "20.00" to the user "Student 1" for the grade item "Manual item 2"
441 And I press "Save changes"
442 And I turn editing mode off
443 And I should see "250.00 (25.25 %)" in the ".course" "css_element"
444 And I navigate to "Categories and items" node in "Grade administration > Setup"
445 And I press "Add category"
446 And I set the following fields to these values:
447 | Category name | Sub sub category 1 |
448 | Parent category | Sub category 3 |
449 And I press "Save changes"
450 And I follow "Grader report"
451 And I should see "270.00 (24.77 %)" in the ".course" "css_element"
454 Scenario: Natural aggregation from the setup screen
455 And I select "Categories and items" from the "Grade report" singleselect
456 And I set the following settings for grade item "Course 1":
457 | Aggregation | Natural |
458 And I set the following settings for grade item "Sub category 1":
459 | Aggregation | Natural |
460 And I set the following settings for grade item "Sub category 2":
461 | Aggregation | Natural |
463 And I set the field "Override weight of Test assignment one" to "1"
464 And the field "Weight of Test assignment one" matches value "37.975"
465 And I set the field "Weight of Test assignment one" to "10"
467 And I set the field "Override weight of Test assignment two" to "1"
468 And the field "Weight of Test assignment two" matches value "12.658"
469 And I set the field "Override weight of Test assignment two" to "0"
471 And I set the field "Override weight of Test assignment six" to "1"
472 And the field "Weight of Test assignment six" matches value "22.222"
473 And I set the field "Weight of Test assignment six" to "50"
474 And I set the field "Override weight of Test assignment six" to "0"
476 And I set the field "Override weight of Test assignment ten" to "1"
477 And the field "Weight of Test assignment ten" matches value "33.333"
478 And I set the field "Weight of Test assignment ten" to "50"
480 And I set the field "Override weight of Sub category 1" to "1"
481 And the field "Weight of Sub category 1" matches value "5.696"
482 And I set the field "Weight of Sub category 1" to "15"
484 When I press "Save changes"
485 And I set the field "Override weight of Test assignment two" to "1"
486 And I set the field "Override weight of Test assignment six" to "1"
488 Then the field "Weight of Test assignment one" matches value "10.0"
489 And the field "Weight of Test assignment two" matches value "16.854"
490 And the field "Weight of Test assignment six" matches value "22.222"
491 And the field "Weight of Test assignment ten" matches value "50.0"
492 And the field "Weight of Sub category 1" matches value "15.0"
493 And I set the field "Override weight of Test assignment one" to "0"
494 And I set the field "Override weight of Test assignment two" to "0"
495 And I set the field "Override weight of Test assignment six" to "0"
496 And I set the field "Override weight of Sub category 1" to "0"
497 And I press "Save changes"
498 And I set the field "Override weight of Test assignment one" to "1"
499 And I set the field "Override weight of Sub category 1" to "1"
500 And the field "Weight of Test assignment one" matches value "37.975"
501 And the field "Weight of Sub category 1" matches value "5.696"
502 And I reset weights for grade category "Sub category 2"
503 And the field "Weight of Test assignment ten" matches value "33.333"
506 Scenario: Natural aggregation with weights of zero
507 When I set the following settings for grade item "Course 1":
508 | Aggregation | Natural |
509 | Exclude empty grades | 0 |
510 And I set the following settings for grade item "Sub category 1":
511 | Aggregation | Natural |
512 | Exclude empty grades | 0 |
513 And I set the following settings for grade item "Sub category 2":
514 | Aggregation | Natural |
515 | Exclude empty grades | 0 |
516 And I turn editing mode off
517 And I select "Categories and items" from the "Grade report" singleselect
518 And I set the field "Override weight of Test assignment one" to "1"
519 And I set the field "Weight of Test assignment one" to "0"
520 And I set the field "Override weight of Test assignment six" to "1"
521 And I set the field "Weight of Test assignment six" to "0"
522 And I set the field "Override weight of Test assignment nine" to "1"
523 And I set the field "Weight of Test assignment nine" to "100"
524 And I press "Save changes"
525 And I navigate to "Course grade settings" node in "Grade administration > Setup"
526 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
527 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
528 And I set the field "Show contribution to course total" to "Show"
529 And I set the field "Show weightings" to "Show"
530 And I press "Save changes"
531 Then I should see "75.00 (16.85 %)" in the ".course" "css_element"
532 And I select "User report" from the "Grade report" singleselect
533 And I select "Student 1" from the "Select all or one user" singleselect
534 And the following should exist in the "user-grade" table:
535 | Grade item | Calculated weight | Grade | Contribution to course total |
536 | Test assignment five | 57.14 % | 10.00 (50.00 %) | 2.25 % |
537 | Test assignment six | 0.00 % | 5.00 (50.00 %) | 0.00 % |
538 | Test assignment seven | 42.86 % | - | 0.00 % |
539 | Test assignment eight | 0.00 % | 10.00 (50.00 %) | 0.00 % |
540 | Test assignment nine | 100.00 % | 5.00 (50.00 %) | 1.12 % |
541 | Test assignment ten | 0.00 % | - | 0.00 % |
542 | Test assignment one | 0.00 % | 60.00 (20.00 %) | 0.00 % |
543 | Test assignment two | 22.47 % | 20.00 (20.00 %) | 4.49 % |
544 | Test assignment three | 33.71 % | 40.00 (26.67 %) | 8.99 % |
545 | Test assignment four | 33.71 % | - | 0.00 |
547 And I log in as "student1"
548 And I follow "Grades" in the user menu
549 And I should see "45.00 (13.85 %)" in the "overview-grade" "table"
550 And I follow "Course 1"
551 And the following should exist in the "user-grade" table:
552 | Grade item | Calculated weight | Grade | Contribution to course total |
553 | Test assignment six | 0.00 % | 5.00 (50.00 %) | 0.00 % |
554 | Test assignment seven | 100.00 % | - | 0.00 % |
555 | Test assignment nine | 100.00 % | 5.00 (50.00 %) | 1.54 % |
556 | Test assignment ten | 0.00 | - | 0.00 % |
557 | Test assignment one | 0.00 % | 60.00 (20.00 %) | 0.00 % |
558 | Test assignment three | 46.15 % | 40.00 (26.67 %) | 12.31 % |
559 | Test assignment four | 46.15 % | - | 0.00 % |