Merge branch 'MDL-56511-master' of git://github.com/andrewnicols/moodle

This commit is contained in:
Andrew Nicols 2018-04-18 09:35:29 +08:00
commit 6979cf56e2
238 changed files with 7613 additions and 6572 deletions

View file

@ -139,7 +139,7 @@ class core_course_management_renderer extends plugin_renderer_base {
$listing = coursecat::get(0)->get_children();
$attributes = array(
'class' => 'ml',
'class' => 'ml-1',
'role' => 'tree',
'aria-labelledby' => 'category-listing-title'
);
@ -288,7 +288,7 @@ class core_course_management_renderer extends plugin_renderer_base {
$html .= html_writer::end_div();
if ($isexpanded) {
$html .= html_writer::start_tag('ul',
array('class' => 'ml', 'role' => 'group', 'id' => 'subcategoryof'.$category->id));
array('class' => 'ml-1', 'role' => 'group', 'id' => 'subcategoryof'.$category->id));
$catatlevel = \core_course\management\helper::get_expanded_categories($category->path);
$catatlevel[] = array_shift($selectedcategories);
$catatlevel = array_unique($catatlevel);
@ -528,7 +528,7 @@ class core_course_management_renderer extends plugin_renderer_base {
array('id' => 'course-listing-title', 'tabindex' => '0'));
$html .= $this->course_listing_actions($category, $course, $perpage);
$html .= $this->listing_pagination($category, $page, $perpage);
$html .= html_writer::start_tag('ul', array('class' => 'ml', 'role' => 'group'));
$html .= html_writer::start_tag('ul', array('class' => 'ml-1', 'role' => 'group'));
foreach ($category->get_courses($options) as $listitem) {
$html .= $this->course_listitem($category, $listitem, $courseid);
}
@ -1109,7 +1109,7 @@ class core_course_management_renderer extends plugin_renderer_base {
));
$html .= html_writer::tag('h3', get_string('courses'));
$html .= $this->search_pagination($totalcourses, $page, $perpage);
$html .= html_writer::start_tag('ul', array('class' => 'ml'));
$html .= html_writer::start_tag('ul', array('class' => 'ml-1'));
foreach ($courses as $listitem) {
$i++;
if ($i == $totalcourses) {

View file

@ -16,7 +16,7 @@ Feature: We can change the visibility of categories in the management interface.
And I log in as "admin"
And I go to the courses management page
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And I toggle visibility of category "CAT1" in management listing
# Redirect.
@ -38,7 +38,7 @@ Feature: We can change the visibility of categories in the management interface.
And I go to the courses management page
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And I toggle visibility of category "CAT1" in management listing
And a new page should not have loaded since I started watching
@ -57,28 +57,28 @@ Feature: We can change the visibility of categories in the management interface.
And I log in as "admin"
And I go to the courses management page
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should not see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should not see "Cat 2" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And I click on category "Cat 1" in the management interface
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And category in management listing should be visible "CAT2"
And I toggle visibility of category "CAT2" in management listing
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And category in management listing should be dimmed "CAT2"
And I toggle visibility of category "CAT2" in management listing
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And category in management listing should be visible "CAT2"
@ -94,8 +94,8 @@ Feature: We can change the visibility of categories in the management interface.
And I go to the courses management page
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should not see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should not see "Cat 2" in the "#category-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And I click to expand category "CAT1" in the management interface
And a new page should not have loaded since I started watching
@ -130,13 +130,13 @@ Feature: We can change the visibility of categories in the management interface.
And I click on category "Cat 1" in the management interface
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 4" in the "#category-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Course 2" in the "#course-listing ul.ml" "css_element"
And I should see "Course 3" in the "#course-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And I should see "Cat 4" in the "#category-listing ul" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
And I should see "Course 2" in the "#course-listing ul" "css_element"
And I should see "Course 3" in the "#course-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And category in management listing should be visible "CAT2"
And category in management listing should be visible "CAT3"
@ -207,13 +207,13 @@ Feature: We can change the visibility of categories in the management interface.
And a new page should have loaded since I started watching
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 4" in the "#category-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Course 2" in the "#course-listing ul.ml" "css_element"
And I should see "Course 3" in the "#course-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And I should see "Cat 4" in the "#category-listing ul" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
And I should see "Course 2" in the "#course-listing ul" "css_element"
And I should see "Course 3" in the "#course-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And category in management listing should be visible "CAT2"
And category in management listing should be visible "CAT3"
@ -223,7 +223,7 @@ Feature: We can change the visibility of categories in the management interface.
And course in management listing should be visible "C3"
And I toggle visibility of course "C2" in management listing
And a new page should not have loaded since I started watching
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And course in management listing should be visible "C1"
And course in management listing should be dimmed "C2"
And course in management listing should be visible "C3"

View file

@ -56,9 +56,9 @@ Feature: Test category management actions
And I log in as "admin"
And I go to the courses management page
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And I click on "delete" action for "Cat 2" in management category listing
# Redirect
And I should see "Delete category: Cat 2"
@ -67,9 +67,9 @@ Feature: Test category management actions
And I press "Cancel"
# Redirect
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And I click on "delete" action for "Cat 2" in management category listing
# Redirect
And I should see "Delete category: Cat 2"
@ -82,9 +82,9 @@ Feature: Test category management actions
And I press "Continue"
# Redirect
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should not see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should not see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And I click on "delete" action for "Cat 3" in management category listing
# Redirect
And I should see "Delete category: Cat 3"
@ -98,10 +98,10 @@ Feature: Test category management actions
And I press "Continue"
# Redirect
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should not see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should not see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should not see "Cat 2" in the "#category-listing ul" "css_element"
And I should not see "Cat 3" in the "#category-listing ul" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
Scenario: Test I can assign roles for a category through the management interface.
Given the following "categories" exist:
@ -222,9 +222,9 @@ Feature: Test category management actions
And I log in as "admin"
And I go to the courses management page
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And I select category "Cat 2" in the management interface
And I select category "Cat 3" in the management interface
And I set the field "menumovecategoriesto" to "Cat 1"
@ -253,9 +253,9 @@ Feature: Test category management actions
And I log in as "admin"
And I go to the courses management page
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 2" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 3" in the "#category-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Cat 2" in the "#category-listing ul" "css_element"
And I should see "Cat 3" in the "#category-listing ul" "css_element"
And the "movecategoriesto" "select" should be disabled
And the "resortcategoriesby" "select" should be disabled
And the "resortcoursesby" "select" should be disabled
@ -298,8 +298,8 @@ Feature: Test category management actions
And I click on category "Cat 3" in the management interface
#Redirect
And I should see the "Course categories and courses" management page
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Course 2" in the "#course-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
And I should see "Course 2" in the "#course-listing ul" "css_element"
And the "movecategoriesto" "select" should be disabled
And the "resortcategoriesby" "select" should be disabled
And the "resortcoursesby" "select" should be disabled

View file

@ -99,47 +99,47 @@ Feature: Course category management interface performs as expected
And I log in as "admin"
And I go to the courses management page
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click on "Cat 1" "link"
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click on "Cat 1-1" "link"
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click on "Cat 2" "link"
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
# This is similar to the above scenario except here we are going to use AJAX
# to load the categories.
@ -170,74 +170,74 @@ Feature: Course category management interface performs as expected
And I go to the courses management page
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT1" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT3" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT2" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT7" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT1" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT1" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
@javascript
Scenario Outline: Top level categories are displayed correctly when resorted
@ -746,51 +746,51 @@ Feature: Course category management interface performs as expected
And I go to the courses management page
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT2" in the management interface
And a new page should not have loaded since I started watching
And I click to expand category "CAT7" in the management interface
And a new page should not have loaded since I started watching
And I click to expand category "CAT9" in the management interface
And a new page should not have loaded since I started watching
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-2-1" in the "#course-category-listings ul" "css_element"
And I click on "Cat 1" category in the management category listing
And a new page should have loaded since I started watching
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-2-1" in the "#course-category-listings ul" "css_element"
And I click on "resortbyidnumber" action for "Cat 1" in management category listing
And a new page should have loaded since I started watching
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-2" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat 2-1-1-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 2-1-2-1" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat 1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 1-2" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-2" in the "#course-category-listings ul" "css_element"
And I should not see "Cat 2-1-1-1" in the "#course-category-listings ul" "css_element"
And I should see "Cat 2-1-2-1" in the "#course-category-listings ul" "css_element"
@javascript
Scenario: Test category expansion after deletion
@ -806,19 +806,19 @@ Feature: Course category management interface performs as expected
And I go to the courses management page
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat A (1)" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat B (2)" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat C (1-1)" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat D (2-1)" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat E (2-1-1)" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat A (1)" in the "#course-category-listings ul" "css_element"
And I should see "Cat B (2)" in the "#course-category-listings ul" "css_element"
And I should not see "Cat C (1-1)" in the "#course-category-listings ul" "css_element"
And I should not see "Cat D (2-1)" in the "#course-category-listings ul" "css_element"
And I should not see "Cat E (2-1-1)" in the "#course-category-listings ul" "css_element"
And I click to expand category "CAT1" in the management interface
And I should see "Cat C (1-1)" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat C (1-1)" in the "#course-category-listings ul" "css_element"
And a new page should not have loaded since I started watching
And I click to expand category "CAT2" in the management interface
And I should see "Cat D (2-1)" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat D (2-1)" in the "#course-category-listings ul" "css_element"
And a new page should not have loaded since I started watching
And I click to expand category "CAT4" in the management interface
And I should see "Cat E (2-1-1)" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat E (2-1-1)" in the "#course-category-listings ul" "css_element"
And a new page should not have loaded since I started watching
And I click on "delete" action for "Cat B (2)" in management category listing
And a new page should have loaded since I started watching
@ -833,5 +833,5 @@ Feature: Course category management interface performs as expected
And I press "Continue"
And a new page should have loaded since I started watching
And I should see the "Course categories and courses" management page
And I should see "Cat A (1)" in the "#course-category-listings ul.ml" "css_element"
And I should not see "Cat B (2)" in the "#course-category-listings ul.ml" "css_element"
And I should see "Cat A (1)" in the "#course-category-listings ul" "css_element"
And I should not see "Cat B (2)" in the "#course-category-listings ul" "css_element"

View file

@ -19,8 +19,8 @@ Feature: We can change the visibility of courses in the management interface.
And I click on category "Cat 1" in the management interface
# Redirect.
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And course in management listing should be visible "C1"
And I toggle visibility of course "C1" in management listing
@ -68,8 +68,8 @@ Feature: We can change the visibility of courses in the management interface.
And a new page should have loaded since I started watching
And I start watching to see if a new page loads
And I should see the "Course categories and courses" management page
And I should see "Cat 1" in the "#category-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Cat 1" in the "#category-listing ul" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
And category in management listing should be visible "CAT1"
And course in management listing should be visible "C1"
And I toggle visibility of course "C1" in management listing
@ -98,7 +98,7 @@ Feature: We can change the visibility of courses in the management interface.
And I click on "Courses" "link" in the ".view-mode-selector" "css_element"
And a new page should have loaded since I started watching
And I start watching to see if a new page loads
And I should see "Course 1" in the "#course-listing ul.ml" "css_element"
And I should see "Course 1" in the "#course-listing ul" "css_element"
And I toggle visibility of course "C1" in management listing
And a new page should not have loaded since I started watching
And course in management listing should be dimmed "C1"

View file

@ -20,7 +20,7 @@ Feature: Courses can be searched for and moved in bulk.
Scenario: Search courses finds correct results
Given I log in as "admin"
And I go to the courses management page
When I set the field "Search courses" to "Biology"
When I set the field "coursesearchbox" to "Biology"
And I press "Go"
Then I should see "Biology Y1"
And I should see "Biology Y2"
@ -31,7 +31,7 @@ Feature: Courses can be searched for and moved in bulk.
Scenario: Search courses and move results in bulk
Given I log in as "admin"
And I go to the courses management page
And I set the field "Search courses" to "Biology"
And I set the field "coursesearchbox" to "Biology"
And I press "Go"
When I select course "Biology Y1" in the management interface
And I select course "Biology Y2" in the management interface

View file

@ -23,12 +23,12 @@ Feature: Browse course list and return back from enrolment page
And I follow "Miscellaneous"
And I follow "Sample course"
And I press "Continue"
Then I should see "Courses" in the ".breadcrumb-nav" "css_element"
And I click on "Courses" "link" in the ".breadcrumb-nav" "css_element"
Then I should see "Courses" in the ".breadcrumb" "css_element"
And I click on "Courses" "link" in the ".breadcrumb" "css_element"
And I follow "Sample category"
And I am on "Course 1" course homepage
And I press "Continue"
And I should see "Sample category" in the ".breadcrumb-nav" "css_element"
And I should see "Sample category" in the ".breadcrumb" "css_element"
@javascript
Scenario: A user can return to the previous page from enrolment page by clicking navigation links
@ -47,7 +47,7 @@ Feature: Browse course list and return back from enrolment page
And I expand "Sample category" node
And I follow "Course 1"
And I press "Continue"
Then I should see "Edit profile" in the ".breadcrumb-nav" "css_element"
Then I should see "Edit profile" in the ".breadcrumb" "css_element"
Scenario: User can return to the choice activity from enrolment page
Given the following "roles" exist:
@ -72,4 +72,4 @@ Feature: Browse course list and return back from enrolment page
And I should see "Sorry, only enrolled users are allowed to make choices."
And I press "Enrol me in this course"
And I press "Continue"
Then I should see "Test choice" in the ".breadcrumb-nav" "css_element"
Then I should see "Test choice" in the ".breadcrumb" "css_element"