Proyectos de Subversion Moodle

Rev

Ir a la última revisión | | Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@mod @mod_quiz @quiz @quiz_statistics
2
Feature: Basic use of the Statistics report
3
  In order to see how my students are progressing
4
  As a teacher
5
  I need to see all their quiz responses
6
 
7
  Background:
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
      | student3 | Student   | 3        | student3@example.com |
14
    And the following "courses" exist:
15
      | fullname | shortname | category |
16
      | Course 1 | C1        | 0        |
17
    And the following "course enrolments" exist:
18
      | user     | course | role           |
19
      | teacher1 | C1     | editingteacher |
20
      | student1 | C1     | student        |
21
      | student2 | C1     | student        |
22
      | student3 | C1     | student        |
23
    And the following "question categories" exist:
24
      | contextlevel | reference | name           |
25
      | Course       | C1        | Test questions |
26
    And the following "questions" exist:
27
      | questioncategory | qtype     | name       | questiontext        |
28
      | Test questions   | truefalse | Question A | This is question 01 |
29
      | Test questions   | truefalse | Question B | This is question 02 |
30
      | Test questions   | truefalse | Question C | This is question 03 |
31
    And the following "activities" exist:
32
      | activity   | name   | course | idnumber |
33
      | quiz       | Quiz 1 | C1     | quiz1    |
34
    And quiz "Quiz 1" contains the following questions:
35
      | question   | page |
36
      | Question A | 1    |
37
      | Question B | 1    |
38
      | Question C | 2    |
39
 
40
  @javascript
41
  Scenario: Report works when there are no attempts
42
    When I am on the "Quiz 1" "mod_quiz > Statistics report" page logged in as teacher1
43
    Then I should see "No attempts have been made at this quiz, or all attempts have questions that need manual grading."
44
    And I should not see "Statistics for question positions"
45
    And "Show chart data" "link" should not exist
46
    And user "student1" has attempted "Quiz 1" with responses:
47
      | slot | response |
48
      |   1  | True     |
49
      |   2  | False    |
50
      |   3  | False    |
51
    And user "student2" has attempted "Quiz 1" with responses:
52
      | slot | response |
53
      |   1  | True     |
54
      |   2  | True     |
55
      |   3  | True     |
56
    And user "student3" has attempted "Quiz 1" with responses:
57
      | slot | response |
58
      |   1  | False    |
59
      |   2  | False    |
60
      |   3  | False    |
61
    And I am on the "Quiz 1" "mod_quiz > Statistics report" page logged in as teacher1
62
    And I press "Show report"
63
    And I should not see "No questions have been attempted yet"
64
    And "Show chart data" "link" should exist
65
 
66
    # Question A statistics breakdown.
67
    And "1" row "Question name" column of "questionstatistics" table should contain "Question A"
68
    And "1" row "Attempts" column of "questionstatistics" table should contain "3"
69
    And "1" row "Facility index" column of "questionstatistics" table should contain "66.67%"
70
    And "1" row "Standard deviation" column of "questionstatistics" table should contain "57.74%"
71
    And "1" row "Random guess score" column of "questionstatistics" table should contain "50.00%"
72
    And "1" row "Intended weight" column of "questionstatistics" table should contain "33.33%"
73
    And "1" row "Effective weight" column of "questionstatistics" table should contain "30.90%"
74
    And "1" row "Discrimination index" column of "questionstatistics" table should contain "50.00%"
75
 
76
    # Question B statistics breakdown.
77
    And "2" row "Question name" column of "questionstatistics" table should contain "Question B"
78
    And "2" row "Attempts" column of "questionstatistics" table should contain "3"
79
    And "2" row "Facility index" column of "questionstatistics" table should contain "33.33%"
80
    And "2" row "Standard deviation" column of "questionstatistics" table should contain "57.74%"
81
    And "2" row "Random guess score" column of "questionstatistics" table should contain "50.00%"
82
    And "2" row "Intended weight" column of "questionstatistics" table should contain "33.33%"
83
    And "2" row "Effective weight" column of "questionstatistics" table should contain "34.55%"
84
    And "2" row "Discrimination index" column of "questionstatistics" table should contain "86.60%"
85
 
86
    # Question C statistics breakdown.
87
    And "3" row "Question name" column of "questionstatistics" table should contain "Question C"
88
    And "3" row "Attempts" column of "questionstatistics" table should contain "3"
89
    And "3" row "Facility index" column of "questionstatistics" table should contain "33.33%"
90
    And "3" row "Standard deviation" column of "questionstatistics" table should contain "57.74%"
91
    And "3" row "Random guess score" column of "questionstatistics" table should contain "50.00%"
92
    And "3" row "Intended weight" column of "questionstatistics" table should contain "33.33%"
93
    And "3" row "Effective weight" column of "questionstatistics" table should contain "34.55%"
94
    And "3" row "Discrimination index" column of "questionstatistics" table should contain "86.60%"