mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 17:36:38 +02:00
Merge branch 'migration-nov26' of https://github.com/Chocolate-lightning/moodle
This commit is contained in:
commit
d29c09344e
150 changed files with 944 additions and 445 deletions
|
@ -30,8 +30,7 @@ Feature: Course index depending on role
|
|||
Given I am on the "C1" "Course" page logged in as "teacher1"
|
||||
Given the "multilang" filter is "on"
|
||||
And the "multilang" filter applies to "content and headings"
|
||||
And I am on the "C1" "Course" page logged in as "teacher1"
|
||||
When I click on "Side panel" "button"
|
||||
When I am on the "C1" "Course" page logged in as "teacher1"
|
||||
Then I should see "Open course index drawer"
|
||||
And I am on the "Activity sample 1" "assign activity editing" page
|
||||
And I set the field "Assignment name" in the "General" "fieldset" to "<span lang=\"en\" class=\"multilang\">Activity</span><span lang=\"de\" class=\"multilang\">Aktivität</span> sample 1"
|
||||
|
@ -44,7 +43,6 @@ Feature: Course index depending on role
|
|||
Scenario: Course index as a teacher
|
||||
Given I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should see "Topic 2" in the "courseindex-content" "region"
|
||||
|
@ -63,7 +61,6 @@ Feature: Course index depending on role
|
|||
And I log out
|
||||
And I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should see "Topic 2" in the "courseindex-content" "region"
|
||||
|
@ -82,7 +79,6 @@ Feature: Course index depending on role
|
|||
And I log out
|
||||
And I log in as "student1"
|
||||
And I am on "Course 1" course homepage
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should not see "Topic 2" in the "courseindex-content" "region"
|
||||
|
@ -95,7 +91,6 @@ Feature: Course index depending on role
|
|||
Scenario: Delete an activity as a teacher
|
||||
Given I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
And I click on "Side panel" "button"
|
||||
When I delete "Activity sample 2" activity
|
||||
And I click on "Open course index drawer" "button"
|
||||
Then I should not see "Activity sample 2" in the "courseindex-content" "region"
|
||||
|
@ -104,7 +99,6 @@ Feature: Course index depending on role
|
|||
Scenario: Highlight sections are represented in the course index.
|
||||
Given I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
And I click on "Side panel" "button"
|
||||
And I turn section "2" highlighting on
|
||||
And I click on "Open course index drawer" "button"
|
||||
# Current section is only marked visually in the course index.
|
||||
|
@ -124,7 +118,6 @@ Feature: Course index depending on role
|
|||
| book | Second activity in section 1 | Test book description | C1 | sample4 | 1 |
|
||||
And I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
# Sections should be opened by default.
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
|
@ -174,7 +167,6 @@ Feature: Course index depending on role
|
|||
@javascript
|
||||
Scenario: Course index section preferences
|
||||
Given I am on the "C1" "Course" page logged in as "teacher1"
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should see "Activity sample 1" in the "courseindex-content" "region"
|
||||
|
@ -205,6 +197,7 @@ Feature: Course index depending on role
|
|||
And I delete section "1"
|
||||
And I click on "Delete" "button" in the ".modal" "css_element"
|
||||
And I reload the page
|
||||
And I click on "Open course index drawer" "button"
|
||||
And I should not see "Activity sample 1" in the "courseindex-content" "region"
|
||||
And I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should see "Activity sample 2" in the "courseindex-content" "region"
|
||||
|
@ -215,7 +208,6 @@ Feature: Course index depending on role
|
|||
Scenario: Adding section should alter the course index
|
||||
Given I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
When I click on "Add topic after" "link" in the "Topic 4" "section"
|
||||
Then I should see "Topic 5" in the "courseindex-content" "region"
|
||||
|
@ -224,7 +216,6 @@ Feature: Course index depending on role
|
|||
Scenario: Remove a section should alter the course index
|
||||
Given I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
When I delete section "4"
|
||||
Then I should not see "Topic 4" in the "courseindex-content" "region"
|
||||
|
@ -233,7 +224,6 @@ Feature: Course index depending on role
|
|||
Scenario: Delete a previous section should alter the course index unnamed sections
|
||||
Given I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
When I delete section "1"
|
||||
And I click on "Delete" "button" in the ".modal" "css_element"
|
||||
|
|
|
@ -26,7 +26,6 @@ Feature: Course index completion icons
|
|||
@javascript
|
||||
Scenario: Teacher does not see completion icons.
|
||||
Given I am on the "C1" "Course" page logged in as "teacher1"
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should see "Activity sample 1" in the "courseindex-content" "region"
|
||||
|
@ -35,7 +34,6 @@ Feature: Course index completion icons
|
|||
@javascript
|
||||
Scenario: User should see the completion icons
|
||||
Given I am on the "C1" "Course" page logged in as "student1"
|
||||
And I click on "Side panel" "button"
|
||||
When I click on "Open course index drawer" "button"
|
||||
Then I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And I should see "Activity sample 1" in the "courseindex-content" "region"
|
||||
|
@ -44,7 +42,6 @@ Feature: Course index completion icons
|
|||
@javascript
|
||||
Scenario: Manual completion shoudl update the course index completion
|
||||
Given I am on the "C1" "Course" page logged in as "student1"
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
And "To do" "icon" should exist in the "courseindex-content" "region"
|
||||
When I press "Mark as done"
|
||||
|
@ -57,7 +54,6 @@ Feature: Course index completion icons
|
|||
@javascript
|
||||
Scenario: Refresh the page should keep the completion consistent
|
||||
Given I am on the "C1" "Course" page logged in as "student1"
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
And "To do" "icon" should exist in the "courseindex-content" "region"
|
||||
When I press "Mark as done"
|
||||
|
@ -72,7 +68,6 @@ Feature: Course index completion icons
|
|||
| assign | Activity sample 2 | Test assignment description | C1 | sample2 | 1 | 1 | 1 |
|
||||
When I am on the "sample2" "Activity" page logged in as "student1"
|
||||
And I am on the "C1" "Course" page
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
Then "Done" "icon" should exist in the "courseindex-content" "region"
|
||||
|
||||
|
@ -94,7 +89,6 @@ Feature: Course index completion icons
|
|||
| slot | response |
|
||||
| 1 | False |
|
||||
When I am on the "C1" "Course" page logged in as "student1"
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
And "Failed" "icon" should exist in the "courseindex-content" "region"
|
||||
|
||||
|
@ -116,6 +110,5 @@ Feature: Course index completion icons
|
|||
| slot | response |
|
||||
| 1 | True |
|
||||
When I am on the "C1" "Course" page logged in as "student1"
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
And "Done" "icon" should exist in the "courseindex-content" "region"
|
||||
|
|
|
@ -17,7 +17,6 @@ Feature: Verify that courseindex is usable with the keyboard
|
|||
| book | Activity sample 2 | Test book description | C1 | sample2 | 2 |
|
||||
| choice | Activity sample 3 | Test choice description | C1 | sample3 | 3 |
|
||||
Given I am on the "C1" "Course" page logged in as "admin"
|
||||
And I click on "Side panel" "button"
|
||||
And I click on "Open course index drawer" "button"
|
||||
And I should see "Topic 1" in the "courseindex-content" "region"
|
||||
And the focused element is "[data-preference='drawer-open-index'] .drawertoggle" "css_element"
|
||||
|
|
|
@ -1938,7 +1938,7 @@ class behat_course extends behat_base {
|
|||
* @Given /^I navigate to course participants$/
|
||||
*/
|
||||
public function i_navigate_to_course_participants() {
|
||||
$this->execute('behat_navigation::i_select_from_flat_navigation_drawer', get_string('participants'));
|
||||
$this->execute('behat_navigation::i_select_from_secondary_navigation', get_string('participants'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -155,7 +155,7 @@ Feature: Collapse course sections
|
|||
| Course layout | Show one section per page |
|
||||
And I press "Save and display"
|
||||
And "[data-toggle=collapse]" "css_element" should not exist in the "region-main" "region"
|
||||
And I follow "Topic 2"
|
||||
And I click on "Topic 2" "link" in the "region-main" "region"
|
||||
And I should see "Assignment 2" in the "region-main" "region"
|
||||
And "[data-toggle=collapse]" "css_element" should not exist in the "region-main" "region"
|
||||
Then "Topic 1" "section" should not exist
|
||||
|
@ -178,7 +178,7 @@ Feature: Collapse course sections
|
|||
| Course layout | Show one section per page |
|
||||
And I press "Save and display"
|
||||
And "[data-toggle=collapse]" "css_element" should not exist in the "region-main" "region"
|
||||
And I follow "8 May - 14 May"
|
||||
And I click on "8 May - 14 May" "link" in the "region-main" "region"
|
||||
And I should see "Assignment 2" in the "region-main" "region"
|
||||
And "[data-toggle=collapse]" "css_element" should not exist in the "region-main" "region"
|
||||
Then "1 May - 7 May" "section" should not exist
|
||||
|
|
|
@ -27,9 +27,8 @@ Feature: Course activity controls works as expected
|
|||
| user | course | role |
|
||||
| teacher1 | C1 | editingteacher |
|
||||
And I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage
|
||||
When I follow <targetpage>
|
||||
And I turn editing mode on
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
When I follow the breadcrumb <targetpage>
|
||||
And I add the "Recent activity" block
|
||||
And I open the action menu in "Recent activity" "block"
|
||||
And I click on "Delete Recent activity block" "link"
|
||||
|
@ -99,9 +98,8 @@ Feature: Course activity controls works as expected
|
|||
| forum | Test forum name 1 | Test forum description 1 | C1 | 0001 | 1 |
|
||||
| forum | Test forum name 2 | Test forum description 2 | C1 | 0002 | 1 |
|
||||
And I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage
|
||||
When I follow <targetpage>
|
||||
And I turn editing mode on
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
When I follow the breadcrumb <targetpage>
|
||||
And I add the "Recent activity" block
|
||||
And I open the action menu in "Recent activity" "block"
|
||||
And I click on "Delete Recent activity block" "link"
|
||||
|
|
|
@ -27,7 +27,7 @@ Feature: Managers can create courses
|
|||
And I log out
|
||||
And I am on the Announcements "forum activity" page logged in as student1
|
||||
And "Add a new topic" "link" should not exist
|
||||
And "Forced subscription" "text" should exist in current page administration
|
||||
And "Forced subscription" "text" should exist
|
||||
|
||||
Scenario: Create a course from the management interface and return to it
|
||||
Given the following "courses" exist:
|
||||
|
|
|
@ -27,11 +27,13 @@ Feature: Access to downloading course content can be controlled
|
|||
And I navigate to "Settings" in current page administration
|
||||
And I set the field "Enable download course content" to "Yes"
|
||||
And I press "Save and display"
|
||||
And "Download course content" "link" should exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
And "Download course content" "link" should exist
|
||||
When the following config values are set as admin:
|
||||
| downloadcoursecontentallowed | 0 |
|
||||
And I am on "Hockey 101" course homepage
|
||||
Then "Download course content" "link" should not exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
And "Download course content" "link" should not exist
|
||||
And I navigate to "Settings" in current page administration
|
||||
And I should not see "Enable download course content"
|
||||
|
||||
|
@ -43,7 +45,8 @@ Feature: Access to downloading course content can be controlled
|
|||
And I set the field "Enable download course content" to "Yes"
|
||||
And I press "Save changes"
|
||||
And I am on "Hockey 101" course homepage
|
||||
Then "Download course content" "link" should exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
Then "Download course content" "link" should exist
|
||||
|
||||
Scenario: A teacher can enable and disable the download course content feature when it is available
|
||||
Given I log in as "teacher1"
|
||||
|
@ -53,11 +56,13 @@ Feature: Access to downloading course content can be controlled
|
|||
And I should see "Enable download course content"
|
||||
And I set the field "Enable download course content" to "Yes"
|
||||
And I press "Save and display"
|
||||
Then "Download course content" "link" should exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
Then "Download course content" "link" should exist
|
||||
And I navigate to "Settings" in current page administration
|
||||
And I set the field "Enable download course content" to "No"
|
||||
And I press "Save and display"
|
||||
And "Download course content" "link" should not exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
And "Download course content" "link" should not exist
|
||||
|
||||
Scenario: Teachers require a capability to access the download course content feature or modify its availability in a course
|
||||
Given I log in as "admin"
|
||||
|
@ -68,7 +73,8 @@ Feature: Access to downloading course content can be controlled
|
|||
# Check teacher can see download option and enable dropdown.
|
||||
And I log in as "teacher1"
|
||||
And I am on "Hockey 101" course homepage
|
||||
And "Download course content" "link" should exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
And "Download course content" "link" should exist
|
||||
And I navigate to "Settings" in current page administration
|
||||
And "Enable download course content" "select" should exist
|
||||
And I log out
|
||||
|
@ -82,7 +88,8 @@ Feature: Access to downloading course content can be controlled
|
|||
# Check teacher can no longer see download option, and that enable value is visible, but dropdown no longer available.
|
||||
When I log in as "teacher1"
|
||||
And I am on "Hockey 101" course homepage
|
||||
Then "Download course content" "link" should not exist in current page administration
|
||||
And I navigate to "Course administration" in current page administration
|
||||
Then "Download course content" "link" should not exist
|
||||
And I navigate to "Settings" in current page administration
|
||||
And I should see "Enable download course content"
|
||||
And I should see "Site default (Yes)"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue