-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add integration test for hostgroup rules
The integration test should cover all use cases in the Automember > Hostgroup rules page. Signed-off-by: Carla Martinez <[email protected]>
- Loading branch information
Showing
1 changed file
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
Feature: Automember > Host group rules | ||
Create and delete automember host group rules. Change default host group rule. | ||
|
||
Background: | ||
Given I am logged in as "Administrator" | ||
Given I am on "host-group-rules" page | ||
|
||
# Prep: Create a new host group to work with | ||
Scenario: Create a new host group to work with | ||
Given I am on "host-groups" page | ||
When I click on "Add" button | ||
* I type in the field "Group name" text "my_automember_hostgroup" | ||
When in the modal dialog I click on "Add" button | ||
* I should see "success" alert with text "New host group added" | ||
Then I should see "my_automember_hostgroup" entry in the data table | ||
|
||
# Host group rules operations | ||
Scenario: Add a new automember host group rule | ||
Given I am on "host-group-rules" page | ||
When I click on "Add" button | ||
* I click in the "Automember" selector field | ||
* I select "my_automember_hostgroup" option in the "Automember" selector | ||
* in the modal dialog I click on "Add" button | ||
* I should see "success" alert with text "Entry successfully added" | ||
Then I should see "my_automember_hostgroup" entry in the data table | ||
|
||
Scenario: Add another automember host group rule | ||
Given I am on "host-group-rules" page | ||
When I click on "Add" button | ||
* I click in the "Automember" selector field | ||
* I select "ipaservers" option in the "Automember" selector | ||
* in the modal dialog I click on "Add" button | ||
* I should see "success" alert with text "Entry successfully added" | ||
Then I should see "ipaservers" entry in the data table | ||
|
||
Scenario: Delete an automember host group rule | ||
Given I should see "my_automember_hostgroup" entry in the data table | ||
Then I select entry "my_automember_hostgroup" in the data table | ||
When I click on "Delete" button | ||
* I see "Remove auto membership rules" modal | ||
* I should see "my_automember_hostgroup" entry in the data table | ||
When in the modal dialog I click on "Delete" button | ||
* I should see "success" alert with text "The selected rules have been removed successfully" | ||
Then I should not see "my_automember_hostgroup" entry in the data table | ||
|
||
Scenario: Set default host group rule | ||
Given I am on "host-group-rules" page | ||
When I click in the selector field with ID "typeahead-select-input" | ||
* I click toolbar dropdown item "ipaservers" | ||
Then I see "Default hostgroup" modal | ||
When in the modal dialog I click on "OK" button | ||
Then I should see "success" alert with text "Default group updated" | ||
* in the selector with ID "typeahead-select-input" I should see option "ipaservers" selected | ||
|
||
# Cleanup: Delete the host group | ||
Scenario: Delete the host group | ||
Given I am on "host-groups" page | ||
Given I should see "my_automember_hostgroup" entry in the data table | ||
Then I select entry "my_automember_hostgroup" in the data table | ||
When I click on "Delete" button | ||
* I see "Remove host groups" modal | ||
* I should see "my_automember_hostgroup" entry in the data table | ||
When in the modal dialog I click on "Delete" button | ||
* I should see "success" alert with text "Host groups removed" | ||
Then I should not see "my_automember_hostgroup" entry in the data table | ||
|