Commit 759b323e authored by David Monllaó's avatar David Monllaó
Browse files

MDL-43236 behat: Updating references to deprecated methods

parent c51c3b55
......@@ -5,7 +5,7 @@ Feature: Display extended course names
I need to display courses short names along with courses full names
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course fullname | C_shortname | 0 |
And I log in as "admin"
......
......@@ -5,19 +5,19 @@ Feature: An administrator can filter user accounts by role, cohort and other pro
I need to filter the users account list using different filter
Background:
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email | auth | confirmed |
| user1 | User | One | one@asd.com | manual | 0 |
| user2 | User | Two | two@asd.com | ldap | 1 |
| user3 | User | Three | three@asd.com | manual | 1 |
| user4 | User | Four | four@asd.com | ldap | 0 |
And the following "cohorts" exists:
And the following "cohorts" exist:
| name | idnumber |
| Cohort 1 | CH1 |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| user1 | C1 | student |
| user2 | C1 | student |
......
......@@ -6,10 +6,10 @@ Feature: Upload users
@javascript
Scenario: Upload users enrolling them on courses and groups
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Maths | math102 | 0 |
And the following "groups" exists:
And the following "groups" exist:
| name | course | idnumber |
| Section 1 | math102 | S1 |
| Section 3 | math102 | S3 |
......
......@@ -34,7 +34,7 @@ Feature: Page contents assertions
@javascript
Scenario: Locators inside specific DOM nodes using CSS selectors
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
......@@ -45,7 +45,7 @@ Feature: Page contents assertions
@javascript
Scenario: Locators inside specific DOM nodes using XPath
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
......
......@@ -5,7 +5,7 @@ Feature: Set up contextual data for tests
I need to fill the database with fixtures
Scenario: Add a bunch of users
Given the following "users" exists:
Given the following "users" exist:
| username | password | firstname | lastname |
| testuser | testuser | | |
| testuser2 | testuser2 | TestFirstname | TestLastname |
......@@ -16,12 +16,12 @@ Feature: Set up contextual data for tests
@javascript
Scenario: Add a bunch of courses and categories
Given the following "categories" exists:
Given the following "categories" exist:
| name | category | idnumber |
| Cat 1 | 0 | CAT1 |
| Cat 2 | CAT1 | CAT2 |
| Cat 3 | CAT1 | CAT3 |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | category |
| Course 1 | COURSE1 | CAT3 |
| Course 2 | COURSE2 | CAT3 |
......@@ -44,14 +44,14 @@ Feature: Set up contextual data for tests
@javascript
Scenario: Add a bunch of groups and groupings
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname |
| Course 1 | C1 |
And the following "groups" exists:
And the following "groups" exist:
| name | course | idnumber |
| Group 1 | C1 | G1 |
| Group 2 | C1 | G2 |
And the following "groupings" exists:
And the following "groupings" exist:
| name | course | idnumber |
| Grouping 1 | C1 | GG1 |
| Grouping 2 | C1 | GG2 |
......@@ -67,21 +67,21 @@ Feature: Set up contextual data for tests
@javascript
Scenario: Role overrides
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | 1 | teacher1@asd.com |
| student1 | Student | 1 | student1@asd.com |
And the following "categories" exists:
And the following "categories" exist:
| name | category | idnumber |
| Cat 1 | 0 | CAT1 |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname |
| Course 1 | C1 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| student1 | C1 | student |
| teacher1 | C1 | editingteacher |
And the following "permission overrides" exists:
And the following "permission overrides" exist:
| capability | permission | role | contextlevel | reference |
| mod/forum:editanypost | Allow | student | Course | C1 |
| mod/forum:replynews | Prevent | editingteacher | Course | C1 |
......@@ -97,13 +97,13 @@ Feature: Set up contextual data for tests
And I press "Cancel"
Scenario: Add course enrolments
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email |
| student1 | Student | 1 | student1@asd.com |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | format |
| Course 1 | C1 | topics |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| student1 | C1 | student |
When I log in as "student1"
......@@ -111,27 +111,27 @@ Feature: Set up contextual data for tests
Then I should see "Topic 1"
Scenario: Add role assigns
Given the following "roles" exists:
Given the following "roles" exist:
| name | shortname | description | archetype |
| Custom editing teacher | custom1 | My custom role 1 | editingteacher |
| Custom student | custom2 | | |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| user1 | User | 1 | user1@moodlemoodle.com |
| user2 | User | 2 | user2@moodlemoodle.com |
| user3 | User | 3 | user3@moodlemoodle.com |
| user4 | User | 4 | user4@moodlemoodle.com |
| user5 | User | 5 | user5@moodlemoodle.com |
And the following "categories" exists:
And the following "categories" exist:
| name | category | idnumber |
| Cat 1 | 0 | CAT1 |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | CAT1 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| user4 | C1 | custom1 |
And the following "role assigns" exists:
And the following "role assigns" exist:
| user | role | contextlevel | reference |
| user1 | manager | System | |
| user2 | editingteacher | Category | CAT1 |
......@@ -157,12 +157,11 @@ Feature: Set up contextual data for tests
And I follow "Course 1"
And I should see "You can not enrol yourself in this course."
Scenario: Add modules
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname |
| Course 1 | C1 |
And the following "activities" exists:
And the following "activities" exist:
| activity | name | intro | course | idnumber |
| assign | Test assignment name | Test assignment description | C1 | assign1 |
| assignment | Test assignment22 name | Test assignment22 description | C1 | assignment1 |
......@@ -218,29 +217,29 @@ Feature: Set up contextual data for tests
@javascript
Scenario: Add relations between users and groups
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email |
| student1 | Student | 1 | student1@asd.com |
| student2 | Student | 2 | student2@asd.com |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname |
| Course 1 | C1 |
And the following "groups" exists:
And the following "groups" exist:
| name | course | idnumber |
| Group 1 | C1 | G1 |
| Group 2 | C1 | G2 |
And the following "groupings" exists:
And the following "groupings" exist:
| name | course | idnumber |
| Grouping 1 | C1 | GG1 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| student1 | C1 | student |
| student2 | C1 | student |
And the following "group members" exists:
And the following "group members" exist:
| user | group |
| student1 | G1 |
| student2 | G2 |
And the following "grouping groups" exists:
And the following "grouping groups" exist:
| grouping | group |
| GG1 | G1 |
When I log in as "admin"
......
......@@ -5,13 +5,13 @@ Feature: Edit capabilities
I need to allow/deny the existing capabilities at different levels
Background:
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | 1 | teacher1@asd.com |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
......
......@@ -5,31 +5,31 @@ Feature: Verify that all form fields values can be get and set
I need to verify it all works in real moodle forms
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | email | firstname | lastname |
| student1 | s1@asd.com | Student | 1 |
| student2 | s2@asd.com | Student | 2 |
| student3 | s3@asd.com | Student | 3 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| student1 | C1 | student |
| student2 | C1 | student |
| student3 | C1 | student |
| admin | C1 | editingteacher |
And the following "groups" exists:
And the following "groups" exist:
| name | description | course | idnumber |
| Group 1 | G1 description | C1 | G1 |
| Group 2 | G1 description | C1 | G2 |
And the following "group members" exists:
And the following "group members" exist:
| user | group |
| student1 | G1 |
| student2 | G1 |
| student2 | G2 |
| student3 | G2 |
And the following "activities" exists:
And the following "activities" exist:
| activity | course | idnumber | name | intro | firstpagetitle | wikimode | visible |
| wiki | C1 | wiki1 | Test this one | Test this one | Test this one | collaborative | 0 |
And I log in as "admin"
......
......@@ -21,7 +21,7 @@ Feature: Forms manipulation
@javascript
Scenario: Expand all fieldsets and advanced elements
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
......
......@@ -6,7 +6,7 @@ Feature: Transform steps arguments
Background:
Given I am on homepage
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
......
......@@ -5,7 +5,7 @@ Feature: An admin can create courses using a CSV file
I need to be able to upload a CSV file and navigate through the import process
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| First course | C1 | 0 |
And I log in as "admin"
......
......@@ -5,7 +5,7 @@ Feature: An admin can update courses using a CSV file
I need to be able to upload a CSV file and navigate through the import process
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Some random name | C1 | 0 |
And I log in as "admin"
......
......@@ -14,7 +14,7 @@ Feature: Authentication
Then I should see "You are logged in as Admin User"
Scenario: Log in as an existing admin user filling the form
Given the following "users" exists:
Given the following "users" exist:
| username | password | firstname | lastname | email |
| testuser | testuser | Test | User | moodle@moodlemoodle.com |
And I am on homepage
......@@ -25,7 +25,7 @@ Feature: Authentication
Then I should see "You are logged in as"
Scenario: Log in as an unexisting user filling the form
Given the following "users" exists:
Given the following "users" exist:
| username | password | firstname | lastname | email |
| testuser | testuser | Test | User | moodle@moodlemoodle.com |
And I am on homepage
......
......@@ -5,11 +5,11 @@ Feature: Backup Moodle courses
I need to create backups of courses
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category | numsections |
| Course 1 | C1 | 0 | 10 |
| Course 2 | C2 | 0 | 2 |
And the following "activities" exists:
And the following "activities" exist:
| activity | course | idnumber | name | intro | section |
| assign | C2 | assign1 | Test assign | Assign description | 1 |
| data | C2 | data1 | Test data | Database description | 2 |
......@@ -37,8 +37,8 @@ Feature: Backup Moodle courses
And I should not see "Section 3"
And I press "Continue"
And I click on "Continue" "button" in the ".bcs-current-course" "css_element"
And "//div[contains(concat(' ', normalize-space(@class), ' '), ' fitem ')][contains(., 'Include calendar events')]/descendant::img" "xpath_element" should exists
And "Include course logs" "checkbox" should exists
And "//div[contains(concat(' ', normalize-space(@class), ' '), ' fitem ')][contains(., 'Include calendar events')]/descendant::img" "xpath_element" should exist
And "Include course logs" "checkbox" should exist
And I press "Next"
@javascript
......
......@@ -6,13 +6,13 @@ Feature: Duplicate activities
@javascript
Scenario: Duplicate an activity
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | 1 | teacher1@asd.com |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
......
......@@ -6,14 +6,14 @@ Feature: Import course's contents into another course
@javascript
Scenario: Import course's contents to another course
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
| Course 2 | C2 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | 1 | teacher1@asd.com |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
| teacher1 | C2 | editingteacher |
......
......@@ -5,12 +5,12 @@ Feature: Restore Moodle 2 course backups
I need to restore them inside other Moodle courses or in new courses
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category | format | numsections | coursedisplay |
| Course 1 | C1 | 0 | topics | 15 | 1 |
| Course 2 | C2 | 0 | topics | 5 | 0 |
| Course 3 | C3 | 0 | topics | 2 | 0 |
And the following "activities" exists:
And the following "activities" exist:
| activity | course | idnumber | name | intro | section |
| assign | C3 | assign1 | Test assign name | Assign description | 1 |
| data | C3 | data1 | Test database name | Database description | 2 |
......
......@@ -39,7 +39,7 @@ Feature: Award badges
@javascript
Scenario: Award site badge
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email |
| teacher | teacher | 1 | teacher1@asd.com |
| student | student | 1 | student1@asd.com |
......@@ -74,15 +74,15 @@ Feature: Award badges
@javascript
Scenario: Award course badge
Given the following "users" exists:
Given the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | 1 | teacher1@asd.com |
| student1 | Student | 1 | student1@asd.com |
| student2 | Student | 2 | student2@asd.com |
And the following "courses" exists:
And the following "courses" exist:
| fullname | shortname | category | groupmode |
| Course 1 | C1 | 0 | 1 |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
......@@ -119,14 +119,14 @@ Feature: Award badges
@javascript
Scenario: Award badge on activity completion
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | Frist | teacher1@asd.com |
| student1 | Student | First | student1@asd.com |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
......@@ -174,14 +174,14 @@ Feature: Award badges
@javascript
Scenario: Award badge on course completion
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | Frist | teacher1@asd.com |
| student1 | Student | First | student1@asd.com |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
......
......@@ -13,7 +13,7 @@ Feature: Block activity modules
And I click on "//a[@title=\"Show\"]" "xpath_element" in the "Feedback" "table_row"
Scenario: Add activities block on the frontpage
Given the following "activities" exists:
Given the following "activities" exist:
| activity | name | intro | course | idnumber |
| assign | Frontpage assignment name | Frontpage assignment description | Acceptance test site | assign0 |
| book | Frontpage book name | Frontpage book description | Acceptance test site | book0 |
......@@ -88,10 +88,10 @@ Feature: Block activity modules
And I should see "Frontpage url name"
Scenario: Add activities block in a course
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | format |
| Course 1 | C1 | topics |
And the following "activities" exists:
And the following "activities" exist:
| activity | name | intro | course | idnumber |
| assign | Test assignment name | Test assignment description | C1 | assign1 |
| book | Test book name | Test book description | C1 | book1 |
......
......@@ -5,14 +5,14 @@ Feature: Add a comment to the comments block
In need to add comments to courses
Background:
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | Frist | teacher1@asd.com |
| student1 | Student | First | student1@asd.com |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
......
......@@ -6,14 +6,14 @@ Feature: Delete comment block messages
@javascript
Scenario: Delete comments with Javascript enabled
Given the following "courses" exists:
Given the following "courses" exist:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
And the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | First | teacher1@asd.com |
| student1 | Student | First | student1@asd.com |
And the following "course enrolments" exists:
And the following "course enrolments" exist:
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
......
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