1 |
efrain |
1 |
@core @core_grades
|
|
|
2 |
Feature: We can understand the gradebook user report
|
|
|
3 |
In order to understand the gradebook user report
|
|
|
4 |
As an teacher
|
|
|
5 |
I need to see the calculated weights for each type of aggregation
|
|
|
6 |
|
|
|
7 |
Background:
|
|
|
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 "activities" exist:
|
|
|
20 |
| activity | course | idnumber | name | intro |
|
|
|
21 |
| assign | C1 | a1 | Test assignment one | Submit something! |
|
|
|
22 |
| assign | C1 | a2 | Test assignment two | Submit something! |
|
|
|
23 |
| assign | C1 | a3 | Test assignment three | Submit something! |
|
|
|
24 |
| assign | C1 | a4 | Test assignment four | Submit something! |
|
|
|
25 |
| assign | C1 | a5 | Test assignment five | Submit something! |
|
|
|
26 |
| assign | C1 | a6 | Test assignment six | Submit something! |
|
|
|
27 |
And I log in as "admin"
|
|
|
28 |
And I set the following administration settings values:
|
|
|
29 |
| 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 |
|
|
|
30 |
And the following "grade grades" exist:
|
|
|
31 |
| gradeitem | user | grade |
|
|
|
32 |
| Test assignment one | student1 | 60.00 |
|
|
|
33 |
| Test assignment two | student1 | 20.00 |
|
|
|
34 |
| Test assignment three | student1 | 40.00 |
|
|
|
35 |
| Test assignment four | student1 | 10.00 |
|
|
|
36 |
| Test assignment five | student1 | 70.00 |
|
|
|
37 |
| Test assignment six | student1 | 30.00 |
|
|
|
38 |
And I am on the "Course 1" "grades > course grade settings" page logged in as "teacher1"
|
|
|
39 |
And I set the field "Show weightings" to "Show"
|
|
|
40 |
And I set the field "Show contribution to course total" to "Show"
|
|
|
41 |
And I press "Save changes"
|
|
|
42 |
And I navigate to "Setup > Gradebook setup" in the course gradebook
|
|
|
43 |
And I choose the "Add category" item in the "Add" action menu
|
|
|
44 |
And I set the field "Category name" to "Sub category"
|
|
|
45 |
And I click on "Save" "button" in the "New category" "dialogue"
|
|
|
46 |
And I wait until the page is ready
|
|
|
47 |
And I click on "Move" "link" in the "Test assignment six" "table_row"
|
|
|
48 |
# This xpath finds the forth last row in the table.
|
|
|
49 |
And I click on "Move to here" "link" in the "//tbody//tr[position()=last()-3]" "xpath_element"
|
|
|
50 |
And I click on "Move" "link" in the "Test assignment five" "table_row"
|
|
|
51 |
And I click on "Move to here" "link" in the "//tbody//tr[position()=last()-3]" "xpath_element"
|
|
|
52 |
And I click on "Move" "link" in the "Test assignment four" "table_row"
|
|
|
53 |
And I click on "Move to here" "link" in the "//tbody//tr[position()=last()-3]" "xpath_element"
|
|
|
54 |
|
|
|
55 |
@javascript @skip_chrome_zerosize
|
|
|
56 |
Scenario: Mean of grades aggregation
|
|
|
57 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
58 |
| Aggregation | Mean of grades |
|
|
|
59 |
And I navigate to "View > User report" in the course gradebook
|
|
|
60 |
And I click on "Student 1" in the "user" search widget
|
|
|
61 |
|
|
|
62 |
# Check the values in the weights column.
|
|
|
63 |
Then the following should exist in the "user-grade" table:
|
|
|
64 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
65 |
| Test assignment one | 25.00 % | 60.00 | 15.00 % |
|
|
|
66 |
| Test assignment two | 25.00 % | 20.00 | 5.00 % |
|
|
|
67 |
| Test assignment three | 25.00 % | 40.00 | 10.00 % |
|
|
|
68 |
| Test assignment four | 33.33 % | 10.00 | 0.83 % |
|
|
|
69 |
| Test assignment five | 33.33 % | 70.00 | 5.83 % |
|
|
|
70 |
| Test assignment six | 33.33 % | 30.00 | 2.50 % |
|
|
|
71 |
|
|
|
72 |
@javascript @skip_chrome_zerosize
|
|
|
73 |
Scenario: Weighted mean of grades aggregation
|
|
|
74 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
75 |
| Aggregation | Weighted mean of grades |
|
|
|
76 |
And I set the following settings for grade item "Test assignment one" of type "gradeitem" on "setup" page:
|
|
|
77 |
| Item weight | 2.0 |
|
|
|
78 |
And I set the following settings for grade item "Test assignment two" of type "gradeitem" on "setup" page:
|
|
|
79 |
| Item weight | 1.0 |
|
|
|
80 |
And I set the following settings for grade item "Test assignment three" of type "gradeitem" on "setup" page:
|
|
|
81 |
| Item weight | 1.0 |
|
|
|
82 |
And I set the following settings for grade item "Sub category" of type "category" on "setup" page:
|
|
|
83 |
| Item weight | 1.0 |
|
|
|
84 |
And I navigate to "View > User report" in the course gradebook
|
|
|
85 |
And I click on "Student 1" in the "user" search widget
|
|
|
86 |
|
|
|
87 |
# Check the values in the weights column.
|
|
|
88 |
Then the following should exist in the "user-grade" table:
|
|
|
89 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
90 |
| Test assignment one | 40.00 % | 60.00 | 24.00 % |
|
|
|
91 |
| Test assignment two | 20.00 % | 20.00 | 4.00 % |
|
|
|
92 |
| Test assignment three | 20.00 % | 40.00 | 8.00 % |
|
|
|
93 |
| Test assignment four | 33.33 % | 10.00 | 0.67 % |
|
|
|
94 |
| Test assignment five | 33.33 % | 70.00 | 4.67 % |
|
|
|
95 |
| Test assignment six | 33.33 % | 30.00 | 2.00 % |
|
|
|
96 |
|
|
|
97 |
@javascript @skip_chrome_zerosize
|
|
|
98 |
Scenario: Simple weighted mean of grades aggregation
|
|
|
99 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
100 |
| Aggregation | Simple weighted mean of grades |
|
|
|
101 |
And I set the following settings for grade item "Sub category" of type "category" on "setup" page:
|
|
|
102 |
| Aggregation | Simple weighted mean of grades |
|
|
|
103 |
And I set the following settings for grade item "Test assignment three" of type "gradeitem" on "setup" page:
|
|
|
104 |
| Extra credit | 1 |
|
|
|
105 |
And I navigate to "View > User report" in the course gradebook
|
|
|
106 |
And I click on "Student 1" in the "user" search widget
|
|
|
107 |
|
|
|
108 |
# Check the values in the weights column.
|
|
|
109 |
Then the following should exist in the "user-grade" table:
|
|
|
110 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
111 |
| Test assignment one | 33.33 % | 60.00 | 20.00 % |
|
|
|
112 |
| Test assignment two | 33.33 % | 20.00 | 6.67 % |
|
|
|
113 |
| Test assignment three | 33.33 %( Extra credit ) | 40.00 | 13.33 % |
|
|
|
114 |
| Test assignment four | 33.33 % | 10.00 | 1.11 % |
|
|
|
115 |
| Test assignment five | 33.33 % | 70.00 | 7.78 % |
|
|
|
116 |
| Test assignment six | 33.33 % | 30.00 | 3.33 % |
|
|
|
117 |
|
|
|
118 |
@javascript @skip_chrome_zerosize
|
|
|
119 |
Scenario: Mean of grades (with extra credits) aggregation
|
|
|
120 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
121 |
| Aggregation | Mean of grades (with extra credits) |
|
|
|
122 |
And I set the following settings for grade item "Test assignment three" of type "gradeitem" on "setup" page:
|
|
|
123 |
| Extra credit weight | 1.0 |
|
|
|
124 |
And I navigate to "View > User report" in the course gradebook
|
|
|
125 |
And I click on "Student 1" in the "user" search widget
|
|
|
126 |
|
|
|
127 |
# Check the values in the weights column.
|
|
|
128 |
Then the following should exist in the "user-grade" table:
|
|
|
129 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
130 |
| Test assignment one | 33.33 % | 60.00 | 20.00 % |
|
|
|
131 |
| Test assignment two | 33.33 % | 20.00 | 6.67 % |
|
|
|
132 |
| Test assignment three | 33.33 %( Extra credit ) | 40.00 | 13.33 % |
|
|
|
133 |
| Test assignment four | 33.33 % | 10.00 | 1.11 % |
|
|
|
134 |
| Test assignment five | 33.33 % | 70.00 | 7.78 % |
|
|
|
135 |
| Test assignment six | 33.33 % | 30.00 | 3.33 % |
|
|
|
136 |
|
|
|
137 |
@javascript @skip_chrome_zerosize
|
|
|
138 |
Scenario: Median of grades aggregation
|
|
|
139 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
140 |
| Aggregation | Median of grades |
|
|
|
141 |
And I navigate to "View > User report" in the course gradebook
|
|
|
142 |
And I click on "Student 1" in the "user" search widget
|
|
|
143 |
|
|
|
144 |
# Check the values in the weights column.
|
|
|
145 |
Then the following should exist in the "user-grade" table:
|
|
|
146 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
147 |
| Test assignment one | 0.00 % | 60.00 | 0.00 % |
|
|
|
148 |
| Test assignment two | 0.00 % | 20.00 | 0.00 % |
|
|
|
149 |
| Test assignment three | 50.00 % | 40.00 | 20.00 % |
|
|
|
150 |
| Test assignment four | 33.33 % | 10.00 | 1.67 % |
|
|
|
151 |
| Test assignment five | 33.33 % | 70.00 | 11.67 % |
|
|
|
152 |
| Test assignment six | 33.33 % | 30.00 | 5.00 % |
|
|
|
153 |
|
|
|
154 |
@javascript @skip_chrome_zerosize
|
|
|
155 |
Scenario: Lowest grade aggregation
|
|
|
156 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
157 |
| Aggregation | Lowest grade |
|
|
|
158 |
And I navigate to "View > User report" in the course gradebook
|
|
|
159 |
And I click on "Student 1" in the "user" search widget
|
|
|
160 |
|
|
|
161 |
# Check the values in the weights column.
|
|
|
162 |
Then the following should exist in the "user-grade" table:
|
|
|
163 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
164 |
| Test assignment one | 0.00 % | 60.00 | 0.00 % |
|
|
|
165 |
| Test assignment two | 100.00 % | 20.00 | 20.00 % |
|
|
|
166 |
| Test assignment three | 0.00 % | 40.00 | 0.00 % |
|
|
|
167 |
| Test assignment four | 33.33 % | 10.00 | 0.00 % |
|
|
|
168 |
| Test assignment five | 33.33 % | 70.00 | 0.00 % |
|
|
|
169 |
| Test assignment six | 33.33 % | 30.00 | 0.00 % |
|
|
|
170 |
|
|
|
171 |
@javascript @skip_chrome_zerosize
|
|
|
172 |
Scenario: Highest grade aggregation
|
|
|
173 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
174 |
| Aggregation | Highest grade |
|
|
|
175 |
And I navigate to "View > User report" in the course gradebook
|
|
|
176 |
And I click on "Student 1" in the "user" search widget
|
|
|
177 |
|
|
|
178 |
# Check the values in the weights column.
|
|
|
179 |
Then the following should exist in the "user-grade" table:
|
|
|
180 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
181 |
| Test assignment one | 100.00 % | 60.00 | 60.00 % |
|
|
|
182 |
| Test assignment two | 0.00 % | 20.00 | 0.00 % |
|
|
|
183 |
| Test assignment three | 0.00 % | 40.00 | 0.00 % |
|
|
|
184 |
| Test assignment four | 33.33 % | 10.00 | 0.00 % |
|
|
|
185 |
| Test assignment five | 33.33 % | 70.00 | 0.00 % |
|
|
|
186 |
| Test assignment six | 33.33 % | 30.00 | 0.00 % |
|
|
|
187 |
|
|
|
188 |
@javascript @skip_chrome_zerosize
|
|
|
189 |
Scenario: Mode of grades aggregation
|
|
|
190 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
191 |
| Aggregation | Mode of grades |
|
|
|
192 |
And I navigate to "View > User report" in the course gradebook
|
|
|
193 |
And I click on "Student 1" in the "user" search widget
|
|
|
194 |
|
|
|
195 |
# Check the values in the weights column.
|
|
|
196 |
Then the following should exist in the "user-grade" table:
|
|
|
197 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
198 |
| Test assignment one | 100.00 % | 60.00 | 60.00 % |
|
|
|
199 |
| Test assignment two | 0.00 % | 20.00 | 0.00 % |
|
|
|
200 |
| Test assignment three | 0.00 % | 40.00 | 0.00 % |
|
|
|
201 |
| Test assignment four | 33.33 % | 10.00 | 0.00 % |
|
|
|
202 |
| Test assignment five | 33.33 % | 70.00 | 0.00 % |
|
|
|
203 |
| Test assignment six | 33.33 % | 30.00 | 0.00 % |
|
|
|
204 |
|
|
|
205 |
@javascript @skip_chrome_zerosize
|
|
|
206 |
Scenario: View user report with mixed aggregation methods
|
|
|
207 |
And I change window size to "large"
|
|
|
208 |
And I set the following settings for grade item "Course 1" of type "course" on "setup" page:
|
|
|
209 |
| Aggregation | Natural |
|
|
|
210 |
And I set the following settings for grade item "Sub category" of type "category" on "setup" page:
|
|
|
211 |
| Aggregation | Weighted mean of grades |
|
|
|
212 |
And I set the following settings for grade item "Test assignment three" of type "gradeitem" on "setup" page:
|
|
|
213 |
| aggregationcoef | 1 |
|
|
|
214 |
And I navigate to "View > User report" in the course gradebook
|
|
|
215 |
And I click on "Student 1" in the "user" search widget
|
|
|
216 |
|
|
|
217 |
# Check the values in the weights column.
|
|
|
218 |
Then the following should exist in the "user-grade" table:
|
|
|
219 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
220 |
| Test assignment one | 33.33 % | 60.00 | 20.00 % |
|
|
|
221 |
| Test assignment two | 33.33 % | 20.00 | 6.67 % |
|
|
|
222 |
| Test assignment three | 33.33 %( Extra credit ) | 40.00 | 13.33 % |
|
|
|
223 |
| Test assignment four | 33.33 % | 10.00 | 1.11 % |
|
|
|
224 |
| Test assignment five | 33.33 % | 70.00 | 7.78 % |
|
|
|
225 |
| Test assignment six | 33.33 % | 30.00 | 3.33 % |
|
|
|
226 |
| Sub category total | 33.33 % | 36.67 | - |
|
|
|
227 |
| Course total | - | 156.67 | - |
|
|
|
228 |
|
|
|
229 |
@javascript @skip_chrome_zerosize
|
|
|
230 |
Scenario: View user report with natural aggregation
|
|
|
231 |
And I set the following settings for grade item "Test assignment three" of type "gradeitem" on "setup" page:
|
|
|
232 |
| Extra credit | 1 |
|
|
|
233 |
And I navigate to "View > User report" in the course gradebook
|
|
|
234 |
And I click on "Student 1" in the "user" search widget
|
|
|
235 |
|
|
|
236 |
# Check the values in the weights column.
|
|
|
237 |
Then the following should exist in the "user-grade" table:
|
|
|
238 |
| Grade item | Calculated weight | Grade | Contribution to course total |
|
|
|
239 |
| Test assignment one | 20.00 % | 60.00 | 12.00 % |
|
|
|
240 |
| Test assignment two | 20.00 % | 20.00 | 4.00 % |
|
|
|
241 |
| Test assignment three | 20.00 %( Extra credit ) | 40.00 | 8.00 % |
|
|
|
242 |
| Test assignment four | 33.33 % | 10.00 | 2.00 % |
|
|
|
243 |
| Test assignment five | 33.33 % | 70.00 | 14.00 % |
|
|
|
244 |
| Test assignment six | 33.33 % | 30.00 | 6.00 % |
|
|
|
245 |
| Sub category total | 60.00 % | 110.00 | - |
|
|
|
246 |
| Course total | - | 230.00 | - |
|