[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/group/tests/behat/ -> id_uniqueness.feature (source)

   1  @core @core_group
   2  Feature: Uniqueness of Group ID number
   3    In order to create unique groups and groupings
   4    As a teacher
   5    I need to create groups with unique identificators
   6  
   7    Background:
   8      Given the following "courses" exist:
   9        | fullname | shortname | category |
  10        | Course 1 | C1 | 0 |
  11      And the following "users" exist:
  12        | username | firstname | lastname | email |
  13        | teacher1 | Teacher | 1 | teacher1@example.com |
  14      And the following "course enrolments" exist:
  15        | user | course | role |
  16        | teacher1 | C1 | editingteacher |
  17      And I log in as "teacher1"
  18      And I follow "Course 1"
  19      And I expand "Users" node
  20      And I follow "Groups"
  21  
  22    @javascript
  23    Scenario: Group ID number uniqueness
  24      Given I press "Create group"
  25      And I set the following fields to these values:
  26        | Group name | Group 1 |
  27        | Group ID number | G1 |
  28      And I press "Save changes"
  29      When I press "Create group"
  30      And I set the following fields to these values:
  31        | Group name | Group 2 |
  32        | Group ID number | G1 |
  33      And I press "Save changes"
  34      Then I should see "This ID number is already taken"
  35      And I set the following fields to these values:
  36        | Group ID number | G2 |
  37      And I press "Save changes"
  38      And I set the field "groups" to "Group 1 (0)"
  39      And I press "Edit group settings"
  40      And I set the following fields to these values:
  41        | Group ID number | G2 |
  42      And I press "Save changes"
  43      And I should see "This ID number is already taken"
  44      And I press "Cancel"
  45  
  46    @javascript
  47    Scenario: Grouping ID number uniqueness
  48      Given I follow "Groupings"
  49      And I press "Create grouping"
  50      And I set the following fields to these values:
  51        | Grouping name | Grouping 1 |
  52        | Grouping ID number | GG1 |
  53      And I press "Save changes"
  54      When I press "Create grouping"
  55      And I set the following fields to these values:
  56        | Grouping name | Grouping 2 |
  57        | Grouping ID number | GG1 |
  58      And I press "Save changes"
  59      Then I should see "This ID number is already taken"
  60      And I set the following fields to these values:
  61        | Grouping ID number | GG2 |
  62      And I press "Save changes"
  63      And I click on "Edit" "link" in the "Grouping 1" "table_row"
  64      And I set the following fields to these values:
  65        | Grouping ID number | GG2 |
  66      And I press "Save changes"
  67      And I should see "This ID number is already taken"
  68      And I press "Cancel"


Generated: Thu Aug 11 10:00:09 2016 Cross-referenced by PHPXref 0.7.1