Skip to content

Commit

Permalink
MDL-56519 behat: Fixed lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Rajesh Taneja committed Jan 3, 2017
1 parent e989ff2 commit 57bee54
Show file tree
Hide file tree
Showing 95 changed files with 503 additions and 542 deletions.
1 change: 0 additions & 1 deletion admin/tool/behat/tests/behat/get_and_set_fields.feature
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ Feature: Verify that all form fields values can be get and set
And I navigate to "Edit settings" node in "Course 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

@javascript
Expand Down
1 change: 0 additions & 1 deletion admin/tool/behat/tests/behat/list_steps.feature
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,3 @@ Feature: List the system steps definitions
Given I set the field "Contains" to "homepage"
When I press "Filter"
Then I should see "Opens Moodle homepage."

1 change: 0 additions & 1 deletion admin/tool/langimport/tests/behat/manage_langpacks.feature
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ Feature: Manage language packs
As an administrator
I need to be able to add, update and remove language packs


Background:
Given remote langimport tests are enabled

Expand Down
4 changes: 2 additions & 2 deletions admin/tool/lp/tests/behat/framework_crud.feature
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ Feature: Manage competency frameworks
Then I should not see "Science Year-4"
And I should not see "sc-y-4"

Scenario: Edit a framework with competencies in user competency
Scenario: Edit a framework with competencies in user competency
Given the following lp "frameworks" exist:
| shortname | idnumber |
| Science Year-5 | sc-y-5 |
Expand Down Expand Up @@ -98,7 +98,7 @@ Scenario: Edit a framework with competencies in user competency
And I should see "Science Year-5 Edited"
And I should see "sc-y-5"

Scenario: Edit a framework with competencies in user competency plan
Scenario: Edit a framework with competencies in user competency plan
Given the following lp "frameworks" exist:
| shortname | idnumber |
| Science Year-6 | sc-y-6 |
Expand Down
2 changes: 1 addition & 1 deletion admin/tool/lp/tests/behat/plan_workflow.feature
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ Feature: Manage plan workflow
And I should not see "Active"
And I log out

Scenario: Manager reopen a complete learning plan
Scenario: Manager reopen a complete learning plan
Given the following lp "plans" exist:
| name | user | description | status | reviewer |
| Test-Plan3 | user1 | Description of plan 3 for user 1 | complete | manager1 |
Expand Down
1 change: 0 additions & 1 deletion admin/tool/lp/tests/behat/user_evidence_crud.feature
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,3 @@ Feature: Manage evidence of prior learning
Then I should see "List of evidence"
And I should see "Evidence-6"
And I should not see "Evidence-5"

1 change: 0 additions & 1 deletion badges/tests/behat/award_badge.feature
Original file line number Diff line number Diff line change
Expand Up @@ -357,4 +357,3 @@ Feature: Award badges
When I press "Revoke badge"
And I follow "Course Badge"
Then I should see "Recipients (0)"

Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Feature: The activity results block displays student scores
And I press "Save changes"
And I follow "Course 1"

Scenario: Configure the block on a non-graded activity to show 3 high scores
Scenario: Configure the block on a non-graded activity to show 3 high scores
Given I follow "Test page name"
And I add the "Activity results" block
When I configure the "Activity results" block
Expand All @@ -78,7 +78,7 @@ Scenario: Configure the block on a non-graded activity to show 3 high scores
And I should see "Student 3" in the "Activity results" "block"
And I should see "70.00" in the "Activity results" "block"

