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"
66 Scenario: Mean of grades aggregation
67 And I set the following settings for grade item "Course 1":
68 | Aggregation | Mean of grades |
69 And I set the following settings for grade item "Sub category 1":
70 | Aggregation | Mean of grades |
71 And I set the following settings for grade item "Sub category 2":
72 | Aggregation | Mean of grades |
73 | Exclude empty grades | 0 |
74 And I turn editing mode off
75 Then I should see "30.00 (30.00 %)" in the ".course" "css_element"
76 And I navigate to "Course grade settings" node in "Grade administration > Setup"
77 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
78 And I press "Save changes"
80 And I log in as "student1"
81 And I follow "Grades" in the user menu
82 And I should see "30.42 (30.42 %)" in the "overview-grade" "table"
85 Scenario: Weighted mean of grades aggregation
86 And I set the following settings for grade item "Course 1":
87 | Aggregation | Weighted mean of grades |
88 And I set the following settings for grade item "Sub category 1":
89 | Aggregation | Weighted mean of grades |
91 And I set the following settings for grade item "Sub category 2":
92 | Aggregation | Weighted mean of grades |
94 | Exclude empty grades | 0 |
95 And I set the following settings for grade item "Test assignment one":
97 And I turn editing mode off
98 Then I should see "27.14 (27.14 %)" in the ".course" "css_element"
99 And I navigate to "Course grade settings" node in "Grade administration > Setup"
100 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
101 And I press "Save changes"
103 And I log in as "student1"
104 And I follow "Grades" in the user menu
105 And I should see "26.94 (26.94 %)" in the "overview-grade" "table"
108 Scenario: Simple weighted mean of grades aggregation
109 And I set the following settings for grade item "Course 1":
110 | Aggregation | Simple weighted mean of grades |
111 And I set the following settings for grade item "Sub category 1":
112 | Aggregation | Simple weighted mean of grades |
113 And I set the following settings for grade item "Sub category 2":
114 | Aggregation | Simple weighted mean of grades |
115 | Exclude empty grades | 0 |
116 And I set the following settings for grade item "Test assignment one":
118 And I turn editing mode off
119 Then I should see "45.19 (45.19 %)" in the ".course" "css_element"
120 And I navigate to "Course grade settings" node in "Grade administration > Setup"
121 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
122 And I press "Save changes"
124 And I log in as "student1"
125 And I follow "Grades" in the user menu
126 And I should see "48.57 (48.57 %)" in the "overview-grade" "table"
129 Scenario: Mean of grades (with extra credits) aggregation
130 And I set the following settings for grade item "Course 1":
131 | Aggregation | Mean of grades (with extra credits) |
132 And I set the following settings for grade item "Sub category 1":
133 | Aggregation | Mean of grades (with extra credits) |
134 And I set the following settings for grade item "Sub category 2":
135 | Aggregation | Mean of grades (with extra credits) |
136 | Exclude empty grades | 0 |
137 And I set the following settings for grade item "Test assignment one":
138 | Extra credit weight | 2 |
139 And I turn editing mode off
140 Then I should see "42.50 (42.50 %)" in the ".course" "css_element"
141 And I navigate to "Course grade settings" node in "Grade administration > Setup"
142 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
143 And I press "Save changes"
145 And I log in as "student1"
146 And I follow "Grades" in the user menu
147 And I should see "47.22 (47.22 %)" in the "overview-grade" "table"
150 Scenario: Median of grades aggregation
151 And I set the following settings for grade item "Course 1":
152 | Aggregation | Median of grades |
153 And I set the following settings for grade item "Sub category 1":
154 | Aggregation | Median of grades |
155 And I set the following settings for grade item "Sub category 2":
156 | Aggregation | Median of grades |
157 | Exclude empty grades | 0 |
158 And I turn editing mode off
159 Then I should see "26.67 (26.67 %)" in the ".course" "css_element"
160 And I navigate to "Course grade settings" node in "Grade administration > Setup"
161 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
162 And I press "Save changes"
164 And I log in as "student1"
165 And I follow "Grades" in the user menu
166 And I should see "25.83 (25.83 %)" in the "overview-grade" "table"
169 Scenario: Lowest grade aggregation
170 And I set the following settings for grade item "Course 1":
171 | Aggregation | Lowest grade |
172 And I set the following settings for grade item "Sub category 1":
173 | Aggregation | Lowest grade |
174 And I set the following settings for grade item "Sub category 2":
175 | Aggregation | Lowest grade |
176 | Exclude empty grades | 0 |
177 And I set the following settings for grade item "Test assignment five":
179 And I set the following settings for grade item "Test assignment four":
181 And I turn editing mode off
182 Then I should see "0.00 (0.00 %)" in the ".course" "css_element"
183 And I navigate to "Course grade settings" node in "Grade administration > Setup"
184 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
185 And I press "Save changes"
187 And I log in as "student1"
188 And I follow "Grades" in the user menu
189 And I should see "0.00 (0.00 %)" in the "overview-grade" "table"
192 Scenario: Highest grade aggregation
193 And I set the following settings for grade item "Course 1":
194 | Aggregation | Highest grade |
195 And I set the following settings for grade item "Sub category 1":
196 | Aggregation | Highest grade |
197 And I set the following settings for grade item "Sub category 2":
198 | Aggregation | Highest grade |
199 | Exclude empty grades | 0 |
200 And I set the following settings for grade item "Test assignment one":
202 And I turn editing mode off
203 Then I should see "50.00 (50.00 %)" in the ".course" "css_element"
204 And I navigate to "Course grade settings" node in "Grade administration > Setup"
205 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
206 And I press "Save changes"
208 And I log in as "student1"
209 And I follow "Grades" in the user menu
210 And I should see "50.00 (50.00 %)" in the "overview-grade" "table"
213 Scenario: Mode of grades aggregation
214 And I set the following settings for grade item "Course 1":
215 | Aggregation | Mode of grades |
216 And I set the following settings for grade item "Sub category 1":
217 | Aggregation | Mode of grades |
218 And I set the following settings for grade item "Sub category 1":
219 | Aggregation | Mode of grades |
220 | Exclude empty grades | 0 |
221 And I set the following settings for grade item "Test assignment one":
223 And I turn editing mode off
224 Then I should see "50.00 (50.00 %)" in the ".course" "css_element"
225 And I navigate to "Course grade settings" node in "Grade administration > Setup"
226 And I set the field "Hide totals if they contain hidden items" to "Show totals excluding hidden items"
227 And I press "Save changes"
229 And I log in as "student1"
230 And I follow "Grades" in the user menu
231 And I should see "50.00 (50.00 %)" in the "overview-grade" "table"
234 Scenario: Natural aggregation on outcome items with natural weights
235 And the following config values are set as admin:
236 | enableoutcomes | 1 |
237 And the following "scales" exist:
239 | Test Scale | Disappointing, Good, Very good, Excellent |
240 And the following "grade outcomes" exist:
241 | fullname | shortname | course | scale |
242 | Outcome 1 | OT1 | C1 | Test Scale |
243 And the following "grade items" exist:
244 | itemname | course | outcome | gradetype | scale |
245 | Test outcome item one | C1 | OT1 | Scale | Test Scale |
246 And I expand "Setup" node
247 And I follow "Categories and items"
248 And I set the following settings for grade item "Course 1":
249 | Aggregation | Natural |
250 | Include outcomes in aggregation | 1 |
251 | Exclude empty grades | 0 |
252 And I follow "Grader report"
253 And I give the grade "Excellent" to the user "Student 1" for the grade item "Test outcome item one"
254 And I press "Save changes"
255 And I navigate to "Course grade settings" node in "Grade administration > Setup"
256 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
257 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
258 And I press "Save changes"
260 And I log in as "student1"
261 And I follow "Grades" in the user menu
262 Then I should see "114.82 (18.27 %)" in the "overview-grade" "table"
263 And I follow "Course 1"
264 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
266 And I log in as "teacher1"
267 And I follow "Course 1"
268 And I navigate to "Grades" node in "Course administration"
269 And I expand "Setup" node
270 And I follow "Categories and items"
271 And I set the following settings for grade item "Test outcome item one":
274 And I log in as "student1"
275 And I follow "Grades" in the user menu
276 Then I should see "114.00 (18.39 %)" in the "overview-grade" "table"
277 And I follow "Course 1"
278 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
280 And I log in as "teacher1"
281 And I follow "Course 1"
282 And I navigate to "Grades" node in "Course administration"
283 And I expand "Setup" node
284 And I follow "Categories and items"
285 And I set the following settings for grade item "Course 1":
286 | Aggregation | Natural |
287 | Include outcomes in aggregation | 0 |
289 And I log in as "student1"
290 And I follow "Grades" in the user menu
291 Then I should see "110.00 (17.74 %)" in the "overview-grade" "table"
292 And I follow "Course 1"
293 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
296 Scenario: Natural aggregation on outcome items with modified weights
297 And the following config values are set as admin:
298 | enableoutcomes | 1 |
299 And the following "scales" exist:
301 | Test Scale | Disappointing, Good, Very good, Excellent |
302 And the following "grade outcomes" exist:
303 | fullname | shortname | course | scale |
304 | Outcome 1 | OT1 | C1 | Test Scale |
305 And the following "grade items" exist:
306 | itemname | course | outcome | gradetype | scale |
307 | Test outcome item one | C1 | OT1 | Scale | Test Scale |
308 And I navigate to "Grades" node in "Course administration"
309 And I expand "Setup" node
310 And I follow "Categories and items"
311 And I set the following settings for grade item "Course 1":
312 | Aggregation | Natural |
313 | Include outcomes in aggregation | 1 |
314 | Exclude empty grades | 0 |
315 And I set the following settings for grade item "Test outcome item one":
316 | Weight adjusted | 1 |
317 | aggregationcoef2 | 100 |
318 And I follow "Grader report"
319 And I give the grade "Excellent" to the user "Student 1" for the grade item "Test outcome item one"
320 And I press "Save changes"
321 And I navigate to "Course grade settings" node in "Grade administration > Setup"
322 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
323 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
324 And I press "Save changes"
326 And I log in as "student1"
327 And I follow "Grades" in the user menu
328 Then I should see "4.00 (100.00 %)" in the "overview-grade" "table"
329 And I follow "Course 1"
330 And "Test outcome item one" row "Grade" column of "user-grade" table should contain "Excellent (100.00 %)"
333 Scenario: Natural aggregation
334 And I set the following settings for grade item "Sub category 1":
335 | Aggregation | Natural |
336 | Exclude empty grades | 0 |
337 And I set the following settings for grade item "Sub category 2":
338 | Aggregation | Natural |
339 | Exclude empty grades | 1 |
340 And I set the following settings for grade item "Course 1":
341 | Aggregation | Natural |
342 | Exclude empty grades | 0 |
343 And I set the following settings for grade item "Test assignment six":
344 | Weight adjusted | 1 |
345 | aggregationcoef2 | 50 |
346 And I set the following settings for grade item "Test assignment three":
348 And I turn editing mode off
349 Then I should see "152.68 (24.43 %)" in the ".course" "css_element"
350 And I navigate to "Course grade settings" node in "Grade administration > Setup"
351 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
352 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
353 And I set the field "Show contribution to course total" to "Show"
354 And I set the field "Show weightings" to "Show"
355 And I press "Save changes"
356 And I set the field "Grade report" to "User report"
357 And I set the field "Select all or one user" to "Student 1"
358 And the following should exist in the "user-grade" table:
359 | Grade item | Calculated weight | Grade | Range | Contribution to course total |
360 | Test assignment five | 28.57 % | 10.00 (50.00 %) | 0–20 | 1.03 % |
361 | Test assignment six | 50.00 % | 5.00 (50.00 %) | 0–10 | 1.80 % |
362 | Test assignment seven | 21.43 % | - | 0–15 | 0.00 % |
363 | Test assignment eight | 66.67 % | 10.00 (50.00 %) | 0–20 | 1.60 % |
364 | Test assignment nine | 33.33 % | 5.00 (50.00 %) | 0–10 | 0.80 % |
365 | Test assignment ten | 0.00 %( Empty ) | - | 0–15 | 0.00 % |
366 | Test assignment one | 48.00 % | 60.00 (20.00 %) | 0–300 | 9.60 % |
367 | Test assignment two | 16.00 % | 20.00 (20.00 %) | 0–100 | 3.20 % |
368 | Test assignment three | 24.00 %( Extra credit ) | 40.00 (26.67 %) | 0–150 | 6.40 % |
369 | Test assignment four | 24.00 % | - | 0–150 | 0.00 % |
371 And I log in as "student1"
372 And I follow "Grades" in the user menu
373 And I should see "113.75 (23.45 %)" in the "overview-grade" "table"
374 And I follow "Course 1"
375 And the following should exist in the "user-grade" table:
376 | Grade item | Calculated weight | Grade | Range | Contribution to course total |
377 | Test assignment six | 70.00 % | 5.00 (50.00 %) | 0–10 | 1.80 % |
378 | Test assignment seven | 30.00 % | - | 0–15 | 0.00 % |
379 | Test assignment nine | 100.00 % | 5.00 (50.00 %) | 0–10 | 1.03 % |
380 | Test assignment ten | -( Empty ) | - | 0–15 | - |
381 | Test assignment one | 61.86 % | 60.00 (20.00 %) | 0–300 | 12.37 % |
382 | Test assignment three | 30.93 %( Extra credit ) | 40.00 (26.67 %) | 0–150 | 8.25 % |
383 | Test assignment four | 30.93 % | - | 0–150 | 0.00 % |
386 Scenario: Natural aggregation with drop lowest
388 And I log in as "admin"
389 And I am on site homepage
390 And I follow "Course 1"
391 And I navigate to "Grades" node in "Course administration"
392 And I turn editing mode on
393 And I set the following settings for grade item "Sub category 1":
394 | Aggregation | Natural |
395 | Exclude empty grades | 0 |
396 And I set the following settings for grade item "Sub category 2":
397 | Aggregation | Natural |
398 | Exclude empty grades | 0 |
399 And I set the following settings for grade item "Course 1":
400 | Aggregation | Natural |
401 | Exclude empty grades | 0 |
402 And I navigate to "Categories and items" node in "Grade administration > Setup"
403 And I press "Add category"
404 And I click on "Show more" "link"
405 And I set the following fields to these values:
406 | Category name | Sub category 3 |
407 | Aggregation | Natural |
408 | Drop the lowest | 1 |
409 And I press "Save changes"
410 And I press "Add grade item"
411 And I set the following fields to these values:
412 | Item name | Manual item 1 |
413 | Grade category | Sub category 3 |
414 And I press "Save changes"
415 And I press "Add grade item"
416 And I set the following fields to these values:
417 | Item name | Manual item 2 |
418 | Grade category | Sub category 3 |
419 And I press "Save changes"
420 And I press "Add grade item"
421 And I set the following fields to these values:
422 | Item name | Manual item 3 |
423 | Grade category | Sub category 3 |
424 And I press "Save changes"
425 And I follow "Grader report"
426 And I give the grade "60.00" to the user "Student 1" for the grade item "Manual item 1"
427 And I give the grade "20.00" to the user "Student 1" for the grade item "Manual item 2"
428 And I give the grade "40.00" to the user "Student 1" for the grade item "Manual item 3"
429 And I press "Save changes"
430 And I turn editing mode off
431 Then I should see "250.00 (25.25 %)" in the ".course" "css_element"
432 And I turn editing mode on
433 And I set the following settings for grade item "Manual item 2":
435 And I turn editing mode off
436 And I should see "270.00 (27.27 %)" in the ".course" "css_element"
437 And I turn editing mode on
438 And I set the following settings for grade item "Manual item 2":
440 | Maximum grade | 200 |
441 And I give the grade "21.00" to the user "Student 1" for the grade item "Manual item 2"
442 And I press "Save changes"
443 And I give the grade "20.00" to the user "Student 1" for the grade item "Manual item 2"
444 And I press "Save changes"
445 And I turn editing mode off
446 And I should see "270.00 (22.69 %)" in the ".course" "css_element"
447 And I turn editing mode on
448 And I set the following settings for grade item "Manual item 2":
450 | Maximum grade | 100 |
451 And I give the grade "21.00" to the user "Student 1" for the grade item "Manual item 2"
452 And I press "Save changes"
453 And I give the grade "20.00" to the user "Student 1" for the grade item "Manual item 2"
454 And I press "Save changes"
455 And I turn editing mode off
456 And I should see "250.00 (25.25 %)" in the ".course" "css_element"
457 And I navigate to "Categories and items" node in "Grade administration > Setup"
458 And I press "Add category"
459 And I set the following fields to these values:
460 | Category name | Sub sub category 1 |
461 | Parent category | Sub category 3 |
462 And I press "Save changes"
463 And I follow "Grader report"
464 And I should see "270.00 (24.77 %)" in the ".course" "css_element"
467 Scenario: Natural aggregation from the setup screen
468 And I set the field "Grade report" to "Categories and items"
469 And I set the following settings for grade item "Course 1":
470 | Aggregation | Natural |
471 And I set the following settings for grade item "Sub category 1":
472 | Aggregation | Natural |
473 And I set the following settings for grade item "Sub category 2":
474 | Aggregation | Natural |
476 And I set the field "Override weight of Test assignment one" to "1"
477 And the field "Weight of Test assignment one" matches value "37.975"
478 And I set the field "Weight of Test assignment one" to "10"
480 And I set the field "Override weight of Test assignment two" to "1"
481 And the field "Weight of Test assignment two" matches value "12.658"
482 And I set the field "Override weight of Test assignment two" to "0"
484 And I set the field "Override weight of Test assignment six" to "1"
485 And the field "Weight of Test assignment six" matches value "22.222"
486 And I set the field "Weight of Test assignment six" to "50"
487 And I set the field "Override weight of Test assignment six" to "0"
489 And I set the field "Override weight of Test assignment ten" to "1"
490 And the field "Weight of Test assignment ten" matches value "33.333"
491 And I set the field "Weight of Test assignment ten" to "50"
493 And I set the field "Override weight of Sub category 1" to "1"
494 And the field "Weight of Sub category 1" matches value "5.696"
495 And I set the field "Weight of Sub category 1" to "15"
497 When I press "Save changes"
498 And I set the field "Override weight of Test assignment two" to "1"
499 And I set the field "Override weight of Test assignment six" to "1"
501 Then the field "Weight of Test assignment one" matches value "10.0"
502 And the field "Weight of Test assignment two" matches value "16.854"
503 And the field "Weight of Test assignment six" matches value "22.222"
504 And the field "Weight of Test assignment ten" matches value "50.0"
505 And the field "Weight of Sub category 1" matches value "15.0"
506 And I set the field "Override weight of Test assignment one" to "0"
507 And I set the field "Override weight of Test assignment two" to "0"
508 And I set the field "Override weight of Test assignment six" to "0"
509 And I set the field "Override weight of Sub category 1" to "0"
510 And I press "Save changes"
511 And I set the field "Override weight of Test assignment one" to "1"
512 And I set the field "Override weight of Sub category 1" to "1"
513 And the field "Weight of Test assignment one" matches value "37.975"
514 And the field "Weight of Sub category 1" matches value "5.696"
515 And I reset weights for grade category "Sub category 2"
516 And the field "Weight of Test assignment ten" matches value "33.333"
519 Scenario: Natural aggregation with weights of zero
520 When I set the following settings for grade item "Course 1":
521 | Aggregation | Natural |
522 | Exclude empty grades | 0 |
523 And I set the following settings for grade item "Sub category 1":
524 | Aggregation | Natural |
525 | Exclude empty grades | 0 |
526 And I set the following settings for grade item "Sub category 2":
527 | Aggregation | Natural |
528 | Exclude empty grades | 0 |
529 And I turn editing mode off
530 And I set the field "Grade report" to "Categories and items"
531 And I set the field "Override weight of Test assignment one" to "1"
532 And I set the field "Weight of Test assignment one" to "0"
533 And I set the field "Override weight of Test assignment six" to "1"
534 And I set the field "Weight of Test assignment six" to "0"
535 And I set the field "Override weight of Test assignment nine" to "1"
536 And I set the field "Weight of Test assignment nine" to "100"
537 And I press "Save changes"
538 And I navigate to "Course grade settings" node in "Grade administration > Setup"
539 And I set the field "report_overview_showtotalsifcontainhidden" to "Show totals excluding hidden items"
540 And I set the field "report_user_showtotalsifcontainhidden" to "Show totals excluding hidden items"
541 And I set the field "Show contribution to course total" to "Show"
542 And I set the field "Show weightings" to "Show"
543 And I press "Save changes"
544 Then I should see "75.00 (16.85 %)" in the ".course" "css_element"
545 And I set the field "Grade report" to "User report"
546 And I set the field "Select all or one user" to "Student 1"
547 And the following should exist in the "user-grade" table:
548 | Grade item | Calculated weight | Grade | Contribution to course total |
549 | Test assignment five | 57.14 % | 10.00 (50.00 %) | 2.25 % |
550 | Test assignment six | 0.00 % | 5.00 (50.00 %) | 0.00 % |
551 | Test assignment seven | 42.86 % | - | 0.00 % |
552 | Test assignment eight | 0.00 % | 10.00 (50.00 %) | 0.00 % |
553 | Test assignment nine | 100.00 % | 5.00 (50.00 %) | 1.12 % |
554 | Test assignment ten | 0.00 % | - | 0.00 % |
555 | Test assignment one | 0.00 % | 60.00 (20.00 %) | 0.00 % |
556 | Test assignment two | 22.47 % | 20.00 (20.00 %) | 4.49 % |
557 | Test assignment three | 33.71 % | 40.00 (26.67 %) | 8.99 % |
558 | Test assignment four | 33.71 % | - | 0.00 |
560 And I log in as "student1"
561 And I follow "Grades" in the user menu
562 And I should see "45.00 (13.85 %)" in the "overview-grade" "table"
563 And I follow "Course 1"
564 And the following should exist in the "user-grade" table:
565 | Grade item | Calculated weight | Grade | Contribution to course total |
566 | Test assignment six | 0.00 % | 5.00 (50.00 %) | 0.00 % |
567 | Test assignment seven | 100.00 % | - | 0.00 % |
568 | Test assignment nine | 100.00 % | 5.00 (50.00 %) | 1.54 % |
569 | Test assignment ten | 0.00 | - | 0.00 % |
570 | Test assignment one | 0.00 % | 60.00 (20.00 %) | 0.00 % |
571 | Test assignment three | 46.15 % | 40.00 (26.67 %) | 12.31 % |
572 | Test assignment four | 46.15 % | - | 0.00 % |