mirror of
https://github.com/moodle/moodle.git
synced 2025-04-14 04:52:36 +02:00
MDL-44711 course: fixed navigation expansion in course tests
This commit is contained in:
parent
65ae0a1bde
commit
37d39fe348
@ -122,9 +122,7 @@ class behat_course extends behat_base {
|
||||
public function i_go_to_the_courses_management_page() {
|
||||
return array(
|
||||
new Given('I am on homepage'),
|
||||
new Given('I expand "' . get_string('administrationsite') . '" node'),
|
||||
new Given('I expand "' . get_string('courses', 'admin') . '" node'),
|
||||
new Given('I follow "' . get_string('coursemgmt', 'admin') . '"')
|
||||
new Given('I navigate to "' . get_string('coursemgmt', 'admin') . '" node in "' . get_string('administrationsite') . ' > ' . get_string('courses', 'admin') . '"')
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -12,9 +12,7 @@ Feature: The maximum number of weeks/topics in a course can be configured
|
||||
| user | course | role |
|
||||
| manager1 | Acceptance test site | manager |
|
||||
And I log in as "admin"
|
||||
And I expand "Site administration" node
|
||||
And I expand "Courses" node
|
||||
And I follow "Course default settings"
|
||||
And I navigate to "Course default settings" node in "Site administration > Courses"
|
||||
|
||||
@javascript
|
||||
Scenario: The number of sections can be increased and the limits are applied to courses
|
||||
|
@ -63,7 +63,7 @@ class behat_navigation extends behat_base {
|
||||
$nodetextliteral = $this->getSession()->getSelectorsHandler()->xpathLiteral($text);
|
||||
$hasblocktree = "[contains(concat(' ', normalize-space(@class), ' '), ' block_tree ')]";
|
||||
$hasbranch = "[contains(concat(' ', normalize-space(@class), ' '), ' branch ')]";
|
||||
$hascollapsed = "li[contains(concat(' ', normalize-space(@class), ' '), ' collapsed ') or @data-exandable='1']";
|
||||
$hascollapsed = "li[contains(concat(' ', normalize-space(@class), ' '), ' collapsed ') or @data-expandable='1']";
|
||||
$notcollapsed = "li[not(contains(concat(' ', normalize-space(@class), ' '), ' collapsed '))]";
|
||||
$match = "[normalize-space(.)={$nodetextliteral}]";
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user