chore: 🤖 gcp plugin creation in the UI (#2645)
gcp plugin creation and mirage changes
This commit is contained in:
1 parent
520020f2c6
commit
dfa62dd04b
11 files changed
+376
-28
No files matched your search
@@ -45,6 +45,7 @@ module('Acceptance | host-catalogs | create', function (hooks) {
|
||||
newStaticHostCatalog: null,
|
||||
newAWSDynamicHostCatalog: null,
|
||||
newAzureDynamicHostCatalog: null,
|
||||
newGCPDynamicHostCatalog: null,
|
||||
};
|
||||
|
||||
hooks.beforeEach(async function () {
|
||||
@@ -81,6 +82,7 @@ module('Acceptance | host-catalogs | create', function (hooks) {
|
||||
urls.newStaticHostCatalog = `${urls.newHostCatalog}?type=static`;
|
||||
urls.newAWSDynamicHostCatalog = `${urls.newHostCatalog}?type=aws`;
|
||||
urls.newAzureDynamicHostCatalog = `${urls.newHostCatalog}?type=azure`;
|
||||
urls.newGCPDynamicHostCatalog = `${urls.newHostCatalog}?type=gcp`;
|
||||
featuresService = this.owner.lookup('service:features');
|
||||
|
||||
// Generate resource counter
|
||||
@@ -110,7 +112,7 @@ module('Acceptance | host-catalogs | create', function (hooks) {
|
||||
assert.strictEqual(getHostCatalogCount(), count + 1);
|
||||
});
|
||||
|
||||
test('Users can create new dynamic aws host catalogs with azure provider', async function (assert) {
|
||||
test('Users can create new dynamic azure host catalogs with azure provider', async function (assert) {
|
||||
const count = getHostCatalogCount();
|
||||
await visit(urls.newAzureDynamicHostCatalog);
|
||||
await fillIn(NAME_INPUT_SELECTOR, 'random string');
|
||||
@@ -120,6 +122,18 @@ module('Acceptance | host-catalogs | create', function (hooks) {
|
||||
assert.strictEqual(getHostCatalogCount(), count + 1);
|
||||
});
|
||||
|
||||
test('Users can create new dynamic host catalogs with GCP provider ', async function (assert) {
|
||||
const count = getHostCatalogCount();
|
||||
await visit(urls.newGCPDynamicHostCatalog);
|
||||
await fillIn(NAME_INPUT_SELECTOR, 'random string');
|
||||
await fillIn(DESCRIPTION_INPUT_SELECTOR, 'random string');
|
||||
await fillIn('[name="zone"]', 'random string');
|
||||
await fillIn('[name="project_id"]', 'random string');
|
||||
await fillIn('[name="client_email"]', 'random string');
|
||||
await click(SAVE_BUTTON_SELECTOR);
|
||||
assert.strictEqual(getHostCatalogCount(), count + 1);
|
||||
});
|
||||
|
||||
test('Users can cancel creation of new static host catalogs', async function (assert) {
|
||||
const count = getHostCatalogCount();
|
||||
await visit(urls.newStaticHostCatalog);
|
||||
@@ -138,6 +152,15 @@ module('Acceptance | host-catalogs | create', function (hooks) {
|
||||
assert.strictEqual(getHostCatalogCount(), count);
|
||||
});
|
||||
|
||||
test('Users can cancel creation of new dynamic host catalogs with GCP provider', async function (assert) {
|
||||
const count = getHostCatalogCount();
|
||||
await visit(urls.newGCPDynamicHostCatalog);
|
||||
await fillIn(NAME_INPUT_SELECTOR, 'random string');
|
||||
await click(CANCEL_BUTTON_SELECTOR);
|
||||
assert.strictEqual(currentURL(), urls.hostCatalogs);
|
||||
assert.strictEqual(getHostCatalogCount(), count);
|
||||
});
|
||||
|
||||
test('Users can cancel creation of new dynamic host catalogs with Azure provider', async function (assert) {
|
||||
const count = getHostCatalogCount();
|
||||
await visit(urls.newAzureDynamicHostCatalog);
|
||||
|
||||
Reference in new issue
Block a user