Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@block @block_myoverview @javascript
2
Feature: Course overview block show users their progress on courses
3
  In order to enable the my overview block in a course
4
  As a student
5
  I can see the progress percentage of the courses I am enrolled in
6
 
7
  Background:
8
    Given the following "users" exist:
9
      | username | firstname | lastname | email | idnumber |
10
      | teacher1 | Teacher | 1 | teacher1@example.com | T1 |
11
      | student1 | Student | 1 | student1@example.com | S1 |
12
    And the following "courses" exist:
13
      | fullname | shortname | category | enablecompletion | startdate     | enddate       |
14
      | Course 1 | C1        | 0        | 1                | ##yesterday## | ##tomorrow##  |
15
    And the following "activities" exist:
16
      | activity | course | idnumber | name          | intro                   | timeopen      | timeclose     |
17
      | choice   | C1     | choice1  | Test choice 1 | Test choice description | ##yesterday## | ##tomorrow##  |
18
    And the following "course enrolments" exist:
19
      | user | course | role            |
20
      | teacher1 | C1 | editingteacher  |
21
      | student1 | C1 | student         |
22
 
23
  Scenario: Course progress percentage should not be displayed if completion is not enabled
24
    Given I am on the "My courses" page logged in as "student1"
25
    And I click on "All" "button" in the "Course overview" "block"
26
    When I click on "All" "link" in the "Course overview" "block"
27
    Then I should not see "0%" in the "Course overview" "block"
28
 
29
  Scenario: User complete activity and verify his progress
30
    Given I am on the "Test choice 1" "choice activity" page logged in as teacher1
31
    And I navigate to "Settings" in current page administration
32
    And I set the following fields to these values:
33
      | Add requirements         | 1                  |
34
      | id_completionview   | 1                                                 |
35
    And I press "Save and return to course"
36
    And I log out
37
    When I am on the "My courses" page logged in as "student1"
38
    And I click on "All" "button" in the "Course overview" "block"
39
    Then I should see "Course 1" in the "Course overview" "block"
40
    And I should see "0%" in the "Course overview" "block"
41
    And I am on the "Test choice 1" "choice activity" page
42
    And I am on the "My courses" page
43
    And I click on "All" "button" in the "Course overview" "block"
44
    And I should see "100%" in the "Course overview" "block"