Rev 1 | AutorÃa | Comparar con el anterior | Ultima modificación | Ver Log |
@format @format_topicsFeature: Sections can be highlightedIn order to mark sectionsAs a teacherI need to highlight and unhighlight sectionsBackground:Given the following "users" exist:| username | firstname | lastname | email || teacher1 | Teacher | 1 | teacher1@example.com |And the following "course" exists:| fullname | Course 1 || shortname | C1 || format | topics || coursedisplay | 0 || numsections | 5 || initsections | 1 |And the following "activities" exist:| activity | name | intro | course | idnumber | section || assign | Test assignment name | Test assignment description | C1 | assign1 | 0 || book | Test book name | Test book description | C1 | book1 | 1 || lesson | Test lesson name | Test lesson description | C1 | lesson1 | 4 || choice | Test choice name | Test choice description | C1 | choice1 | 5 |And the following "course enrolments" exist:| user | course | role || teacher1 | C1 | editingteacher |And I log in as "teacher1"And I am on "Course 1" course homepage with editing mode on@javascriptScenario: Highlight a sectionWhen I open section "2" edit menuAnd I click on "Highlight" "link" in the "Section 2" "section"Then I should see "Highlighted" in the "Section 2" "section"@javascriptScenario: Highlight a section when another section is already highlightedGiven I open section "3" edit menuAnd I click on "Highlight" "link" in the "Section 3" "section"And I should see "Highlighted" in the "Section 3" "section"When I open section "2" edit menuAnd I click on "Highlight" "link" in the "Section 2" "section"Then I should see "Highlighted" in the "Section 2" "section"And I should not see "Highlighted" in the "Section 3" "section"@javascriptScenario: Unhighlight a sectionGiven I open section "3" edit menuAnd I click on "Highlight" "link" in the "Section 3" "section"And I should see "Highlighted" in the "Section 3" "section"When I open section "3" edit menuAnd I click on "Unhighlight" "link" in the "Section 3" "section"Then I should not see "Highlighted" in the "Section 3" "section"Scenario: Highlight and unhighlight a section can be done without ajax# Without javascript hidden elements cannot be detected with a simple I should see step.Given ".section.current" "css_element" should not existWhen I click on "Highlight" "link" in the "Section 2" "core_courseformat > Section actions menu"Then ".section.current[data-number='2']" "css_element" should existAnd I click on "Unhighlight" "link" in the "Section 2" "core_courseformat > Section actions menu"And ".section.current" "css_element" should not exist