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: Submissions are unlocked when a new attempt is given
3
  In order to allow students to reattempt a locked submission
4
  As a teacher
5
  I need to use quick grading to grant a new submission
6
 
7
  Background:
8
    Given the following "courses" exist:
9
      | fullname | shortname | category | groupmode |
10
      | Course 1 | C1 | 0 | 1 |
11
    And the following "users" exist:
12
      | username | firstname | lastname | email |
13
      | teacher1 | Teacher | 1 | teacher1@example.com |
14
      | student1 | Student | 1 | student1@example.com |
15
    And the following "course enrolments" exist:
16
      | user | course | role |
17
      | teacher1 | C1 | editingteacher |
18
      | student1 | C1 | student |
19
 
20
  @javascript
21
  Scenario: A locked submission should unlock when a new attempt is automatically given.
22
    Given the following "activity" exists:
23
      | activity                             | assign                |
24
      | course                               | C1                    |
25
      | name                                 | Test assignment name  |
26
      | submissiondrafts                     | 0                     |
27
      | assignsubmission_onlinetext_enabled  | 1                     |
1441 ariadna 28
      | maxattempts                          | -1                    |
1 efrain 29
      | attemptreopenmethod                  | untilpass             |
30
      | gradepass                            | 50                    |
31
      | submissiondrafts                     | 0                     |
32
    And the following "mod_assign > submissions" exist:
33
      | assign                | user      | onlinetext                   |
34
      | Test assignment name  | student1  | I'm the student1 submission  |
35
 
36
    And I am on the "Test assignment name" Activity page logged in as teacher1
1441 ariadna 37
    And I navigate to "Submissions" in current page administration
38
    And I change window size to "large"
1 efrain 39
    And I open the action menu in "Student 1" "table_row"
1441 ariadna 40
    And I change window size to "medium"
1 efrain 41
    And I follow "Prevent submission changes"
42
    And I should see "Submission changes not allowed"
43
    And I click on "Quick grading" "checkbox"
44
    And I set the field "User grade" to "49.0"
1441 ariadna 45
    And I click on "Save" "button" in the "sticky-footer" "region"
1 efrain 46
    And I should see "The grade changes were saved"
47
    And I press "Continue"
48
    Then I should see "Reopened"
49
    And I should not see "Submission changes not allowed"
50
 
51
  @javascript
52
  Scenario: A locked submission should unlock when a new attempt is manually given.
53
    Given the following "activity" exists:
54
      | activity                            | assign                  |
55
      | course                              | C1                      |
56
      | name                                | Test assignment name    |
57
      | submissiondrafts                    | 0                       |
58
      | assignsubmission_onlinetext_enabled | 1                       |
1441 ariadna 59
      | maxattempts                         | -1                      |
1 efrain 60
      | attemptreopenmethod                 | manual                  |
61
    And the following "mod_assign > submissions" exist:
62
      | assign                | user      | onlinetext                   |
63
      | Test assignment name  | student1  | I'm the student1 submission  |
64
 
65
    And I am on the "Test assignment name" Activity page logged in as teacher1
1441 ariadna 66
    And I navigate to "Submissions" in current page administration
67
    And I change window size to "large"
1 efrain 68
    When I open the action menu in "Student 1" "table_row"
1441 ariadna 69
    And I change window size to "medium"
1 efrain 70
    And I follow "Prevent submission changes"
71
    Then I should see "Submission changes not allowed"
1441 ariadna 72
    And I change window size to "large"
1 efrain 73
    And I open the action menu in "Student 1" "table_row"
1441 ariadna 74
    And I change window size to "medium"
1 efrain 75
    And I follow "Allow another attempt"
76
    And I should see "Reopened"
77
    And I should not see "Submission changes not allowed"