Scenario: Block should select current activity by default
Scenario: Block should select current activity by default
Given I follow "Test assignment 1"
When I add the "Activity results" block
And I configure the "Activity results" block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block doesn't displays student scores for unconfigured block
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block doesn't display student scores for unsupported activity
In order to be display student scores
As a user
I need to properly configure the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block displays student high scores
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores as scales
Feature: The activity results block displays students high scores in group as scales
In order to be display student scores as scales
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores as scales
Feature: The activity results block displays student in group high scores as scales
In order to be display student scores as scales
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block displays student in separate groups scores
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block displays student in visible groups scores
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block displays student low scores
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores as scales
Feature: The activity results block displays student low scores as scales
In order to be display student scores as scales
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores as scales
Feature: The activity results block displays students in groups low scores as scales
In order to be display student scores as scales
As a user
I need to see the activity results block
Expand Down Expand Up @@ -146,4 +146,3 @@ Feature: The activity results block displays student scores as scales
And I should see "User" in the "Activity results" "block"
And I should see "Good" in the "Activity results" "block"
And I should see "Average" in the "Activity results" "block"

Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block displays students in separate groups scores
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_activity_results
Feature: The activity results block displays student scores
Feature: The activity results block displays student in visible groups low scores
In order to be display student scores
As a user
I need to see the activity results block
Expand Down
8 changes: 4 additions & 4 deletions blocks/blog_menu/tests/behat/block_blog_menu_course.feature
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
@block @block_blog_menu
Feature: Enable Block blog menu in a course
In order to enable the blog menu in a course
As a teacher
I can add blog menu block to a course
Feature: Students can use block blog menu in a course
In order students to use the blog menu in a course
As a student
I view blog menu block in a course

Background:
Given the following "users" exist:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_calendar_upcoming
Feature: View a site event on the dashboard
Feature: View a upcoming site event on the dashboard
In order to view a site event
As a student
I can view the event in the upcoming events block
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ Feature: Enable Block Completion in a course using manual completion by others
And I follow "More details"
And I should see "Yes" in the "Marked complete by Teacher" "table_row"


Scenario: Add the block to a the course and require multiple roles to mark a student complete.
Given I log in as "teacher1"
And I follow "Course 1"
Expand Down
1 change: 0 additions & 1 deletion blocks/course_overview/tests/behat/quiz_overview.feature
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,3 @@ Feature: View the quiz being due
And I should not see "Quiz 1B Past deadline" in the "Course overview" "block"
And I should not see "Quiz 1D Future deadline" in the "Course overview" "block"
And I should not see "Quiz 2A Future deadline" in the "Course overview" "block"

Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ Feature: Random glossary entry block can be added to the frontpage
As a teacher
I can add the random glossary entry to the frontpage

Scenario: Admin can add random glossary block to the frontpage
Given the following "activities" exist:
| activity | name | intro | course | idnumber |
| glossary | Tips and Tricks | Frontpage glossary description | Acceptance test site | glossary0 |
And I log in as "admin"
And I am on site homepage
And I turn editing mode on
And I add the "Random glossary entry" block
And I configure the "block_glossary_random" block
And I set the following fields to these values:
| Title | Tip of the day |
| Take entries from this glossary | Tips and Tricks |
And I press "Save changes"
And I click on "Add a new entry" "link" in the "Tip of the day" "block"
And I set the following fields to these values:
| Concept | Never come late |
| Definition | Come in time for your classes |
And I press "Save changes"
When I log out
Then I should see "Never come late" in the "Tip of the day" "block"
And I should see "Come in time for your classes" in the "Tip of the day" "block"
Scenario: Admin can add random glossary block to the frontpage
Given the following "activities" exist:
| activity | name | intro | course | idnumber |
| glossary | Tips and Tricks | Frontpage glossary description | Acceptance test site | glossary0 |
And I log in as "admin"
And I am on site homepage
And I turn editing mode on
And I add the "Random glossary entry" block
And I configure the "block_glossary_random" block
And I set the following fields to these values:
| Title | Tip of the day |
| Take entries from this glossary | Tips and Tricks |
And I press "Save changes"
And I click on "Add a new entry" "link" in the "Tip of the day" "block"
And I set the following fields to these values:
| Concept | Never come late |
| Definition | Come in time for your classes |
And I press "Save changes"
When I log out
Then I should see "Never come late" in the "Tip of the day" "block"
And I should see "Come in time for your classes" in the "Tip of the day" "block"
2 changes: 1 addition & 1 deletion blocks/html/tests/behat/multiple_instances.feature
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_html
Feature: Adding and configuring HTML blocks
Feature: Adding and configuring multiple HTML blocks
In order to have one or multiple HTML blocks on a page
As admin
I need to be able to create, configure and change HTML blocks
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_online_users
Feature: The online users block allow you to see who is currently online
Feature: The online users block allow you to see who is currently online on dashboard
In order to use the online users block on the dashboard
As a user
I can view the online users block on my dashboard
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_online_users
Feature: The online users block allow you to see who is currently online
Feature: The online users block allow you to see who is currently online on frontpage
In order to enable the online users block on the front page page
As an admin
I can add the online users block to the front page page
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_private_files @_file_upload @javascript
Feature: The private files block allows users to store files privately in moodle
Feature: The private files block allows users to store files privately in moodle on activity page
In order to store a private file in moodle
As a teacher
I can upload the file to my private files area using the private files block in an activity
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_private_files @_file_upload @javascript
Feature: The private files block allows users to store files privately in moodle
Feature: The private files block allows users to store files privately in moodle on course page
In order to store a private file in moodle
As a teacher
I can upload the file to my private files area using the private files block in a course
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_private_files @_file_upload @javascript
Feature: The private files block allows users to store files privately in moodle
Feature: The private files block allows users to store files privately in moodle on dashboard
In order to store a private file in moodle
As a user
I can upload the file to my private files area using the private files block on the dashboard
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_private_files @_file_upload
Feature: The private files block allows users to store files privately in moodle
Feature: The private files block allows users to store files privately in moodle on front page.
In order to store a private file in moodle
As a teacher
I can upload the file to my private files area using the private files block from the front page
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_search_forums @mod_forum
Feature: The search forums block allows users to search for forum posts
Feature: The search forums block allows users to search for forum posts on course page
In order to search for a forum post
As a user
I can use the search forums block
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@block @block_search_forums @mod_forum
Feature: The search forums block allows users to search for forum posts
Feature: The search forums block allows users to search for forum posts on frontpage
In order to search for a forum post
As an administrator
I can add the search forums block
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ Feature: The section links block allows users to quickly navigate around a moodl
| id_coursedisplay | Show one section per page |
And I press "Save and display"


