Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@tool @tool_generator @_file_upload
2
Feature: Create testing scenarios using generators
3
  In order to execute manual tests
4
  As a developer
5
  I need to use a feature file to execute generators into the current instance
6
 
7
  @javascript
8
  Scenario: Create a testing scenario with a course enrolled users and activities
9
    Given I log in as "admin"
10
    And I navigate to "Development > Create testing scenarios" in site administration
11
    When I upload "admin/tool/generator/tests/fixtures/testscenario/scenario.feature" file to "Feature file" filemanager
12
    And I press "Import"
13
    And I should see "Scenario: Create course content"
14
    Then I am on the "C1" "Course" page
15
    And I should see "Activity sample 1" in the "Section 1" "section"
16
    And I should see "Activity sample 2" in the "Section 1" "section"
17
    And I navigate to course participants
18
    And I should see "Teacher Test1"
19
    And I should see "Student Test1"
20
    And I should see "Student Test2"
21
    And I should see "Student Test3"
22
    And I should see "Student Test4"
23
    And I should see "Student Test5"
24
 
25
  @javascript
26
  Scenario: Prevent creating a testing scenario with no steps to execute
27
    Given I log in as "admin"
28
    And I navigate to "Development > Create testing scenarios" in site administration
29
    When I upload "admin/tool/generator/tests/fixtures/testscenario/scenario_wrongempty.feature" file to "Feature file" filemanager
30
    And I press "Import"
31
    Then I should see "There are no steps to execute in the file."
32
 
33
  @javascript
34
  Scenario: Prevent creating a testing scenario with only background steps to execute
35
    Given I log in as "admin"
36
    And I navigate to "Development > Create testing scenarios" in site administration
37
    When I upload "admin/tool/generator/tests/fixtures/testscenario/scenario_wrongonlybackground.feature" file to "Feature file" filemanager
38
    And I press "Import"
39
    Then I should see "There are no steps to execute in the file."
40
 
41
  @javascript
42
  Scenario: Prevent creating a testing scenario with a wrong file format
43
    Given I log in as "admin"
44
    And I navigate to "Development > Create testing scenarios" in site administration
45
    When I upload "admin/tool/generator/tests/fixtures/testscenario/scenario_wrongformat.feature" file to "Feature file" filemanager
46
    And I press "Import"
47
    Then I should see "Error parsing feature file"
48
 
49
  @javascript
50
  Scenario: Prevent creating a testing scenario with non generator steps
51
    Given I log in as "admin"
52
    And I navigate to "Development > Create testing scenarios" in site administration
53
    When I upload "admin/tool/generator/tests/fixtures/testscenario/scenario_wrongstep.feature" file to "Feature file" filemanager
54
    And I press "Import"
55
    Then I should see "The file format is not valid or contains invalid steps"
56
 
57
  @javascript
58
  Scenario: Prevent creating a testing scenario from a scenario outline
59
    Given I log in as "admin"
60
    And I navigate to "Development > Create testing scenarios" in site administration
61
    When I upload "admin/tool/generator/tests/fixtures/testscenario/scenario_wrongoutline.feature" file to "Feature file" filemanager
62
    And I press "Import"
63
    Then I should see "Scenario outlines are not supported"
64
    Then I should see "There are no steps to execute in the file"