open-consul/ui-v2/tests/acceptance/dc/nspaces/update.feature
John Cowen 4be0f6c061
ui: Run 2 separate test runs oss and ent (#7214)
* ui: Make API integration tests aware of CONSUL_NSPACES_ENABLED

* ui: Allow passing CONSUL_NSPACES_ENABLED in via the cli in ember

* ui: Add more makefile targets/package scripts to switch NSPACEs on/off

* ui: Ensure all acceptance tests continue to pass with NSPACEs on/off

This required a little tweaking of the dictionary, at some point
page-navigation and some of these little tweaks will no longer be
required

* ui: Try running CI frontend tests in two parellel runs oss/ent

* ui: Use correct make target, use different names for the reports
2020-02-07 11:02:53 +00:00

45 lines
1.4 KiB
Gherkin

@setupApplicationTest
@onlyNamespaceable
Feature: dc / nspaces / update: Nspace Update
Background:
Given 1 datacenter model with the value "datacenter"
And 1 nspace model from yaml
---
Name: namespace
Description: empty
PolicyDefaults: ~
---
When I visit the nspace page for yaml
---
dc: datacenter
namespace: namespace
---
Then the url should be /datacenter/namespaces/namespace
And the title should be "Edit Namespace - Consul"
Scenario: Update to [Description]
Then I fill in with yaml
---
Description: [Description]
---
And I submit
Then a PUT request was made to "/v1/namespace/namespace" from yaml
---
body:
Description: [Description]
---
Then the url should be /datacenter/namespaces
And "[data-notification]" has the "notification-update" class
And "[data-notification]" has the "success" class
Where:
---------------------------
| Description |
| description |
| description with spaces |
---------------------------
Scenario: There was an error saving the key
Given the url "/v1/namespace/namespace" responds with a 500 status
And I submit
Then the url should be /datacenter/namespaces/namespace
Then "[data-notification]" has the "notification-update" class
And "[data-notification]" has the "error" class