2 Feature: Teachers see correct answers when overriding marks
4 In order to correct errors
5 I must be able to override the grades that Moodle gives.
8 Given the following "users" exist:
9 | username | firstname | lastname | email |
10 | teacher1 | Teacher | 1 | teacher1@example.com |
11 | student1 | Student | 1 | student0@example.com |
12 And the following "courses" exist:
13 | fullname | shortname | category |
15 And the following "course enrolments" exist:
16 | user | course | role |
17 | teacher1 | C1 | editingteacher |
18 | student1 | C1 | student |
19 And the following "question categories" exist:
20 | contextlevel | reference | name |
21 | Course | C1 | Test questions |
22 And the following "questions" exist:
23 | questioncategory | qtype | name | questiontext | generalfeedback |
24 | Test questions | shortanswer | Kermit | What kind of animal is Kermit? | |
25 And the following "activities" exist:
26 | activity | name | course | idnumber |
27 | quiz | Quiz 1 | C1 | quiz1 |
28 And quiz "Quiz 1" contains the following questions:
31 And I am on the "Quiz 1" "mod_quiz > View" page logged in as "student1"
32 And I press "Attempt quiz"
33 And I set the field "Answer" to "lion"
34 And I follow "Finish attempt ..."
35 And I press "Submit all and finish"
36 And I click on "Submit all and finish" "button" in the "Submit all your answers and finish?" "dialogue"
39 @javascript @_switch_window @_bug_phantomjs
40 Scenario: Override marking of a short answer question attempt.
41 When I am on the "Quiz 1 > student1 > Attempt 1" "mod_quiz > Attempt review" page logged in as "teacher1"
42 And I follow "Make comment or override mark"
43 And I switch to "commentquestion" window
45 Then I should see "The correct answer is: frog"