Skip to content
Snippets Groups Projects
Commit 10488170 authored by Kumiko Ono's avatar Kumiko Ono Committed by Yas Naoi
Browse files

Issue #3276714 by kumikoono, yas: Refactor BDD test feature files (K8s)

parent a8c10eaa
Branches
Tags
3 merge requests!1316Issue #3310263: Release 4.5.0,!1260Issue #3307397: Release 4.4.0,!879Issue #3276714: Refactor BDD test feature files for k8s module
Showing
with 30 additions and 31 deletions
Feature: Create a cloud service provider for K8s as "Cloud administrator"
In order to start BDD testing
We need to create a cloud service provider
@api
Scenario: Add a K8s Cloud service provider
Given I am logged in as a user with the "Cloud administrator" role
When I visit "/admin/structure/cloud_config/add/k8s"
And I enter "{{ k8s_cloud_service_provider_name_entered }}" for "Name"
And I enter "{{ api_server }}" for "API server"
And I enter "{{ api_server_token }}" for "Token"
And I press "Save"
Then I should be on "/admin/structure/cloud_config"
And I should see "has been created"
And I should see K8s in the "{{ k8s_cloud_service_provider_name }}" row
Feature: Create resources for K8s as "Administrator"
In order to start BDD testing
We need to create some resources
@api
Scenario: Add a K8s Cloud service provider
Given I am logged in as a user with the "Cloud administrator" role
When I visit "/admin/structure/cloud_config/add/k8s"
And I enter "{{ k8s_cloud_service_provider_name_entered }}" for "Name"
And I enter "{{ api_server }}" for "API server"
And I enter "{{ api_server_token }}" for "Token"
And I press "Save"
Then I should be on "/admin/structure/cloud_config"
And I should see "has been created"
And I should see K8s in the "{{ k8s_cloud_service_provider_name }}" row
Feature: Create a Drupal role for K8s and a user as "Administrator"
@api
Scenario: Create a role
......
Feature: Delete the created resources as "Cloud administrator"
@api
Scenario: Delete created Cloud service providers
Given I am logged in as a user with the "Cloud administrator" role
When I visit "/admin/structure/cloud_config"
And I check the box in the "{{ k8s_cloud_service_provider_name }}" row
And I select "Delete cloud service provider(s)" from "Action"
And I press "Apply to selected items"
And I press "Delete"
Then I should be on "/admin/structure/cloud_config"
And I should see "Deleted 1 item."
And I should not see the link "{{ k8s_cloud_service_provider_name }}"
Feature: Delete the created resources as "Administrator"
In order to change to clean state
As an admin
I need to delete some resource
@api
Scenario: Delete created Cloud service providers
Given I am logged in as a user with the "Cloud administrator" role
When I visit "/admin/structure/cloud_config"
And I check the box in the "{{ k8s_cloud_service_provider_name }}" row
And I select "Delete cloud service provider(s)" from "Action"
And I press "Apply to selected items"
And I press "Delete"
Then I should be on "/admin/structure/cloud_config"
And I should see "Deleted 1 item."
And I should not see the link "{{ k8s_cloud_service_provider_name }}"
Feature: Delete the created Drupal resources as "Administrator"
@api
Scenario: Delete a created role
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment