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_quiz
2
Feature: Attempt a quiz with multiple grades
3
  As a student
4
  In order to demonstrate multiple skills at once
5
  I need to be able to attempt quizzes with multiple grades setup
6
 
7
  Background:
8
    Given the following "users" exist:
9
      | username |
10
      | student  |
11
    And the following "courses" exist:
12
      | fullname | shortname |
13
      | Course 1 | C1        |
14
    And the following "course enrolments" exist:
15
      | user    | course | role    |
16
      | student | C1     | student |
1441 ariadna 17
    And the following "activities" exist:
18
      | activity   | name   | course | idnumber |
19
      | quiz       | Quiz 1 | C1     | quiz1    |
1 efrain 20
    And the following "question categories" exist:
1441 ariadna 21
      | contextlevel    | reference | name           |
22
      | Activity module | quiz1     | Test questions |
1 efrain 23
 
24
  @javascript
25
  Scenario: Navigation to, and display of, grading setup
26
    Given the following "questions" exist:
27
      | questioncategory | qtype     | name      | questiontext       |
28
      | Test questions   | truefalse | Reading   | Can you read this? |
29
      | Test questions   | truefalse | Listening | Can you hear this? |
30
    And the following "mod_quiz > grade items" exist:
31
      | quiz   | name                |
32
      | Quiz 1 | Grade for reading   |
33
      | Quiz 1 | Grade for listening |
34
      | Quiz 1 | Unused grade item   |
35
    And quiz "Quiz 1" contains the following questions:
36
      | question  | page | grade item           |
37
      | Reading   | 1    | Grade for reading    |
38
      | Listening | 1    | Grade for listening  |
39
 
40
    When I am on the "Quiz 1" "quiz activity" page logged in as "student"
41
    And I click on "Attempt quiz" "button"
42
    And I set the field "True" in the "Can you read this?" "question" to "1"
43
    And I set the field "False" in the "Can you hear this?" "question" to "1"
44
    And I press "Finish attempt ..."
45
    And I press "Submit all and finish"
46
    And I click on "Submit all and finish" "button" in the "Submit all your answers and finish?" "dialogue"
1441 ariadna 47
    Then I should see "1.00 out of 1.00 (100%)" in the "Grade for reading" "table_row"
48
    And I should see "0.00 out of 1.00 (0%)" in the "Grade for listening" "table_row"
1 efrain 49
    And I should not see "Unused grade item"
50
    And I should see "1.00/2.00" in the "Marks" "table_row"
51
    # Funny order because 'Grade' also appears in other rows.
52
    And I should see "Grade" in the "50.00 out of 100.00" "table_row"
53
    And I follow "Finish review"
54
    And I should not see "Unused grade item"
55
    And I should see "1.00/2.00" in the "Marks" "table_row"
56
    And I should see "Grade" in the "50.00 out of 100.00" "table_row"
1441 ariadna 57
 
58
  @javascript
59
  Scenario: The grade item should not show a percentage in sectional scoring if the question's max mark is 100
60
    Given the following "questions" exist:
61
      | questioncategory | qtype     | name      | questiontext       |
62
      | Test questions   | truefalse | Reading   | Can you read this? |
63
    And the following "mod_quiz > grade items" exist:
64
      | quiz   | name                |
65
      | Quiz 1 | Grade for reading   |
66
    And quiz "Quiz 1" contains the following questions:
67
      | question | page | grade item        |
68
      | Reading  | 1    | Grade for reading |
69
    When I am on the "Quiz 1" "mod_quiz > Edit" page logged in as "admin"
70
    And I set the max mark for question "Reading" to "100.0"
71
    And I am on the "Quiz 1" "quiz activity" page logged in as "student"
72
    And I click on "Attempt quiz" "button"
73
    And I set the field "True" in the "Can you read this?" "question" to "1"
74
    And I press "Finish attempt ..."
75
    And I press "Submit all and finish"
76
    And I click on "Submit all and finish" "button" in the "Submit all your answers and finish?" "dialogue"
77
    Then I should see "100.00 out of 100.00" in the "Grade for reading" "table_row"