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
@report @report_outline
2
Feature: View an outline report
3
  In order to ensure the outline report works as expected
4
  As a teacher
5
  I need to log in as a teacher and view the outline report
6
 
7
  Background:
8
    Given the following "courses" exist:
1441 ariadna 9
      | fullname | shortname | format | numsections |
10
      | Course 1 | C1        | topics | 1           |
1 efrain 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
      | student2 | Student | 2 | student2@example.com |
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                      | course | idnumber |
23
      | forum      | Forum name                | C1     | forum1   |
24
      | book       | Book name                 | C1     | book1    |
25
    When I am on the "Course 1" course page logged in as admin
26
 
27
  Scenario: View the outline report when only the standard log reader is enabled
28
    Given I navigate to "Plugins > Logging > Manage log stores" in site administration
29
    And "Disable" "link" should exist in the "Standard log" "table_row"
30
    And I am on the "Course 1" course page logged in as student1
31
    And I follow "Forum name"
32
    And I am on "Course 1" course homepage
33
    And I follow "Book name"
34
    And I am on the "Course 1" course page logged in as student2
35
    And I follow "Book name"
36
    And I am on the "Course 1" course page logged in as admin
37
    When I navigate to "Reports" in current page administration
38
    And I click on "Activity report" "link"
39
    Then I should see "2 views by 2 users" in the "Book name" "table_row"
40
    And I should see "1 views by 1 users" in the "Forum name" "table_row"
41
 
42
  Scenario: View the outline report when no log reader is enabled
43
    Given I navigate to "Plugins > Logging > Manage log stores" in site administration
44
    And I click on "Disable" "link" in the "Standard log" "table_row"
45
    And I am on "Course 1" course homepage
46
    When I navigate to "Reports" in current page administration
47
    And I click on "Activity report" "link"
48
    Then I should see "No log reader enabled"
49
 
50
  Scenario: Multiple views from a single user are identified as not distinct
51
    Given I am on the "Course 1" course page logged in as student1
52
    And I follow "Forum name"
53
    And I am on "Course 1" course homepage
54
    And I follow "Forum name"
55
    And I am on "Course 1" course homepage
56
    And I follow "Forum name"
57
    And I am on site homepage
58
    When I am on the "Course 1" course page logged in as teacher1
59
    And I navigate to "Reports" in current page administration
60
    And I click on "Activity report" "link"
61
    Then I should see "3 views by 1 users" in the "Forum name" "table_row"
62
    And I should see "-" in the "Book name" "table_row"
63
 
64
  Scenario: Multiple views from multiple users are identified as not distinct
65
    Given I am on the "Course 1" course page logged in as student1
66
    And I follow "Forum name"
67
    And I am on "Course 1" course homepage
68
    And I follow "Forum name"
69
    And I am on "Course 1" course homepage
70
    And I follow "Forum name"
71
    And I am on site homepage
72
    Given I am on the "Course 1" course page logged in as student2
73
    And I follow "Forum name"
74
    And I am on "Course 1" course homepage
75
    And I follow "Forum name"
76
    And I am on "Course 1" course homepage
77
    And I follow "Forum name"
78
    And I am on site homepage
79
    When I am on the "Course 1" course page logged in as teacher1
80
    And I navigate to "Reports" in current page administration
81
    And I click on "Activity report" "link"
82
    Then I should see "6 views by 2 users" in the "Forum name" "table_row"
83
    And I should see "-" in the "Book name" "table_row"
84
 
85
  Scenario: No views from any users
86
    When I am on the "Course 1" course page logged in as teacher1
87
    And I navigate to "Reports" in current page administration
88
    And I click on "Activity report" "link"
89
    Then I should see "-" in the "Forum name" "table_row"
90
    And I should see "-" in the "Book name" "table_row"
1441 ariadna 91
 
92
  Scenario: The outline report can represent courses with subsections
93
    Given the following "activities" exist:
94
      | activity | name      | course | section | visible | assignsubmission_onlinetext_enabled | assignsubmission_file_enabled |
95
      | assign   | Activity1 | C1     | 1       | 1       | 1                                   | 0                             |
96
    And the following "activities" exist:
97
      | activity   | name        | course | section | visible |
98
      | subsection | Subsection1 | C1     | 1       | 1       |
99
    And the following "activities" exist:
100
      | activity | name           | course | section | visible | assignsubmission_onlinetext_enabled | assignsubmission_file_enabled |
101
      | assign   | Subactivity1.1 | C1     | 2       | 1       | 1                                   | 0                             |
102
      | assign   | Subactivity1.2 | C1     | 2       | 0       | 1                                   | 0                             |
103
      | assign   | Activity2      | C1     | 1       | 1       | 1                                   | 0                             |
104
    When I am on the "Course 1" course page logged in as teacher1
105
    And I navigate to "Reports" in current page administration
106
    And I click on "Activity report" "link"
107
    Then "Subactivity1.1" "table_row" should appear after "Activity1" "table_row"
108
    And "Subactivity1.2" "table_row" should appear after "Subactivity1.1" "table_row"
109
    And "Activity2" "table_row" should appear after "Subactivity1.2" "table_row"
110
    And I navigate to "Participants" in current page administration
111
    And I click on "Student 1" "link"
112
    And I click on "Outline report" "link"
113
    And "Subactivity1.1" "table_row" should appear after "Activity1" "table_row"
114
    And I should not see "Subactivity1.2" in the "page-content" "region"
115
    And "Activity2" "table_row" should appear after "Subactivity1.1" "table_row"