Commit 7d821080 authored by Mihail Geshoski's avatar Mihail Geshoski
Browse files

MDL-72093 navigation: Update behat tests

parent ecf8e77f
......@@ -223,7 +223,7 @@ Feature: Set up contextual data for tests
And I should see "Test assignment description"
And I am on "Course 1" course homepage
And I follow "Test assignment name with scale"
And I follow "Edit settings"
And I follow "Settings"
And the field "Type" matches value "Scale"
@javascript
......
......@@ -72,7 +72,7 @@ Feature: Edit capabilities
@javascript
Scenario: Edit permissions escapes role names correctly
When I am on the "C1" "Course" page logged in as "admin"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Your word for 'Teacher' | Teacher >= editing |
| Your word for 'Non-editing teacher' | Teacher < "editing" |
......
......@@ -56,13 +56,13 @@ Feature: Verify that all form fields values can be get and set
And I press "Save"
Then I should see "Student page contents" in the "region-main" "region"
# Select (multi-select) - Checking "I set the field".
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
# Checkbox - Checking "I set the field" and "The field matches value" ticked.
And I set the field "Force format" to "1"
And I press "Save and return to course"
And I am on the "Test this one" "wiki activity" page
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the field "Force format" matches value "1"
And the field "Force format" does not match value ""
......@@ -70,7 +70,7 @@ Feature: Verify that all form fields values can be get and set
And I set the field "Force format" to ""
And I press "Save and return to course"
And I am on the "Test this one" "wiki activity" page
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the field "Force format" matches value ""
And the field "Force format" does not match value "1"
......@@ -79,7 +79,7 @@ Feature: Verify that all form fields values can be get and set
| Force format | 1 |
And I press "Save and return to course"
And I am on the "Test this one" "wiki activity" page
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the following fields match these values:
| Force format | 1 |
......@@ -90,7 +90,7 @@ Feature: Verify that all form fields values can be get and set
| Force format | |
And I press "Save and return to course"
And I am on the "Test this one" "wiki activity" page
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the following fields match these values:
| Force format | |
......@@ -102,7 +102,7 @@ Feature: Verify that all form fields values can be get and set
# Select (simple) - Checking "I set the field".
And I set the field "Group mode" to "Separate groups"
And I press "Save and display"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And the following fields match these values:
| Default format | NWiki |
| Group mode | Separate groups |
......@@ -135,12 +135,12 @@ Feature: Verify that all form fields values can be get and set
And the field "two" matches value ""
# Check if field xpath set/match works.
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the field with xpath "//input[@id='id_idnumber']" to "Course id number"
And the field with xpath "//input[@name='idnumber']" matches value "Course id number"
And the field with xpath "//input[@name='idnumber']" does not match value ""
And I press "Save and display"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And the field "Course ID number" matches value "Course id number"
Scenario: with JS disabled all form fields getters and setters works as expected
......@@ -171,7 +171,7 @@ Feature: Verify that all form fields values can be get and set
And the "available[day]" "field" should be enabled
And the field "deadline[enabled]" matches value "1"
And I press "Save and display"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And the field "available[enabled]" matches value "1"
And the "available[day]" "field" should be enabled
And the field "deadline[enabled]" matches value "1"
......
......@@ -12,7 +12,7 @@ Feature: Behat steps for interacting with form work
When I log in as "admin"
And I am on "Course 1" course homepage
# Just get to any form.
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the field "Course full name" in the "General" "fieldset" to "Frog"
And I set the following fields in the "Appearance" "fieldset" to these values:
| Show activity reports | Yes |
......
......@@ -20,7 +20,7 @@ Feature: Confirm that conditions on completion no longer cause a bug
# Set up course.
Given I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And I set the field "Enable completion tracking" to "Yes"
And I press "Save and display"
......
......@@ -41,7 +41,7 @@ Feature: edit_availability
| intro | pageintro |
And I am on "Course 1" course homepage with editing mode on
And I follow "Page1"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
Then "Restrict access" "fieldset" should not exist
Given I am on "Course 1" course homepage
......@@ -60,7 +60,7 @@ Feature: edit_availability
| intro | pageintro |
And I am on "Course 1" course homepage
And I follow "Page2"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
Then "Restrict access" "fieldset" should exist
Given I am on "Course 1" course homepage
......@@ -220,7 +220,7 @@ Feature: edit_availability
# Check the button still works after saving and editing.
And I press "Save and display"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the "Add group/grouping access restriction" "button" should be disabled
And I should see "Grouping" in the "Restrict access" "fieldset"
......
......@@ -42,7 +42,7 @@ Feature: Restore Moodle 2 course backups
And I should see "Test forum name"
And I should see "Topic 15"
And I should not see "Topic 16"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the field "id_format" matches value "Topics format"
And I press "Cancel"
......@@ -82,7 +82,7 @@ Feature: Restore Moodle 2 course backups
When I restore "test_backup.mbz" backup into a new course using this options:
Then I should see "Topic 1"
And I should see "Test forum name"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the field "id_format" matches value "Topics format"
And I set the following fields to these values:
......@@ -94,14 +94,14 @@ Feature: Restore Moodle 2 course backups
And I press "Save and display"
And I should see "1 January - 7 January"
And I should see "Test forum name"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the field "id_format" matches value "Weekly format"
And I set the following fields to these values:
| id_format | Social format |
And I press "Save and display"
And I should see "An open forum for chatting about anything you want to"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And the field "id_format" matches value "Social format"
And I press "Cancel"
......@@ -118,7 +118,7 @@ Feature: Restore Moodle 2 course backups
| Confirmation | Filename | test_backup.mbz |
And I restore "test_backup.mbz" backup into "Course 2" course using this options:
| Schema | Overwrite course configuration | Yes |
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
Then the field "id_format" matches value "Topics format"
And the field "Course layout" matches value "Show one section per page"
......@@ -144,7 +144,7 @@ Feature: Restore Moodle 2 course backups
| Confirmation | Filename | test_backup.mbz |
And I restore "test_backup.mbz" backup into "Course 2" course using this options:
| Schema | Overwrite course configuration | No |
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
Then the field "id_format" matches value "Topics format"
And the field "Course short name" matches value "C2"
......@@ -173,7 +173,7 @@ Feature: Restore Moodle 2 course backups
And I navigate to "Restore" in current page administration
And I merge "test_backup.mbz" backup into the current course after deleting it's contents using this options:
| Schema | Overwrite course configuration | Yes |
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
Then the field "id_format" matches value "Topics format"
And the field "Course layout" matches value "Show one section per page"
......@@ -202,7 +202,7 @@ Feature: Restore Moodle 2 course backups
And I navigate to "Restore" in current page administration
And I merge "test_backup.mbz" backup into the current course after deleting it's contents using this options:
| Schema | Overwrite course configuration | No |
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
Then the field "id_format" matches value "Topics format"
And the field "Course short name" matches value "C2"
......@@ -231,7 +231,7 @@ Feature: Restore Moodle 2 course backups
And I navigate to "Restore" in current page administration
And I merge "test_backup.mbz" backup into the current course after deleting it's contents using this options:
| Schema | Overwrite course configuration | No |
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
Then the field "id_format" matches value "Topics format"
And the field "Course short name" matches value "C4"
......
......@@ -214,7 +214,7 @@ Feature: Award badges
| student1 | C1 | student |
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Enable completion tracking | Yes |
And I press "Save and display"
......@@ -261,7 +261,7 @@ Feature: Award badges
| student1 | C1 | student |
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Enable completion tracking | Yes |
And I press "Save and display"
......
......@@ -32,7 +32,7 @@ Feature: Award badges with separate groups
| teacher2 | CA |
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I expand all fieldsets
And I set the field "Group mode" to "Separate groups"
And I press "Save and display"
......
......@@ -31,7 +31,7 @@ Feature: The activity results block doesn't display student scores for unsupport
| id_config_nameformat | Display full names |
And I press "Save changes"
When I follow "Test assignment"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| id_grade_modgrade_type | None |
And I press "Save and return to course"
......
......@@ -41,7 +41,7 @@ Feature: The activity results block displays students high scores in group as sc
And I press "Save changes"
And I am on "Course 1" course homepage
And I follow "Test assignment"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
......
......@@ -54,7 +54,7 @@ Feature: The activity results block displays student in group high scores as sca
And I press "Save changes"
And I am on "Course 1" course homepage
And I follow "Test assignment"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| assignsubmission_file_enabled | 0 |
| id_grade_modgrade_type | Scale |
......
......@@ -47,7 +47,7 @@ Feature: The activity results block displays student in visible groups scores
And I log in as "teacher1"
And I am on "Course 1" course homepage with editing mode on
And I follow "Test assignment"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Group mode | Visible groups |
And I press "Save and return to course"
......
......@@ -42,7 +42,7 @@ Feature: The activity results block displays student low scores as scales
And I press "Save changes"
And I am on "Course 1" course homepage with editing mode on
And I follow "Test assignment"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
......
......@@ -59,7 +59,7 @@ Feature: The activity results block displays students in groups low scores as sc
And I press "Save changes"
And I am on "Course 1" course homepage
And I follow "Test assignment"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
......
......@@ -123,7 +123,7 @@ Feature: Enable the calendar block in a course and test it's functionality
| student2 | G2 |
When I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| id_groupmode | Separate groups |
| id_groupmodeforce | Yes |
......@@ -159,7 +159,7 @@ Feature: Enable the calendar block in a course and test it's functionality
| student2 | G2 |
When I log in as "teacher1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| id_groupmode | Separate groups |
| id_groupmodeforce | Yes |
......
......@@ -20,7 +20,7 @@ Feature: Enable Block Completion in a course
Scenario: Add the block to a the course where completion is disabled
Given I log in as "teacher1"
And I am on "Course 1" course homepage with editing mode on
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Enable completion tracking | No |
And I press "Save and display"
......@@ -40,7 +40,7 @@ Feature: Enable Block Completion in a course
And I log in as "teacher1"
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Completion tracking | Show activity as complete when conditions are met |
| Require view | 1 |
......
......@@ -24,7 +24,7 @@ Feature: Enable Block Completion in a course using activity completion
Given I log in as "teacher1"
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Completion tracking | Show activity as complete when conditions are met |
| Require view | 1 |
......@@ -45,7 +45,7 @@ Feature: Enable Block Completion in a course using activity completion
Given I log in as "teacher1"
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Completion tracking | Show activity as complete when conditions are met |
| Require view | 1 |
......
......@@ -72,7 +72,7 @@ Feature: Random glossary entry block linking to global glossary
And I log in as "admin"
And I am on "Course 2" course homepage
And I follow "Tips and Tricks"
And I follow "Edit settings"
And I follow "Settings"
And I set the field "globalglossary" to "0"
And I press "Save and return to course"
And I am on "Course 1" course homepage
......
......@@ -28,7 +28,7 @@ Feature: Course overview block show users their progress on courses
Scenario: User complete activity and verify his progress
Given I am on the "Test choice 1" "choice activity" page logged in as teacher1
And I navigate to "Edit settings" in current page administration
And I navigate to "Settings" in current page administration
And I set the following fields to these values:
| Completion tracking | Show activity as complete when conditions are met |
| id_completionview | 1 |
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment