Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@core @core_course
2
Feature: The maximum number of weeks/topics in a course can be configured
3
  In order to set boundaries to courses size
4
  As a manager
5
  I need to limit the number of weeks/topics a course can have
6
 
7
  Background:
8
    Given the following "users" exist:
9
      | username | firstname | lastname | email |
10
      | manager1 | Manager | 1 | manager1@example.com |
11
    And the following "system role assigns" exist:
12
      | user | course | role |
13
      | manager1 | Acceptance test site | manager |
14
    And I log in as "admin"
15
    And I navigate to "Courses > Default settings > Course default settings" in site administration
16
 
17
  @javascript
18
  Scenario: The number of sections can be increased and the limits are applied to courses
19
    Given I set the field "Maximum number of sections" to "100"
20
    When I press "Save changes"
21
    And the field "Maximum number of sections" matches value "100"
22
    And the "Number of sections" select box should contain "100"
23
    And I log out
24
    And I log in as "manager1"
25
    And the following "course" exists:
26
      | fullname     | New course fullname  |
27
      | shortname    | New course shortname |
28
      | format       | topics               |
29
      | numsections  | 90                   |
30
      | initsections | 1                    |
31
    And I am on the "New course fullname" course page
32
    Then I should see "Section 90"
33
 
34
  @javascript
35
  Scenario: The number of sections can be reduced to 0 and the limits are applied to courses
36
    Given I set the field "Maximum number of sections" to "0"
37
    When I press "Save changes"
38
    And the field "Maximum number of sections" matches value "0"
39
    And the "Number of sections" select box should contain "0"
40
    And the "Number of sections" select box should not contain "52"
41
    And I log out
42
    And I log in as "manager1"
43
    And the following "course" exists:
44
      | fullname     | New course fullname  |
45
      | shortname    | New course shortname |
46
      | format       | topics               |
47
      | numsections  | 0                    |
48
      | initsections | 1                    |
49
    And I am on the "New course fullname" course page
50
    Then I should not see "Section 1"