Línea 1... |
Línea 1... |
1 |
@mod @mod_assign
|
1 |
@mod @mod_assign @assign_grade
|
2 |
Feature: Check that the assignment grade can be updated correctly
|
2 |
Feature: Check that the assignment grade can be updated correctly
|
3 |
In order to ensure that the grade is shown correctly in the grading table
|
3 |
In order to ensure that the grade is shown correctly in the grading table
|
4 |
As a teacher
|
4 |
As a teacher
|
5 |
I need to grade a student and ensure the grade is shown correctly
|
5 |
I need to grade a student and ensure the grade is shown correctly
|
Línea 26... |
Línea 26... |
26 |
| name | Test assignment name |
|
26 |
| name | Test assignment name |
|
27 |
| intro | Test assignment description |
|
27 |
| intro | Test assignment description |
|
28 |
| markingworkflow | 1 |
|
28 |
| markingworkflow | 1 |
|
29 |
| submissiondrafts | 0 |
|
29 |
| submissiondrafts | 0 |
|
30 |
And I am on the "Test assignment name" Activity page logged in as teacher1
|
30 |
And I am on the "Test assignment name" Activity page logged in as teacher1
|
31 |
Then I follow "View all submissions"
|
31 |
Then I change window size to "large"
|
32 |
And I click on "Grade" "link" in the "Student 1" "table_row"
|
32 |
And I go to "Student 1" "Test assignment name" activity advanced grading page
|
33 |
And I set the field "Grade out of 100" to "50"
|
33 |
And I set the field "Grade out of 100" to "50"
|
34 |
And I set the field "Notify student" to "0"
|
34 |
And I set the field "Notify student" to "0"
|
35 |
And I press "Save changes"
|
35 |
And I press "Save changes"
|
36 |
And I follow "View all submissions"
|
36 |
And I follow "View all submissions"
|
37 |
And "Student 1" row "Grade" column of "generaltable" table should contain "50.00"
|
37 |
And "Student 1" row "Grade" column of "generaltable" table should contain "50.00"
|
Línea 60... |
Línea 60... |
60 |
| markingworkflow | 1 |
|
60 |
| markingworkflow | 1 |
|
61 |
| submissiondrafts | 0 |
|
61 |
| submissiondrafts | 0 |
|
62 |
| teamsubmission | 1 |
|
62 |
| teamsubmission | 1 |
|
63 |
| groupmode | 0 |
|
63 |
| groupmode | 0 |
|
64 |
And I am on the "Test assignment name" Activity page logged in as teacher1
|
64 |
And I am on the "Test assignment name" Activity page logged in as teacher1
|
65 |
When I follow "View all submissions"
|
65 |
When I change window size to "large"
|
- |
|
66 |
And I go to "Student 1" "Test assignment name" activity advanced grading page
|
66 |
And I click on "Grade" "link" in the "Student 1" "table_row"
|
67 |
And I change window size to "medium"
|
67 |
And I set the field "Grade out of 100" to "50"
|
68 |
And I set the field "Grade out of 100" to "50"
|
68 |
And I set the field "Notify student" to "0"
|
69 |
And I set the field "Notify student" to "0"
|
69 |
And I press "Save changes"
|
70 |
And I press "Save changes"
|
70 |
And I follow "View all submissions"
|
71 |
And I follow "View all submissions"
|
71 |
Then "Student 1" row "Grade" column of "generaltable" table should contain "50.00"
|
72 |
Then "Student 1" row "Grade" column of "generaltable" table should contain "50.00"
|
- |
|
73 |
|
- |
|
74 |
@javascript
|
- |
|
75 |
Scenario: Update the grade for an assignment with penalty
|
- |
|
76 |
Given the following "courses" exist:
|
- |
|
77 |
| fullname | shortname | category | groupmode |
|
- |
|
78 |
| Course 1 | C1 | 0 | 1 |
|
- |
|
79 |
And the following "users" exist:
|
- |
|
80 |
| username | firstname | lastname | email |
|
- |
|
81 |
| teacher1 | Teacher | 1 | teacher1@example.com |
|
- |
|
82 |
| student1 | Student | 1 | student10@example.com |
|
- |
|
83 |
And the following "course enrolments" exist:
|
- |
|
84 |
| user | course | role |
|
- |
|
85 |
| teacher1 | C1 | editingteacher |
|
- |
|
86 |
| student1 | C1 | student |
|
- |
|
87 |
And the following "groups" exist:
|
- |
|
88 |
| name | course | idnumber |
|
- |
|
89 |
| Group 1 | C1 | G1 |
|
- |
|
90 |
And I enable grade penalties for assignment
|
- |
|
91 |
And the following "activity" exists:
|
- |
|
92 |
| activity | assign |
|
- |
|
93 |
| course | C1 |
|
- |
|
94 |
| name | Test assignment name |
|
- |
|
95 |
| intro | Test assignment description |
|
- |
|
96 |
| grade | 100 |
|
- |
|
97 |
| duedate | ##yesterday## |
|
- |
|
98 |
| gradepenalty | 1 |
|
- |
|
99 |
| assignsubmission_onlinetext_enabled | 1 |
|
- |
|
100 |
| submissiondrafts | 0 |
|
- |
|
101 |
# Add a submission.
|
- |
|
102 |
And the following "mod_assign > submissions" exist:
|
- |
|
103 |
| assign | user | onlinetext |
|
- |
|
104 |
| Test assignment name | student1 | I'm the student first submission |
|
- |
|
105 |
And I am on the "Test assignment name" Activity page logged in as teacher1
|
- |
|
106 |
And I change window size to "large"
|
- |
|
107 |
And I go to "Student 1" "Test assignment name" activity advanced grading page
|
- |
|
108 |
When I set the field "Grade out of 100" to "90"
|
- |
|
109 |
And I set the field "Notify student" to "0"
|
- |
|
110 |
And I press "Save changes"
|
- |
|
111 |
Then the "data-bs-original-title" attribute of ".penalty-indicator-icon" "css_element" should contain "Late penalty applied -10.00 marks"
|
- |
|
112 |
And I follow "View all submissions"
|
- |
|
113 |
And "Student 1" row "Grade" column of "submissions" table should contain "90.00"
|
- |
|
114 |
And "Student 1" row "Final grade" column of "submissions" table should contain "80.00"
|
- |
|
115 |
And the "data-bs-original-title" attribute of ".penalty-indicator-icon" "css_element" should contain "Late penalty applied -10.00 marks"
|
- |
|
116 |
# Override the grade.
|
- |
|
117 |
And I am on the "Course 1" "grades > Grader report > View" page
|
- |
|
118 |
And the following should exist in the "user-grades" table:
|
- |
|
119 |
| -1- | -2- | -3- | -4- |
|
- |
|
120 |
| Student 1 | student10@example.com | 80 | 80 |
|
- |
|
121 |
And the "data-bs-original-title" attribute of ".penalty-indicator-icon" "css_element" should contain "Late penalty applied -10.00 marks"
|
- |
|
122 |
And I turn editing mode on
|
- |
|
123 |
And I set the following fields to these values:
|
- |
|
124 |
| Student 1 Test assignment name grade | 100 |
|
- |
|
125 |
And I click on "Save changes" "button"
|
- |
|
126 |
And I turn editing mode off
|
- |
|
127 |
And the following should exist in the "user-grades" table:
|
- |
|
128 |
| -1- | -2- | -3- | -4- |
|
- |
|
129 |
| Student 1 | student10@example.com | 100 | 100 |
|
- |
|
130 |
And ".penalty-indicator-icon" "css_element" should not exist
|
- |
|
131 |
And I go to "Student 1" "Test assignment name" activity advanced grading page
|
- |
|
132 |
And ".penalty-indicator-icon" "css_element" should not exist
|
- |
|
133 |
And I follow "View all submissions"
|
- |
|
134 |
And ".penalty-indicator-icon" "css_element" should not exist
|