Skip to content

Commit

Permalink
MDL-72456 mod_assign: fix behats
Browse files Browse the repository at this point in the history
  • Loading branch information
ferranrecio committed Nov 25, 2021
1 parent bcb35d9 commit 26d0e51
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 11 deletions.
5 changes: 3 additions & 2 deletions admin/tool/policy/tests/behat/consent.feature
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,7 @@ Feature: User must accept policy managed by this plugin when logging in and sign
| This privacy policy | 1 | | full text3 | short text3 | active | loggedin |
| This guests policy | 0 | | full text4 | short text4 | active | guest |
And I am on site homepage
And I change window size to "large"
And I follow "Log in"
When I press "Log in as a guest"
Then I should see "If you continue browsing this website, you agree to our policies"
Expand All @@ -472,11 +473,11 @@ Feature: User must accept policy managed by this plugin when logging in and sign
# Confirm when clicking on the policy links, the policy content is displayed.
When I click on "This site policy" "link"
Then I should see "full text2"
And I click on "Close" "button"
And I click on "Close" "button" in the "This site policy" "dialogue"
And I should not see "full text2"
When I click on "This guests policy" "link"
Then I should see "full text4"
And I click on "Close" "button"
And I click on "Close" "button" in the "This guests policy" "dialogue"
And I should not see "full text4"
# Confirm when agreeing to policies the pop-up is no longer displayed.
When I follow "Continue"
Expand Down
4 changes: 2 additions & 2 deletions admin/tool/uploaduser/tests/behat/upload_users.feature
Original file line number Diff line number Diff line change
Expand Up @@ -183,9 +183,9 @@ Feature: Upload users
And I click on "Manual enrolments" "link" in the "Student One" "table_row"
Then I should see "1 January 2019" in the "Enrolment starts" "table_row"
And I should not see "Enrolment ends"
And I click on "Close" "button"
And I click on "Close" "button" in the "Enrolment details" "dialogue"
And I click on "Manual enrolments" "link" in the "Student Two" "table_row"
Then I should see "2 January 2020" in the "Enrolment starts" "table_row"
And I should see "12 January 2020" in the "Enrolment ends" "table_row"
And I click on "Close" "button"
And I click on "Close" "button" in the "Enrolment details" "dialogue"
And I log out
2 changes: 1 addition & 1 deletion analytics/tests/behat/manage_models.feature
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ Feature: Manage analytics models
And I should see "Configuration"
And I click on "View" "link"
And I should see "Log extra info"
And I click on "Close" "button"
And I click on "Close" "button" in the "Log extra info" "dialogue"
And I navigate to "Analytics > Analytics models" in site administration
# Execute scheduled analysis
And I open the action menu in "Students at risk of not meeting the course completion conditions" "table_row"
Expand Down
6 changes: 3 additions & 3 deletions calendar/tests/behat/calendar.feature
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Feature: Perform basic calendar functionality
And I follow "Full calendar"
And I click on "Really awesome event!" "link"
And "Course 1" "link" should exist in the "Really awesome event!" "dialogue"
And I click on "Close" "button"
And I click on "Close" "button" in the "Really awesome event!" "dialogue"
And I log out
And I log in as "student2"
And I follow "Full calendar"
Expand Down Expand Up @@ -203,7 +203,7 @@ Feature: Perform basic calendar functionality
Then "Course 1" "autocomplete_suggestions" should exist
And "Course 2" "autocomplete_suggestions" should not exist
And "Course 3" "autocomplete_suggestions" should not exist
And I click on "Close" "button"
And I click on "Close" "button" in the "New event" "dialogue"
And I am on site homepage
And I navigate to "Appearance > Calendar" in site administration
And I set the field "Admins see all" to "1"
Expand All @@ -226,7 +226,7 @@ Feature: Perform basic calendar functionality
And I follow "Full calendar"
When I click on "New event" "button"
Then I should see "User" in the "div#fitem_id_staticeventtype" "css_element"
And I click on "Close" "button"
And I click on "Close" "button" in the "New event" "dialogue"
And I log out
Given I log in as "admin"
And I navigate to "Appearance > Calendar" in site administration
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Feature: In a group assignment, teacher can annotate PDF files for all users
When I follow "View annotated PDF..."
Then I should see "Annotate PDF"
And I wait until the page is ready
And I click on "Close" "button"
And I click on "Close" "button" in the "Annotate PDF" "dialogue"
And I log out
And I am on the "Test assignment name" Activity page logged in as student2
And I should not see "View annotated PDF..."
Expand All @@ -79,7 +79,7 @@ Feature: In a group assignment, teacher can annotate PDF files for all users
Then I should see "Annotate PDF"
And I change window size to "medium"
And I wait until the page is ready
And I click on "Close" "button"
And I click on "Close" "button" in the "Annotate PDF" "dialogue"
And I log out

And I am on the "Test assignment name" Activity page logged in as student2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Feature: See the competencies for an activity
And I click on "Rate" "button"
And I set the field "Rating" to "A"
And I click on "Rate" "button" in the ".competency-grader" "css_element"
And I click on "Close" "button"
And I click on "Close" "button" in the "User competency summary" "dialogue"
And I click on "PageName1" "autocomplete_selection"
And I should see "Test-Comp1"
And I should see "Test-Comp2"

0 comments on commit 26d0e51

Please sign in to comment.