Scenario: Add the section links block to a course.
Given I add the "Section links" block
And I turn editing mode off
Expand Down
1 change: 0 additions & 1 deletion blog/tests/behat/delete.feature
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,3 @@ Feature: Delete a blog entry
And I press "Cancel"
And I should see "Blog post one"
And I should see "Blog post two"

1 change: 0 additions & 1 deletion calendar/tests/behat/calendar.feature
Original file line number Diff line number Diff line change
Expand Up @@ -111,4 +111,3 @@ Feature: Perform basic calendar functionality
| Description | Wait, this event isn't that great. |
And I press "Save changes"
And I should see "Mediocre event"

1 change: 0 additions & 1 deletion cohort/tests/behat/access_visible_cohorts.feature
Original file line number Diff line number Diff line change
Expand Up @@ -125,4 +125,3 @@ Feature: Access visible and hidden cohorts
And the "Select members from cohort" select box should not contain "Cohort in category 2"
And the "Select members from cohort" select box should not contain "Cohort empty in category 1"
And the "Select members from cohort" select box should not contain "System empty cohort"

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Feature: Change number of discussions displayed
As a teacher
I need to edit the course and change the number of sections displayed.

Background:
Background:
Given the following "users" exist:
| username | firstname | lastname | email |
| teacher1 | Teacher | 1 | teacher1@example.com |
Expand Down Expand Up @@ -96,28 +96,28 @@ Background:
And I wait to be redirected
And I follow "Course 1"

Scenario: When number of discussions is decreased fewer discussions appear
Scenario: When number of discussions is decreased fewer discussions appear
Given I navigate to "Edit settings" in current page administration
And I set the following fields to these values:
| numdiscussions | 5 |
| numdiscussions | 5 |
When I press "Save and display"
Then I should see "This is forum post one"
And I should see "This is forum post five"
And I should not see "This is forum post six"

Scenario: When number of discussions is decreased to less than 1 only 1 discussion should appear
Scenario: When number of discussions is decreased to less than 1 only 1 discussion should appear
Given I navigate to "Edit settings" in current page administration
And I set the following fields to these values:
| numdiscussions | -1 |
| numdiscussions | -1 |
When I press "Save and display"
Then I should see "This is forum post one"
And I should not see "This is forum post two"
And I should not see "This is forum post ten"

Scenario: When number of discussions is increased more discussions appear
Scenario: When number of discussions is increased more discussions appear
Given I navigate to "Edit settings" in current page administration
And I set the following fields to these values:
| numdiscussions | 9 |
| numdiscussions | 9 |
When I press "Save and display"
Then I should see "This is forum post one"
And I should see "This is forum post five"
Expand Down
Loading

0 comments on commit 57bee54

Please sign in to comment.