mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
Merge branch 'MDL-75553-master' of https://github.com/junpataleta/moodle
This commit is contained in:
commit
adba94a873
33 changed files with 133 additions and 133 deletions
|
@ -22,12 +22,12 @@
|
|||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
$string['allincludinghidden'] = 'All (including archived)';
|
||||
$string['allincludinghidden'] = 'All (including removed from view)';
|
||||
$string['all'] = 'All';
|
||||
$string['addtofavourites'] = 'Star this course';
|
||||
$string['aria:addtofavourites'] = 'Star for';
|
||||
$string['aria:allcoursesincludinghidden'] = 'Show all courses';
|
||||
$string['aria:allcourses'] = 'Show all courses except archived courses';
|
||||
$string['aria:allcourses'] = 'Show all courses except courses removed from view';
|
||||
$string['aria:card'] = 'Switch to card view';
|
||||
$string['aria:controls'] = 'Course overview controls';
|
||||
$string['aria:courseactions'] = 'Actions for current course';
|
||||
|
@ -77,11 +77,11 @@ $string['summary'] = 'Summary';
|
|||
$string['title'] = 'Course name';
|
||||
$string['aria:hidecourse'] = 'Remove {$a} from view';
|
||||
$string['aria:showcourse'] = 'Restore {$a} to view';
|
||||
$string['aria:hiddencourses'] = 'Show archived courses';
|
||||
$string['hidden'] = 'Archived courses';
|
||||
$string['hidecourse'] = 'Archive';
|
||||
$string['hiddencourses'] = 'Archived';
|
||||
$string['show'] = 'Unarchive';
|
||||
$string['aria:hiddencourses'] = 'Show courses removed from view';
|
||||
$string['hidden'] = 'Courses removed from view';
|
||||
$string['hidecourse'] = 'Remove from view';
|
||||
$string['hiddencourses'] = 'Removed from view';
|
||||
$string['show'] = 'Restore to view';
|
||||
$string['sortbytitle'] = 'Sort by course name';
|
||||
$string['sortbylastaccessed'] = 'Sort by last accessed';
|
||||
$string['sortbyshortname'] = 'Sort by short name';
|
||||
|
|
|
@ -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"
|
||||
|
|
|
@ -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"
|
||||
|
|
|
@ -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"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue