Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@mod @mod_choice
2
Feature: Update a choice activity removing options
3
  In order to remove incorrect or unwanted options
4
  As a teacher
5
  I need to update the choice activity
6
 
7
  Scenario: Update a choice activity that has student responses.
8
    Given the following "users" exist:
9
      | username | firstname | lastname | email |
10
      | teacher1 | Teacher | 1 | teacher1@example.com |
11
      | student1 | Student | 1 | student1@example.com |
12
      | student2 | Student | 2 | student2@example.com |
13
    And the following "courses" exist:
14
      | fullname | shortname | category |
15
      | Course 1 | C1 | 0 |
16
    And the following "course enrolments" exist:
17
      | user | course | role |
18
      | teacher1 | C1 | editingteacher |
19
      | student1 | C1 | student |
20
      | student2 | C1 | student |
21
    And the following "activities" exist:
22
      | activity | name        | intro              | course | idnumber | option                       | section |
23
      | choice   | Choice name | Choice Description | C1     | choice1  | Option 1, Option 2, Option 3 | 1       |
24
    And I log in as "student1"
25
    And I am on "Course 1" course homepage
26
    And I choose "Option 3" from "Choice name" choice activity
27
    And I should see "Your selection: Option 3"
28
    And I should see "Your choice has been saved"
29
    And I log out
30
    And I log in as "student2"
31
    And I am on "Course 1" course homepage
32
    And I choose "Option 2" from "Choice name" choice activity
33
    And I should see "Your selection: Option 2"
34
    And I should see "Your choice has been saved"
35
    And I log out
36
    When I log in as "teacher1"
37
    And I am on "Course 1" course homepage
38
    And I click on "Choice name" "link" in the "region-main" "region"
39
    And I navigate to "Settings" in current page administration
40
    And I set the field "option[2]" to ""
41
    And I press "Save and display"
42
    Then I navigate to "Responses" in current page administration
43
    And I should see "1" in the "Number of responses" "table_row"