AutorÃa | Ultima modificación | Ver Log |
@core @core_course @core_completionFeature: Edit completion settings of an activityIn order to edit completion settings without accidentally breaking user dataAs a teacherI need to edit the activity and use the unlock button if requiredBackground:Given the following "courses" exist:| fullname | shortname | enablecompletion || Course 1 | C1 | 1 |And the following "activities" exist:| activity | course | idnumber | intro | name | completion | completionview || page | C1 | p1 | x | TestPage | 2 | 1 |Scenario: Completion is not locked when the activity has not yet been viewedGiven I am on the TestPage "Page Activity editing" page logged in as adminWhen I expand all fieldsetsThen I should see "Completion conditions"And I should not see "Completion options locked"Scenario: Completion is locked after the activity has been viewedGiven I am on the TestPage "Page Activity" page logged in as adminWhen I am on the TestPage "Page Activity editing" pageAnd I expand all fieldsetsThen I should see "Completion options locked"@javascriptScenario: Pressing the unlock button allows the user to edit completion settingsGiven I am on the TestPage "Page Activity" page logged in as adminWhen I am on the TestPage "Page Activity editing" pageAnd I expand all fieldsetsAnd I press "Unlock completion settings"And I expand all fieldsetsThen I should see "Completion options unlocked"And I set the field "Students must manually mark the activity as done" to "1"And I press "Save and display"And I navigate to "Settings" in current page administrationAnd I expand all fieldsetsThen the field "Students must manually mark the activity as done" matches value "1"@javascriptScenario: Even when completion is locked, the user can still set the dateGiven I am on the TestPage "Page Activity" page logged in as adminAnd I am on the TestPage "Page Activity editing" pageAnd I expand all fieldsetsWhen I click on "id_completionexpected_enabled" "checkbox"And I set the field "id_completionexpected_year" to "2013"And I press "Save and display"And I navigate to "Settings" in current page administrationAnd I expand all fieldsetsThen the field "id_completionexpected_year" matches value "2013"