From aa49eb24fb14dfd07cd20b3361adc8918e6ffa82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Mudr=C3=A1k?= Date: Fri, 2 Sep 2022 15:47:44 +0200 Subject: [PATCH] MDL-75553 lang: Fix Behat regressions in scenario files --- .../restore_moodle2_courses_settings.feature | 2 +- .../block_myoverview_adminsettings.feature | 30 +++++++-------- .../behat/block_myoverview_dashboard.feature | 18 ++++----- .../behat/block_myoverview_hidden.feature | 38 +++++++++---------- ...aderescale_for_database_pointscale.feature | 2 +- mod/data/tests/behat/add_entries.feature | 8 ++-- .../behat/data_activity_completion.feature | 2 +- ...ata_activity_completion_pass_grade.feature | 2 +- mod/data/tests/behat/manageapproved.feature | 4 +- mod/data/tests/behat/required_entries.feature | 28 +++++++------- mod/feedback/tests/behat/multichoice.feature | 6 +-- 11 files changed, 70 insertions(+), 70 deletions(-) diff --git a/backup/util/ui/tests/behat/restore_moodle2_courses_settings.feature b/backup/util/ui/tests/behat/restore_moodle2_courses_settings.feature index fabadbac987..86939ccf9cd 100644 --- a/backup/util/ui/tests/behat/restore_moodle2_courses_settings.feature +++ b/backup/util/ui/tests/behat/restore_moodle2_courses_settings.feature @@ -21,7 +21,7 @@ Feature: Restore Moodle 2 course backups with different user data settings | data | Test database name | n | C1 | data1 | And I log in as "teacher1" And I am on "Course 1" course homepage - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field name | | Field description | Test field description | And I navigate to "Templates" in current page administration diff --git a/blocks/myoverview/tests/behat/block_myoverview_adminsettings.feature b/blocks/myoverview/tests/behat/block_myoverview_adminsettings.feature index 25a1c148346..d962f0844bd 100644 --- a/blocks/myoverview/tests/behat/block_myoverview_adminsettings.feature +++ b/blocks/myoverview/tests/behat/block_myoverview_adminsettings.feature @@ -26,26 +26,26 @@ Feature: The my overview block allows admins to easily configure the students' c | student1 | C4 | student | | student1 | C5 | student | - Scenario: Enable 'All (including archived)' course filter option + Scenario: Enable 'All (including removed from view)' course filter option Given I log in as "admin" And I navigate to "Plugins > Blocks > Course overview" in site administration - And I set the field "All (including archived)" to "1" + And I set the field "All (including removed from view)" to "1" And I press "Save" And I log out Then I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" # We have to check for the data attribute instead of the list element text as we would get false positives from the "All" element otherwise - Then "All (including archived)" "list_item" should exist in the ".block_myoverview .dropdown-menu" "css_element" + Then "All (including removed from view)" "list_item" should exist in the ".block_myoverview .dropdown-menu" "css_element" - Scenario: Disable 'All (including archived)' course filter option + Scenario: Disable 'All (including removed from view)' course filter option Given I log in as "admin" And I navigate to "Plugins > Blocks > Course overview" in site administration - And I set the field "All (including archived)" to "0" + And I set the field "All (including removed from view)" to "0" And I press "Save" And I log out Then I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" - Then "All (including archived)" "list_item" should not exist in the ".block_myoverview .dropdown-menu" "css_element" + Then "All (including removed from view)" "list_item" should not exist in the ".block_myoverview .dropdown-menu" "css_element" Scenario: Enable 'All' course filter option Given I log in as "admin" @@ -76,7 +76,7 @@ Feature: The my overview block allows admins to easily configure the students' c And I log out Then I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" - # We have to check for the data attribute instead of the list element text as we would get false negatives "All (including archived)" element otherwise + # We have to check for the data attribute instead of the list element text as we would get false negatives "All (including removed from view)" element otherwise Then "In progress" "list_item" should exist in the ".block_myoverview .dropdown-menu" "css_element" Scenario: Disable 'In progress' course filter option @@ -152,33 +152,33 @@ Feature: The my overview block allows admins to easily configure the students' c Scenario: Enable 'Removed courses' course filter option Given I log in as "admin" And I navigate to "Plugins > Blocks > Course overview" in site administration - And I set the field "Archived" to "1" + And I set the field "Removed from view" to "1" And I press "Save" And I log out Then I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" - Then "Archived" "list_item" should exist in the ".block_myoverview .dropdown-menu" "css_element" + Then "Removed from view" "list_item" should exist in the ".block_myoverview .dropdown-menu" "css_element" Scenario: Disable 'Removed courses' course filter option Given I log in as "admin" And I navigate to "Plugins > Blocks > Course overview" in site administration - And I set the field "Archived" to "0" + And I set the field "Removed from view" to "0" And I press "Save" And I log out Then I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" - Then "Archived" "list_item" should not exist in the ".block_myoverview .dropdown-menu" "css_element" + Then "Removed from view" "list_item" should not exist in the ".block_myoverview .dropdown-menu" "css_element" Scenario: Disable all course filter options Given I log in as "admin" And I navigate to "Plugins > Blocks > Course overview" in site administration - And I set the field "All (including archived)" to "0" + And I set the field "All (including removed from view)" to "0" And I set the field "All" in the "//*[@id=\"admin-displaygroupingall\"]" "xpath_element" to "0" And I set the field "In progress" to "0" And I set the field "Future" to "0" And I set the field "Past" to "0" And I set the field "Starred" to "0" - And I set the field "Archived" to "0" + And I set the field "Removed from view" to "0" And I press "Save" And I log out And I am on the "My courses" page logged in as "student1" @@ -192,13 +192,13 @@ Feature: The my overview block allows admins to easily configure the students' c Scenario: Disable all but one course filter option Given I log in as "admin" And I navigate to "Plugins > Blocks > Course overview" in site administration - And I set the field "All (including archived)" to "0" + And I set the field "All (including removed from view)" to "0" And I set the field "All" in the "//*[@id=\"admin-displaygroupingall\"]" "xpath_element" to "0" And I set the field "In progress" to "1" And I set the field "Future" to "0" And I set the field "Past" to "0" And I set the field "Starred" to "0" - And I set the field "Archived" to "0" + And I set the field "Removed from view" to "0" And I press "Save" And I log out And I am on the "My courses" page logged in as "student1" diff --git a/blocks/myoverview/tests/behat/block_myoverview_dashboard.feature b/blocks/myoverview/tests/behat/block_myoverview_dashboard.feature index 43ca3107849..b4b495250d0 100644 --- a/blocks/myoverview/tests/behat/block_myoverview_dashboard.feature +++ b/blocks/myoverview/tests/behat/block_myoverview_dashboard.feature @@ -66,13 +66,13 @@ Feature: The my overview block allows users to easily access their courses Then I should see "Course 4" in the "Course overview" "block" Then I should see "Course 5" in the "Course overview" "block" - Scenario: View all (including archived) courses + Scenario: View all (including removed from view) courses Given the following config values are set as admin: | config | value | plugin | | displaygroupingallincludinghidden | 1 | block_myoverview | And I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" - # We have to click on the data attribute instead of the button element text as we might risk to click on the false positive "All (including archived)" element instead + # We have to click on the data attribute instead of the button element text as we might risk to click on the false positive "All (including removed from view)" element instead When I click on "[data-value='allincludinghidden']" "css_element" in the "Course overview" "block" Then I should see "Course 1" in the "Course overview" "block" Then I should see "Course 2" in the "Course overview" "block" @@ -203,7 +203,7 @@ Feature: The my overview block allows users to easily access their courses When I click on "In progress" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I reload the page Then I should see "Course 3" in the "Course overview" "block" Then I should see "Course 4" in the "Course overview" "block" @@ -217,7 +217,7 @@ Feature: The my overview block allows users to easily access their courses When I click on "Past" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 1')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 1')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 1')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 1')]" "xpath_element" And I reload the page Then I should not see "Course 1" in the "Course overview" "block" And I should not see "Course 2" in the "Course overview" "block" @@ -231,7 +231,7 @@ Feature: The my overview block allows users to easily access their courses When I click on "Future" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" And I reload the page Then I should not see "Course 5" in the "Course overview" "block" And I should not see "Course 1" in the "Course overview" "block" @@ -245,7 +245,7 @@ Feature: The my overview block allows users to easily access their courses When I click on "All" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" And I reload the page Then I should not see "Course 5" in the "Course overview" "block" And I should see "Course 1" in the "Course overview" "block" @@ -253,17 +253,17 @@ Feature: The my overview block allows users to easily access their courses And I should see "Course 3" in the "Course overview" "block" And I should see "Course 4" in the "Course overview" "block" - Scenario: View all (including archived) courses with hide persistent functionality + Scenario: View all (including removed from view) courses with hide persistent functionality Given the following config values are set as admin: | config | value | plugin | | displaygroupingallincludinghidden | 1 | block_myoverview | And I am on the "My courses" page logged in as "student1" And I click on "All" "button" in the "Course overview" "block" - # We have to click on the data attribute instead of the button element text as we might risk to click on the false positive "All (including archived)" element instead + # We have to click on the data attribute instead of the button element text as we might risk to click on the false positive "All (including removed from view)" element instead When I click on "[data-value='allincludinghidden']" "css_element" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 5')]" "xpath_element" And I reload the page Then I should see "Course 5" in the "Course overview" "block" And I should see "Course 1" in the "Course overview" "block" diff --git a/blocks/myoverview/tests/behat/block_myoverview_hidden.feature b/blocks/myoverview/tests/behat/block_myoverview_hidden.feature index e27ef877174..c0bb19069a6 100644 --- a/blocks/myoverview/tests/behat/block_myoverview_hidden.feature +++ b/blocks/myoverview/tests/behat/block_myoverview_hidden.feature @@ -29,7 +29,7 @@ Feature: The my overview block allows users to hide their courses When I click on "All" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I reload the page Then I should not see "Course 2" in the "Course overview" "block" @@ -42,14 +42,14 @@ Feature: The my overview block allows users to hide their courses And I click on "Star this course" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" When I reload the page Then I should not see "Course 2" in the "Course overview" "block" And I click on "All" "button" in the "Course overview" "block" And I click on "Starred" "link" in the "Course overview" "block" Then I should not see "Course 2" in the "Course overview" "block" And I click on "Starred" "button" in the "Course overview" "block" - And I click on "Archived" "link" in the "Course overview" "block" + And I click on "Removed from view" "link" in the "Course overview" "block" Then I should see "Course 2" in the "Course overview" "block" Scenario: Test show toggle functionality @@ -58,14 +58,14 @@ Feature: The my overview block allows users to hide their courses When I click on "All" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" When I click on "All" "button" in the "Course overview" "block" - And I click on "Archived" "link" in the "Course overview" "block" + And I click on "Removed from view" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" When I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Unarchive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Restore to view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I reload the page - And I click on "Archived" "button" in the "Course overview" "block" + And I click on "Removed from view" "button" in the "Course overview" "block" When I click on "All" "link" in the "Course overview" "block" Then I should see "Course 2" in the "Course overview" "block" @@ -78,16 +78,16 @@ Feature: The my overview block allows users to hide their courses And I click on "Star this course" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on "All" "button" in the "Course overview" "block" - And I click on "Archived" "link" in the "Course overview" "block" + And I click on "Removed from view" "link" in the "Course overview" "block" And I should see "Course 2" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Unarchive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Restore to view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" When I reload the page Then I should not see "Course 2" in the "Course overview" "block" - And I click on "Archived" "button" in the "Course overview" "block" + And I click on "Removed from view" "button" in the "Course overview" "block" And I click on "All" "link" in the "Course overview" "block" Then I should see "Course 2" in the "Course overview" "block" And I click on "All" "button" in the "Course overview" "block" @@ -100,10 +100,10 @@ Feature: The my overview block allows users to hide their courses When I click on "All" "link" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" Then I should not see "Course 2" in the "Course overview" "block" - Scenario: Test a course is never hidden with "All (including archived)" courses + Scenario: Test a course is never hidden with "All (including removed from view)" courses Given the following config values are set as admin: | config | value | plugin | | displaygroupingallincludinghidden | 1 | block_myoverview | @@ -113,15 +113,15 @@ Feature: The my overview block allows users to hide their courses When I click on "[data-value='allincludinghidden']" "css_element" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Archive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Remove from view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" Then I should see "Course 2" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I should not see "Archive" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I should see "Unarchive" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I click on "Unarchive" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I should not see "Remove from view" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I should see "Restore to view" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I click on "Restore to view" "link" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" Then I should see "Course 2" in the "Course overview" "block" And I hover "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" And I click on ".coursemenubtn" "css_element" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I should see "Archive" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" - And I should not see "Unarchive" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I should see "Remove from view" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" + And I should not see "Restore to view" in the "//div[@class='card dashboard-card' and contains(.,'Course 2')]" "xpath_element" diff --git a/lib/form/tests/behat/graderescale_for_database_pointscale.feature b/lib/form/tests/behat/graderescale_for_database_pointscale.feature index d629fabb310..474f4f6a218 100644 --- a/lib/form/tests/behat/graderescale_for_database_pointscale.feature +++ b/lib/form/tests/behat/graderescale_for_database_pointscale.feature @@ -23,7 +23,7 @@ Feature: Using the database activities which support point scale @javascript Scenario: Database rescale grade should not be possible when users are graded Given I am on the "Course 1" course page logged in as teacher1 - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field name | | Field description | Test field description | And I navigate to "Templates" in current page administration diff --git a/mod/data/tests/behat/add_entries.feature b/mod/data/tests/behat/add_entries.feature index 230d3340978..782f2df0f96 100644 --- a/mod/data/tests/behat/add_entries.feature +++ b/mod/data/tests/behat/add_entries.feature @@ -23,10 +23,10 @@ Feature: Users can add entries to database activities @javascript Scenario: Students can add entries to a database Given I am on the "Course 1" course page logged in as teacher1 - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field name | | Field description | Test field description | - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field 2 name | | Field description | Test field 2 description | # To generate the default templates. @@ -94,7 +94,7 @@ Feature: Users can add entries to database activities And I set the following fields to these values: | Maximum number of entries | 2 | And I press "Save and display" - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test1 | And I navigate to "Templates" in current page administration And I press "Save template" @@ -135,7 +135,7 @@ Feature: Users can add entries to database activities And I should not see "Add entry" When I log out And I am on the "Test database name" "data activity" page logged in as teacher1 - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field name | | Field description | Test field description | And I log out diff --git a/mod/data/tests/behat/data_activity_completion.feature b/mod/data/tests/behat/data_activity_completion.feature index fe4df594000..2095ef23fc4 100644 --- a/mod/data/tests/behat/data_activity_completion.feature +++ b/mod/data/tests/behat/data_activity_completion.feature @@ -34,7 +34,7 @@ Feature: View activity completion in the database activity | Require view | 1 | | Require grade | 1 | And I press "Save and display" - And I add a "Text input" field to "Music history" database and I fill the form with: + And I add a "Short text" field to "Music history" database and I fill the form with: | Field name | Instrument types | And I navigate to "Templates" in current page administration And I press "Save template" diff --git a/mod/data/tests/behat/data_activity_completion_pass_grade.feature b/mod/data/tests/behat/data_activity_completion_pass_grade.feature index a1e2355bc08..f7f7fc942d0 100644 --- a/mod/data/tests/behat/data_activity_completion_pass_grade.feature +++ b/mod/data/tests/behat/data_activity_completion_pass_grade.feature @@ -48,7 +48,7 @@ Feature: Completion pass grade | completionentriesenabled | 1 | | completionentries | 2 | And I press "Save and display" - And I add a "Text input" field to "Music history" database and I fill the form with: + And I add a "Short text" field to "Music history" database and I fill the form with: | Field name | Instrument types | And I navigate to "Templates" in current page administration And I press "Save template" diff --git a/mod/data/tests/behat/manageapproved.feature b/mod/data/tests/behat/manageapproved.feature index 19aed506d19..4f86ecba5a7 100644 --- a/mod/data/tests/behat/manageapproved.feature +++ b/mod/data/tests/behat/manageapproved.feature @@ -27,7 +27,7 @@ Feature: Users can edit approved entries in database activities | approval | 1 | | manageapproved | 1 | And I am on the "Test database name" "data activity" page logged in as teacher1 - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field name | | Field description | Test field description | # To generate the default templates. @@ -59,7 +59,7 @@ Feature: Users can edit approved entries in database activities | approval | 1 | | manageapproved | 0 | And I am on the "Test database name" "data activity" page logged in as teacher1 - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Test field name | | Field description | Test field description | # To generate the default templates. diff --git a/mod/data/tests/behat/required_entries.feature b/mod/data/tests/behat/required_entries.feature index 4e39a6c952a..ba23ffb2972 100644 --- a/mod/data/tests/behat/required_entries.feature +++ b/mod/data/tests/behat/required_entries.feature @@ -21,7 +21,7 @@ Feature: Users can be required to specify certain fields when adding entries to | data | Test database name | n | C1 | data1 | And I log in as "teacher1" And I am on "Course 1" course homepage - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Base Text input | | Required | yes | | Field description | Base Text input | @@ -42,9 +42,9 @@ Feature: Users can be required to specify certain fields when adding entries to RTOC Option 2 """ And I press "Add" - And I add a "Latlong" field to "Test database name" database and I fill the form with: - | Field name | Required Latlong | - | Field description | Required Latlong | + And I add a "Coordinates" field to "Test database name" database and I fill the form with: + | Field name | Required Coordinates | + | Field description | Required Coordinates | | Required | yes | And I add a "Menu" field to "Test database name" database and I fill the form with: | Field name | Required Menu | @@ -60,7 +60,7 @@ Feature: Users can be required to specify certain fields when adding entries to | Field description | Required Radio | | Required | yes | | Options | Required Radio Option 1 | - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Required Text input | | Field description | Required Text input | | Required | yes | @@ -93,9 +93,9 @@ Feature: Users can be required to specify certain fields when adding entries to | Field name | Not required Checkbox | | Field description | Not required Checkbox | | Options | Not required Checkbox Option 1 | - And I add a "Latlong" field to "Test database name" database and I fill the form with: - | Field name | Not required Latlong | - | Field description | Not required Latlong | + And I add a "Coordinates" field to "Test database name" database and I fill the form with: + | Field name | Not required Coordinates | + | Field description | Not required Coordinates | And I add a "Menu" field to "Test database name" database and I fill the form with: | Field name | Not required Menu | | Field description | Not required Menu | @@ -107,7 +107,7 @@ Feature: Users can be required to specify certain fields when adding entries to | Field name | Not required Radio | | Field description | Not required Radio | | Options | Not required Radio Option 1 | - And I add a "Text input" field to "Test database name" database and I fill the form with: + And I add a "Short text" field to "Test database name" database and I fill the form with: | Field name | Not required Text input | | Field description | Not required Text input | And I add a "Text area" field to "Test database name" database and I fill the form with: @@ -131,7 +131,7 @@ Feature: Users can be required to specify certain fields when adding entries to And I press "Save" Then ".alert" "css_element" should exist in the "Required Checkbox" "table_row" And ".alert" "css_element" should exist in the "Required Two-Option Checkbox" "table_row" - And ".alert" "css_element" should exist in the "Required Latlong" "table_row" + And ".alert" "css_element" should exist in the "Required Coordinates" "table_row" And ".alert" "css_element" should exist in the "Required Menu" "table_row" And ".alert" "css_element" should exist in the "Required Number" "table_row" And ".alert" "css_element" should exist in the "Required Radio" "table_row" @@ -141,7 +141,7 @@ Feature: Users can be required to specify certain fields when adding entries to And ".alert" "css_element" should exist in the "Required Multimenu" "table_row" And ".alert" "css_element" should exist in the "Required Two-Option Multimenu" "table_row" And ".alert" "css_element" should not exist in the "Not required Checkbox" "table_row" - And ".alert" "css_element" should not exist in the "Not required Latlong" "table_row" + And ".alert" "css_element" should not exist in the "Not required Coordinates" "table_row" And ".alert" "css_element" should not exist in the "Not required Menu" "table_row" And ".alert" "css_element" should not exist in the "Not required Number" "table_row" And ".alert" "css_element" should not exist in the "Not required Radio" "table_row" @@ -220,10 +220,10 @@ Feature: Users can be required to specify certain fields when adding entries to | Required URL | http://example.com/ | | Required Multimenu | 1 | | Required Two-Option Multimenu | 1 | - And I set the field with xpath "//div[@title='Not required Latlong']//tr[td/label[normalize-space(.)='Latitude']]/td/input" to "20" + And I set the field with xpath "//div[@title='Not required Coordinates']//tr[td/label[normalize-space(.)='Latitude']]/td/input" to "20" And I press "Save" - Then ".alert" "css_element" should exist in the "Required Latlong" "table_row" - And ".alert" "css_element" should exist in the "Not required Latlong" "table_row" + Then ".alert" "css_element" should exist in the "Required Coordinates" "table_row" + And ".alert" "css_element" should exist in the "Not required Coordinates" "table_row" Scenario: A student filling in number and text fields with zero will not see an error. Given I log in as "student1" diff --git a/mod/feedback/tests/behat/multichoice.feature b/mod/feedback/tests/behat/multichoice.feature index 2cddd4a0e67..31abc53562c 100644 --- a/mod/feedback/tests/behat/multichoice.feature +++ b/mod/feedback/tests/behat/multichoice.feature @@ -153,7 +153,7 @@ Feature: Testing multichoice questions in feedback And I click on "Edit questions" "link" in the "[role=main]" "css_element" And I open the action menu in "//div[contains(@class, 'feedback_itemlist') and contains(.,'multichoice1')]" "xpath_element" And I choose "Edit question" in the open action menu - And I set the field "Do not analyse empty submits" to "Yes" + And I set the field "Omit empty submits in analysis" to "Yes" And I press "Save changes to question" And I am on the "Learning experience" "feedback activity" page And I navigate to "Analysis" in current page administration @@ -293,7 +293,7 @@ Feature: Testing multichoice questions in feedback And I click on "Edit questions" "link" in the "[role=main]" "css_element" And I open the action menu in "//div[contains(@class, 'feedback_itemlist') and contains(.,'multichoice1')]" "xpath_element" And I choose "Edit question" in the open action menu - And I set the field "Do not analyse empty submits" to "Yes" + And I set the field "Omit empty submits in analysis" to "Yes" And I press "Save changes to question" And I am on the "Learning experience" "feedback activity" page And I navigate to "Analysis" in current page administration @@ -412,7 +412,7 @@ Feature: Testing multichoice questions in feedback And I click on "Edit questions" "link" in the "[role=main]" "css_element" And I open the action menu in "//div[contains(@class, 'feedback_itemlist') and contains(.,'multichoice1')]" "xpath_element" And I choose "Edit question" in the open action menu - And I set the field "Do not analyse empty submits" to "Yes" + And I set the field "Omit empty submits in analysis" to "Yes" And I press "Save changes to question" And I am on the "Learning experience" "feedback activity" page And I navigate to "Analysis" in current page administration