Ir a la última revisión | Autoría | Comparar con el anterior | Ultima modificación | Ver Log |
@core @core_grades @gradereport_user @javascriptFeature: We can use the user reportAs a userI browse to the User reportBackground:Given the following "courses" exist:| fullname | shortname | category | groupmode || Course 1 | C1 | 0 | 1 |Scenario: Verify we can view a user grade report with no users enrolled.When I am on the "Course 1" "grades > User report > View" page logged in as "admin"Then I should see "There are no students enrolled in this course."Scenario: Teacher sees his last viewed user report when navigating back to the gradebook user report.Given the following "users" exist:| username | firstname | lastname | email || teacher1 | Teacher | 1 | teacher1@example.com || teacher2 | Teacher | 2 | teacher2@example.com || student1 | Student | 1 | student1@example.com |And the following "course enrolments" exist:| user | course | role || teacher1 | C1 | editingteacher || teacher2 | C1 | editingteacher || student1 | C1 | student |And I am on the "Course 1" "grades > User report > View" page logged in as "teacher1"And I should see "Search for a user to view their report" in the "region-main" "region"And I click on "Student 1" in the "user" search widgetAnd I should see "Student 1" in the "region-main" "region"When I am on the "Course 1" "grades > User report > View" pageThen I should not see "Search for a user to view their report" in the "region-main" "region"And I should see "Student 1" in the "region-main" "region"And I am on the "Course 1" "grades > User report > View" page logged in as "teacher2"And I should see "Search for a user to view their report" in the "region-main" "region"Scenario: Teacher sees his last viewed user report if the user is a part of the the current group.Given the following "groups" exist:| name | course | idnumber | participation || Group 1 | C1 | G1 | 1 |And the following "users" exist:| username | firstname | lastname | email || teacher1 | Teacher | 1 | teacher1@example.com || student1 | Student | 1 | student1@example.com || student2 | Student | 2 | student2@example.com |And the following "course enrolments" exist:| user | course | role || teacher1 | C1 | editingteacher || student1 | C1 | student || student2 | C1 | student |And the following "group members" exist:| user | group || student2 | G1 |And I am on the "Course 1" "grades > User report > View" page logged in as "teacher1"And I click on "Student 2" in the "user" search widgetAnd I navigate to "View > Grader report" in the course gradebookAnd I click on "Group 1" in the "group" search widgetWhen I navigate to "View > User report" in the course gradebookThen I should see "Student 2" in the "region-main" "region"And I should not see "Search for a user to view their report" in the "region-main" "region"Scenario: Teacher does not see the last viewed user if the user is not a part of the the current group.Given the following "groups" exist:| name | course | idnumber | participation || Group 1 | C1 | G1 | 1 |And the following "users" exist:| username | firstname | lastname | email || teacher1 | Teacher | 1 | teacher1@example.com || student1 | Student | 1 | student1@example.com || student2 | Student | 2 | student2@example.com |And the following "course enrolments" exist:| user | course | role || teacher1 | C1 | editingteacher || student1 | C1 | student || student2 | C1 | student |And the following "group members" exist:| user | group || student2 | G1 |And I am on the "Course 1" "grades > User report > View" page logged in as "teacher1"And I click on "Student 1" in the "user" search widgetAnd I navigate to "View > Grader report" in the course gradebookAnd I click on "Group 1" in the "group" search widgetWhen I navigate to "View > User report" in the course gradebookThen I should see "Search for a user to view their report" in the "region-main" "region"And I should not see "Student 1" in the "region-main" "region"Scenario: Teacher does not see his last viewed user report if the user is no longer enrolled in the course.Given the following "users" exist:| username | firstname | lastname | email || teacher1 | Teacher | 1 | teacher1@example.com || student1 | Student | 1 | student1@example.com || student2 | Student | 2 | student2@example.com |And the following "course enrolments" exist:| user | course | role || teacher1 | C1 | editingteacher || student1 | C1 | student || student2 | C1 | student |And I am on the "Course 1" "grades > User report > View" page logged in as "teacher1"And I click on "Student 1" in the "user" search widgetAnd I should see "Student 1" in the "region-main" "region"And I navigate to course participantsAnd I click on "Unenrol" "icon" in the "Student 1" "table_row"And I click on "Unenrol" "button" in the "Unenrol" "dialogue"And I am on "Course 1" course homepageWhen I navigate to "View > User report" in the course gradebookThen I should see "Search for a user to view their report" in the "region-main" "region"And I should not see "Student 1" in the "region-main" "region"