MDL-74276 report: Update behat tests to account for new page.

This commit is contained in:
Peter Dias
2022-04-01 12:44:04 +08:00
parent 3eb80e7386
commit 2c27a33213
28 changed files with 51 additions and 51 deletions
@@ -23,7 +23,7 @@ Feature: In a course administration page, navigate through report page, test for
And I click on "Enable" "link"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Event monitoring rules"
And the field "Report" matches value "Event monitoring rules"
+6 -6
View File
@@ -19,7 +19,7 @@ Feature: tool_monitor_rule
And I click on "Enable" "link"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
And I press "Add a new rule"
And I set the following fields to these values:
| name | New rule course level |
@@ -47,7 +47,7 @@ Feature: tool_monitor_rule
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
When I press "Add a new rule"
And I set the following fields to these values:
| name | New rule |
@@ -68,7 +68,7 @@ Feature: tool_monitor_rule
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
When I click on "Delete rule" "link"
Then I should see "Are you sure you want to delete the rule \"New rule course level\"?"
And I press "Continue"
@@ -79,7 +79,7 @@ Feature: tool_monitor_rule
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
When I click on "Edit rule" "link"
And I set the following fields to these values:
| name | New rule quiz |
@@ -99,7 +99,7 @@ Feature: tool_monitor_rule
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
When I click on "Duplicate rule" "link" in the "New rule course level" "table_row"
Then I should see "Rule successfully duplicated"
And "#toolmonitorrules_r1" "css_element" should appear before "#toolmonitorrules_r2" "css_element"
@@ -159,7 +159,7 @@ Feature: tool_monitor_rule
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
When I click on "Duplicate rule" "link" in the "New rule site level" "table_row"
Then I should see "Rule successfully duplicated"
And "#toolmonitorrules_r2" "css_element" should appear after "#toolmonitorrules_r1" "css_element"
@@ -24,7 +24,7 @@ Feature: tool_monitor_subscriptions
And I click on "Enable" "link"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Event monitoring rules" from the "Report type" singleselect
And I click on "Event monitoring rules" "link"
And I press "Add a new rule"
And I set the following fields to these values:
| name | New rule course level |
@@ -37,7 +37,7 @@ Feature: Enable Block Completion in a course using manual completion by others
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course completion" from the "Report type" singleselect
And I click on "Course completion" "link" in the "region-main" "region"
And I follow "Click to mark user complete"
# Running completion task just after clicking sometimes fail, as record
# should be created before the task runs.
@@ -73,7 +73,7 @@ Feature: Enable Block Completion in a course using manual completion by others
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course completion" from the "Report type" singleselect
And I click on "Course completion" "link" in the "region-main" "region"
And I follow "Click to mark user complete"
And I log out
And I log in as "student1"
@@ -88,7 +88,7 @@ Feature: Enable Block Completion in a course using manual completion by others
And I log in as "teacher2"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course completion" from the "Report type" singleselect
And I click on "Course completion" "link" in the "region-main" "region"
And I follow "Click to mark user complete"
# Running completion task just after clicking sometimes fail, as record
# should be created before the task runs.
+1 -1
View File
@@ -88,7 +88,7 @@ class behat_completion extends behat_base {
$this->execute("behat_navigation::i_navigate_to_in_current_page_administration",
$reportsnode);
$this->execute("behat_forms::i_select_from_the_singleselect", [$completionnode, "Report type"]);
$this->execute("behat_general::i_click_on_in_the", [$completionnode, "link", "region-main", "region"]);
}
/**
+2 -2
View File
@@ -251,7 +251,7 @@ Feature: Initials bar
And I log out
And I am on the "C1" "Course" page logged in as "teacher"
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And ".initialbarall.page-item.active" "css_element" should exist in the ".initialbar.firstinitial" "css_element"
And ".initialbarall.page-item.active" "css_element" should exist in the ".initialbar.lastinitial" "css_element"
And ".page-item.active.B" "css_element" should not exist in the ".initialbar.firstinitial" "css_element"
@@ -277,7 +277,7 @@ Feature: Initials bar
And I should not see "Cstudent Cstudent"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And ".initialbarall.page-item.active" "css_element" should not exist in the ".initialbar.firstinitial" "css_element"
And ".initialbarall.page-item.active" "css_element" should not exist in the ".initialbar.lastinitial" "css_element"
And ".page-item.active.B" "css_element" should exist in the ".initialbar.firstinitial" "css_element"
@@ -46,7 +46,7 @@ Feature: Automatic completion in the choice activity
Scenario: Overriding automatic choice completion for a user
Given I am on the "Course 1" course page logged in as teacher1
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And I click on "Student 1, What to drink?: Not completed" "link"
And I press "Save changes"
And I log out
@@ -54,7 +54,7 @@ Feature: Manual completion in the choice activity
Scenario: Overriding a manual choice completion for a user to done
Given I am on the "Course 1" course page logged in as teacher1
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And I click on "Student 1, What to drink?: Not completed" "link"
And I press "Save changes"
And I log out
@@ -71,7 +71,7 @@ Feature: Manual completion in the choice activity
And I log out
And I am on the "Course 1" course page logged in as teacher1
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And I click on "Student 1, What to drink?: Completed" "link"
And I press "Save changes"
And I log out
@@ -60,7 +60,7 @@ Feature: Set a quiz to be marked complete when the student uses all attempts all
And "Test quiz name" should have the "Receive a pass grade or complete all available attempts" completion condition
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "<expectedactivitycompletion>" "icon" should exist in the "Student 1" "table_row"
Examples:
@@ -58,5 +58,5 @@ Feature: Set a quiz to be marked complete when the student completes a minimum a
And "Test quiz name" should have the "Make attempts: 2" completion condition
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "Completed" "icon" should exist in the "Student 1" "table_row"
@@ -52,5 +52,5 @@ Feature: Set a quiz to be marked complete when the student passes
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "Completed" "icon" should exist in the "Student 1" "table_row"
@@ -76,7 +76,7 @@ Feature: View activity completion in the quiz activity
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "<expectedactivitycompletion>" "icon" should exist in the "Student 1" "table_row"
Examples:
@@ -49,7 +49,7 @@ Feature: See the competencies for an activity
@javascript
Scenario: Go to the competency breakdown report
When I navigate to "Reports" in current page administration
And I select "Competency breakdown" from the "Report type" singleselect
And I click on "Competency breakdown" "link"
And I set the field "Filter competencies by resource or activity" to "PageName1"
Then I should see "Test-Comp1"
And I should not see "Test-Comp2"
@@ -21,7 +21,7 @@ Feature: In a course administration page, navigate through report page, test for
Given I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Competency breakdown" from the "Report type" singleselect
And I click on "Competency breakdown" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Competency breakdown"
And the field "Report" matches value "Competency breakdown"
@@ -34,5 +34,5 @@ Feature: See the completion for items in a course
And I press "Save changes"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Course completion" from the "Report type" singleselect
And I click on "Course completion" "link" in the "region-main" "region"
Then I should see "Ann, Jill, Grainne, Beauchamp"
@@ -27,7 +27,7 @@ Feature: In a course administration page, navigate through report page, test for
And I press "Save changes"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Course completion" from the "Report type" singleselect
And I click on "Course completion" "link" in the "region-main" "region"
Then "Report" "field" should exist
And the "Report" select box should contain "Course completion"
And the field "Report" matches value "Course completion"
@@ -21,7 +21,7 @@ Feature: In a course administration page, navigate through report page, test for
Given I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Logs" from the "Report type" singleselect
And I click on "Logs" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Logs"
And the field "Report" matches value "Logs"
+1 -1
View File
@@ -69,7 +69,7 @@ Feature: User can view activity log.
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Logs" from the "Report type" singleselect
And I click on "Logs" "link"
And I set the field with xpath "//select[@name='user']" to "Ann, Jill, Grainne, Beauchamp"
When I click on "Get these logs" "button"
Then I should see "Ann, Jill, Grainne, Beauchamp"
@@ -21,7 +21,7 @@ Feature: In a course administration page, navigate through report page, test for
Given I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Live logs" from the "Report type" singleselect
And I click on "Live logs" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Live logs"
And the field "Report" matches value "Live logs"
@@ -21,7 +21,7 @@ Feature: In a course administration page, navigate through report page, test for
Given I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Activity report"
And the field "Report" matches value "Activity report"
+2 -2
View File
@@ -46,7 +46,7 @@ Feature: Filter an outline report
And I log in as "admin"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
And I should see "2 views by 2 users" in the "Book name" "table_row"
And I should see "1 views by 1 users" in the "Forum name" "table_row"
When I set the following fields to these values:
@@ -79,7 +79,7 @@ Feature: Filter an outline report
And I log in as "admin"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
And I should see "2 views by 2 users" in the "Book name" "table_row"
And I should see "1 views by 1 users" in the "Forum name" "table_row"
When I set the following fields to these values:
+7 -7
View File
@@ -45,7 +45,7 @@ Feature: View an outline report
And I log in as "teacher1"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "2 views by 2 users" in the "Book name" "table_row"
And I should see "1 views by 1 users" in the "Forum name" "table_row"
@@ -67,7 +67,7 @@ Feature: View an outline report
And I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "2 views by 2 users" in the "Book name" "table_row"
And I should see "1 views by 1 users" in the "Forum name" "table_row"
@@ -91,7 +91,7 @@ Feature: View an outline report
And I log in as "teacher1"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "2 views by 2 users" in the "Book name" "table_row"
And I should see "1 views by 1 users" in the "Forum name" "table_row"
@@ -101,7 +101,7 @@ Feature: View an outline report
And I click on "Disable" "link" in the "Standard log" "table_row"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "No log reader enabled"
Scenario: Multiple views from a single user are identified as not distinct
@@ -118,7 +118,7 @@ Feature: View an outline report
When I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "3 views by 1 users" in the "Forum name" "table_row"
And I should see "-" in the "Book name" "table_row"
@@ -145,7 +145,7 @@ Feature: View an outline report
When I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "6 views by 2 users" in the "Forum name" "table_row"
And I should see "-" in the "Book name" "table_row"
@@ -154,6 +154,6 @@ Feature: View an outline report
When I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity report" from the "Report type" singleselect
And I click on "Activity report" "link"
Then I should see "-" in the "Forum name" "table_row"
And I should see "-" in the "Book name" "table_row"
@@ -21,7 +21,7 @@ Feature: In a course administration page, navigate through report page, test for
Given I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Course participation"
And the field "Report" matches value "Course participation"
@@ -43,7 +43,7 @@ Feature: In a participation report, admin can filter student actions
When I am on the "Course 1" course page logged in as admin
When I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
And I set the field "instanceid" to "Test book name"
And I set the field "roleid" to "Student"
And I press "Go"
@@ -73,7 +73,7 @@ Feature: In a participation report, admin can filter student actions
And I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
And I set the field "instanceid" to "Test book name"
And I set the field "roleid" to "Student"
And I press "Go"
@@ -87,7 +87,7 @@ Feature: In a participation report, admin can filter student actions
And I log in as "admin"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
And I set the field "instanceid" to "Test book name"
And I set the field "roleid" to "Student"
And I press "Go"
@@ -34,7 +34,7 @@ Feature: Use the particiaption report to message groups of students
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
And I set the field "instanceid" to "Test book name"
And I set the field "roleid" to "Student"
And I press "Go"
@@ -49,7 +49,7 @@ Feature: Use the particiaption report to message groups of students
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
And I set the field "instanceid" to "Test book name"
And I set the field "roleid" to "Student"
And I press "Go"
@@ -69,7 +69,7 @@ Feature: Use the particiaption report to message groups of students
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Course participation" from the "Report type" singleselect
And I click on "Course participation" "link"
When I set the field "instanceid" to "Test book name"
And I set the field "roleid" to "Student"
And I press "Go"
@@ -42,7 +42,7 @@ Feature: Teacher can view and override users' activity completion data via the p
# Teacher overrides the activity completion statuses to incomplete.
When I am on the "Course 1" course page logged in as teacher1
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "Ann, Jill, Grainne, Beauchamp, my assignment: Completed" "icon" should exist in the "Ann, Jill, Grainne, Beauchamp" "table_row"
And "Ann, Jill, Grainne, Beauchamp, my assignment 2: Completed" "icon" should exist in the "Ann, Jill, Grainne, Beauchamp" "table_row"
And I click on "my assignment" "link" in the "Ann, Jill, Grainne, Beauchamp" "table_row"
@@ -68,7 +68,7 @@ Feature: Teacher can view and override users' activity completion data via the p
# And the activity completion report should show the same.
And I am on the "Course 1" Course page logged in as teacher1
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "Ann, Jill, Grainne, Beauchamp, my assignment: Completed" "icon" should exist in the "Ann, Jill, Grainne, Beauchamp" "table_row"
And "Ann, Jill, Grainne, Beauchamp, my assignment 2: Completed" "icon" should exist in the "Ann, Jill, Grainne, Beauchamp" "table_row"
@@ -80,7 +80,7 @@ Feature: Teacher can view and override users' activity completion data via the p
# When the teacher overrides the activity completion statuses to complete.
When I am on the "Course 1" Course page logged in as teacher1
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
And "Ann, Jill, Grainne, Beauchamp, my assignment: Not completed" "icon" should exist in the "Ann, Jill, Grainne, Beauchamp" "table_row"
And "Ann, Jill, Grainne, Beauchamp, my assignment 3: Not completed" "icon" should exist in the "Ann, Jill, Grainne, Beauchamp" "table_row"
And I click on "my assignment" "link" in the "Ann, Jill, Grainne, Beauchamp" "table_row"
@@ -37,7 +37,7 @@ Feature: Teacher can view and filter activity completion data by group and activ
When I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
Then "My quiz B" "link" should appear before "My quiz A" "link" in the "completion-progress" "table"
And I should see "My assignment" in the "completion-progress" "table"
And I should see "My page" in the "completion-progress" "table"
@@ -27,7 +27,7 @@ Feature: In a course administration page, navigate through report page, test for
Given I log in as "admin"
And I am on "Course 1" course homepage
When I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
Then "Report" "field" should exist
And the "Report" select box should contain "Activity completion"
And the field "Report" matches value "Activity completion"
@@ -46,6 +46,6 @@ Feature: In a course administration page, navigate through report page, test for
| showuseridentity | email,profile_field_frog |
When I am on the "C1" "Course" page logged in as "admin"
And I navigate to "Reports" in current page administration
And I select "Activity completion" from the "Report type" singleselect
And I click on "Activity completion" "link"
Then I should see "Favourite frog"
Then I should see "Kermit" in the "Student Two" "table_row"