Proyectos de Subversion Moodle

Rev

Rev 1 | | Comparar con el anterior | Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@mod @mod_assign
2
Feature: Assign reset
3
  In order to reuse past Assignss
4
  As a teacher
5
  I need to remove all previous data.
6
 
7
  Background:
8
    Given the following "users" exist:
9
      | username | firstname | lastname | email |
10
      | teacher1 | Tina | Teacher1 | teacher1@example.com |
11
      | student1 | Sam1 | Student1 | student1@example.com |
12
      | student2 | Sam2 | Student2 | 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 "groups" exist:
22
      | name    | course | idnumber |
23
      | Group 1 | C1     | G1       |
24
      | Group 2 | C1     | G2       |
25
    And the following "activity" exists:
26
      | activity                                      | assign                  |
27
      | course                                        | C1                      |
28
      | name                                          | Test assignment name    |
29
      | intro                                         | Submit your online text |
30
      | assignsubmission_onlinetext_enabled           | 1                       |
31
      | assignsubmission_onlinetext_wordlimit_enabled | 1                       |
32
      | assignsubmission_onlinetext_wordlimit         | 10                      |
33
      | assignsubmission_file_enabled                 | 0                       |
34
      | submissiondrafts                              | 0                       |
35
 
36
  Scenario: Use course reset to clear all attempt data
37
    Given the following "mod_assign > submissions" exist:
38
      | assign                | user      | onlinetext                       |
39
      | Test assignment name  | student1  | I'm the student first submission |
40
    And I am on the "Test assignment name" Activity page logged in as student1
41
    And I should see "Submitted for grading"
42
    And I should see "I'm the student first submission"
43
    And I should see "Not graded"
44
    And I log out
45
 
46
    And I am on the "Test assignment name" Activity page logged in as teacher1
1441 ariadna 47
    And I navigate to "Submissions" in current page administration
1 efrain 48
    And I should see "Submitted for grading"
49
    When I am on the "Course 1" "reset" page
50
    And I set the following fields to these values:
1441 ariadna 51
        | All submissions | 1  |
1 efrain 52
    And I press "Reset course"
53
    And I press "Continue"
54
    And I am on the "Test assignment name" Activity page
1441 ariadna 55
    And I navigate to "Submissions" in current page administration
1 efrain 56
    Then I should not see "Submitted for grading"
57
 
58
  @javascript
1441 ariadna 59
  Scenario: Use course reset to remove user overrides
1 efrain 60
    And I am on the "Test assignment name" Activity page logged in as teacher1
61
    And I navigate to "Overrides" in current page administration
62
    And I press "Add user override"
63
    And I set the following fields to these values:
64
        | Override user    | Student1  |
65
        | id_duedate_enabled | 1 |
66
        | duedate[day]       | 1 |
67
        | duedate[month]     | January |
68
        | duedate[year]      | 2020 |
69
        | duedate[hour]      | 08 |
70
        | duedate[minute]    | 00 |
71
    And I press "Save"
72
    And I should see "Sam1 Student1"
73
    When I am on the "Course 1" "reset" page
1441 ariadna 74
    And I press "Deselect all"
1 efrain 75
    And I set the following fields to these values:
1441 ariadna 76
        | All user overrides | 1  |
1 efrain 77
    And I press "Reset course"
1441 ariadna 78
    And I click on "Reset course" "button" in the "Reset course?" "dialogue"
1 efrain 79
    And I press "Continue"
80
    And I am on "Course 1" course homepage
81
    And I click on "Test assignment name" "link" in the "region-main" "region"
82
    And I navigate to "Overrides" in current page administration
83
    Then I should not see "Sam1 Student1"
84
 
85
  Scenario: Use course reset to remove group overrides.
86
    When I am on the "Test assignment name" Activity page logged in as teacher1
87
    And I navigate to "Overrides" in current page administration
88
    And I select "Group overrides" from the "jump" singleselect
89
    And I press "Add group override"
90
    And I set the following fields to these values:
91
        | Override group   | Group 1  |
92
        | id_duedate_enabled | 1 |
93
        | duedate[day]       | 1 |
94
        | duedate[month]     | January |
95
        | duedate[year]      | 2020 |
96
        | duedate[hour]      | 08 |
97
        | duedate[minute]    | 00 |
98
    And I press "Save"
99
    And I should see "Group 1"
100
    And I am on the "Course 1" "reset" page
101
    And I set the following fields to these values:
1441 ariadna 102
        | All group overrides | 1  |
1 efrain 103
    And I press "Reset course"
104
    And I press "Continue"
105
    And I am on the "Test assignment name" Activity page
106
    And I navigate to "Overrides" in current page administration
107
    And I select "Group overrides" from the "jump" singleselect
108
    Then I should not see "Group 1"
109
 
110
  Scenario: Use course reset to reset blind marking assignment.
111
    When I am on the "Test assignment name" Activity page logged in as teacher1
112
    And I navigate to "Settings" in current page administration
113
    And I set the following fields to these values:
114
        | blindmarking | 1 |
115
    And I press "Save"
116
    When I am on the "Test assignment name" Activity page
1441 ariadna 117
    And I navigate to "Submissions" in current page administration
118
    And I choose the "Reveal student identities" item in the "Actions" action menu
1 efrain 119
    And I press "Continue"
120
    And I should see "Sam1 Student1"
121
    When I am on the "Course 1" "reset" page
122
    And I set the following fields to these values:
1441 ariadna 123
        | All submissions | 1 |
1 efrain 124
    And I press "Reset course"
125
    And I press "Continue"
126
    And I am on the "Test assignment name" Activity page
1441 ariadna 127
    And I navigate to "Submissions" in current page administration
1 efrain 128
    Then I should not see "Sam1 Student1"