From bb8920a90c7fa12cab4188b08032703b4412b7b1 Mon Sep 17 00:00:00 2001 From: Randall Morey Date: Tue, 21 Sep 2021 14:32:39 -0400 Subject: [PATCH] =?UTF-8?q?chore:=20=F0=9F=A4=96=20rename=20ember=20resour?= =?UTF-8?q?ces=20to=20*-sources?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- addons/core/translations/actions/en-us.yaml | 1 - addons/core/translations/resources/en-us.yaml | 4 +- .../target/add-credential-libraries/index.hbs | 4 +- .../form/target/add-host-sets/index.hbs | 4 +- .../{add-host-sets.js => add-host-sources.js} | 4 +- ...ial-libraries.js => credential-sources.js} | 4 +- .../target/{host-sets.js => host-sources.js} | 2 +- ui/admin/app/router.js | 8 ++-- ...libraries.js => add-credential-sources.js} | 17 ++++---- .../{add-host-sets.js => add-host-sources.js} | 8 ++-- ...ial-libraries.js => credential-sources.js} | 2 +- .../target/{host-sets.js => host-sources.js} | 2 +- .../scopes/scope/targets/target/-actions.hbs | 10 ++--- .../scope/targets/target/-navigation.hbs | 4 +- ...braries.hbs => add-credential-sources.hbs} | 4 +- .../-header.hbs | 0 ...add-host-sets.hbs => add-host-sources.hbs} | 4 +- .../-header.hbs | 2 +- ...l-libraries.hbs => credential-sources.hbs} | 6 +-- .../{host-sets.hbs => host-sources.hbs} | 4 +- ui/admin/config/environment.js | 2 +- ...ies-test.js => credential-sources-test.js} | 42 +++++++++---------- ...host-sets-test.js => host-sources-test.js} | 32 +++++++------- ...-sets-test.js => add-host-sources-test.js} | 4 +- ...ies-test.js => credential-sources-test.js} | 4 +- ...host-sets-test.js => host-sources-test.js} | 4 +- ...test.js => add-credential-sources-test.js} | 4 +- ...-sets-test.js => add-host-sources-test.js} | 4 +- ...ies-test.js => credential-sources-test.js} | 4 +- ...host-sets-test.js => host-sources-test.js} | 4 +- 30 files changed, 95 insertions(+), 103 deletions(-) rename ui/admin/app/controllers/scopes/scope/targets/target/{add-host-sets.js => add-host-sources.js} (60%) rename ui/admin/app/controllers/scopes/scope/targets/target/{credential-libraries.js => credential-sources.js} (60%) rename ui/admin/app/controllers/scopes/scope/targets/target/{host-sets.js => host-sources.js} (77%) rename ui/admin/app/routes/scopes/scope/targets/target/{add-credential-libraries.js => add-credential-sources.js} (83%) rename ui/admin/app/routes/scopes/scope/targets/target/{add-host-sets.js => add-host-sources.js} (86%) rename ui/admin/app/routes/scopes/scope/targets/target/{credential-libraries.js => credential-sources.js} (94%) rename ui/admin/app/routes/scopes/scope/targets/target/{host-sets.js => host-sources.js} (96%) rename ui/admin/app/templates/scopes/scope/targets/target/{add-credential-libraries.hbs => add-credential-sources.hbs} (90%) rename ui/admin/app/templates/scopes/scope/targets/target/{add-credential-libraries => add-credential-sources}/-header.hbs (100%) rename ui/admin/app/templates/scopes/scope/targets/target/{add-host-sets.hbs => add-host-sources.hbs} (84%) rename ui/admin/app/templates/scopes/scope/targets/target/{add-host-sets => add-host-sources}/-header.hbs (68%) rename ui/admin/app/templates/scopes/scope/targets/target/{credential-libraries.hbs => credential-sources.hbs} (94%) rename ui/admin/app/templates/scopes/scope/targets/target/{host-sets.hbs => host-sources.hbs} (97%) rename ui/admin/tests/acceptance/targets/{credential-libraries-test.js => credential-sources-test.js} (81%) rename ui/admin/tests/acceptance/targets/{host-sets-test.js => host-sources-test.js} (85%) rename ui/admin/tests/unit/controllers/scopes/scope/targets/target/{add-host-sets-test.js => add-host-sources-test.js} (69%) rename ui/admin/tests/unit/controllers/scopes/scope/targets/target/{credential-libraries-test.js => credential-sources-test.js} (68%) rename ui/admin/tests/unit/controllers/scopes/scope/targets/target/{host-sets-test.js => host-sources-test.js} (71%) rename ui/admin/tests/unit/routes/scopes/scope/targets/target/{add-credential-libraries-test.js => add-credential-sources-test.js} (64%) rename ui/admin/tests/unit/routes/scopes/scope/targets/target/{add-host-sets-test.js => add-host-sources-test.js} (67%) rename ui/admin/tests/unit/routes/scopes/scope/targets/target/{credential-libraries-test.js => credential-sources-test.js} (65%) rename ui/admin/tests/unit/routes/scopes/scope/targets/target/{host-sets-test.js => host-sources-test.js} (68%) diff --git a/addons/core/translations/actions/en-us.yaml b/addons/core/translations/actions/en-us.yaml index 9b7a8561d..144ced636 100644 --- a/addons/core/translations/actions/en-us.yaml +++ b/addons/core/translations/actions/en-us.yaml @@ -23,7 +23,6 @@ choose-org: Choose Scope choose-different-org: Choose a different scope add-host-set: Create Host Set add-host: Create Host -add-host-sets: Add Host Sets add-principals: Add Principals add-members: Add Members add-hosts: Add Hosts diff --git a/addons/core/translations/resources/en-us.yaml b/addons/core/translations/resources/en-us.yaml index f6b3373c8..91ed16ac1 100644 --- a/addons/core/translations/resources/en-us.yaml +++ b/addons/core/translations/resources/en-us.yaml @@ -253,8 +253,8 @@ target: actions: create: New Target delete: Delete Target - add-host-sets: Add Host Sources - add-credential-libraries: Add Credential Sources + add-host-sources: Add Host Sources + add-credential-sources: Add Credential Sources types: tcp: TCP host-source: diff --git a/ui/admin/app/components/form/target/add-credential-libraries/index.hbs b/ui/admin/app/components/form/target/add-credential-libraries/index.hbs index e70fc20e2..d07c27884 100644 --- a/ui/admin/app/components/form/target/add-credential-libraries/index.hbs +++ b/ui/admin/app/components/form/target/add-credential-libraries/index.hbs @@ -8,7 +8,7 @@ as |form| > @@ -54,7 +54,7 @@ {{t 'resources.target.credential-source.messages.none.description'}} - + {{t 'actions.back'}} diff --git a/ui/admin/app/components/form/target/add-host-sets/index.hbs b/ui/admin/app/components/form/target/add-host-sets/index.hbs index f248e80fd..1885700fd 100644 --- a/ui/admin/app/components/form/target/add-host-sets/index.hbs +++ b/ui/admin/app/components/form/target/add-host-sets/index.hbs @@ -9,7 +9,7 @@ > @@ -58,7 +58,7 @@ {{t 'resources.target.host-source.messages.none.description'}} - + {{t 'actions.back'}} diff --git a/ui/admin/app/controllers/scopes/scope/targets/target/add-host-sets.js b/ui/admin/app/controllers/scopes/scope/targets/target/add-host-sources.js similarity index 60% rename from ui/admin/app/controllers/scopes/scope/targets/target/add-host-sets.js rename to ui/admin/app/controllers/scopes/scope/targets/target/add-host-sources.js index 6700b582d..56c5282ea 100644 --- a/ui/admin/app/controllers/scopes/scope/targets/target/add-host-sets.js +++ b/ui/admin/app/controllers/scopes/scope/targets/target/add-host-sources.js @@ -1,7 +1,7 @@ import Controller from '@ember/controller'; import { inject as service } from '@ember/service'; -export default class ScopesScopeTargetsTargetAddHostSetsController extends Controller { +export default class ScopesScopeTargetsTargetAddHostSourcesController extends Controller { // =services @service intl; @@ -13,6 +13,6 @@ export default class ScopesScopeTargetsTargetAddHostSetsController extends Contr * @type {string} */ get breadCrumb() { - return this.intl.t('resources.target.actions.add-host-sets'); + return this.intl.t('resources.target.actions.add-host-sources'); } } diff --git a/ui/admin/app/controllers/scopes/scope/targets/target/credential-libraries.js b/ui/admin/app/controllers/scopes/scope/targets/target/credential-sources.js similarity index 60% rename from ui/admin/app/controllers/scopes/scope/targets/target/credential-libraries.js rename to ui/admin/app/controllers/scopes/scope/targets/target/credential-sources.js index ff0f8c558..eb9ab7720 100644 --- a/ui/admin/app/controllers/scopes/scope/targets/target/credential-libraries.js +++ b/ui/admin/app/controllers/scopes/scope/targets/target/credential-sources.js @@ -1,7 +1,7 @@ import Controller from '@ember/controller'; import { inject as service } from '@ember/service'; -export default class ScopesScopeTargetsTargetCredentialLibrariesController extends Controller { +export default class ScopesScopeTargetsTargetCredentialSourcesController extends Controller { // =services @service intl; @@ -13,6 +13,6 @@ export default class ScopesScopeTargetsTargetCredentialLibrariesController exten * @type {string} */ get breadCrumb() { - return this.intl.t('resources.credential-library.title_plural'); + return this.intl.t('resources.target.credential-source.title_plural'); } } diff --git a/ui/admin/app/controllers/scopes/scope/targets/target/host-sets.js b/ui/admin/app/controllers/scopes/scope/targets/target/host-sources.js similarity index 77% rename from ui/admin/app/controllers/scopes/scope/targets/target/host-sets.js rename to ui/admin/app/controllers/scopes/scope/targets/target/host-sources.js index b37d3dbf6..80317b66d 100644 --- a/ui/admin/app/controllers/scopes/scope/targets/target/host-sets.js +++ b/ui/admin/app/controllers/scopes/scope/targets/target/host-sources.js @@ -1,7 +1,7 @@ import Controller from '@ember/controller'; import { inject as service } from '@ember/service'; -export default class ScopesScopeTargetsTargetHostSetsController extends Controller { +export default class ScopesScopeTargetsTargetHostSourcesController extends Controller { // =services @service intl; diff --git a/ui/admin/app/router.js b/ui/admin/app/router.js index 6b70bd999..7e62a2ce4 100644 --- a/ui/admin/app/router.js +++ b/ui/admin/app/router.js @@ -63,10 +63,10 @@ Router.map(function () { this.route('targets', function () { this.route('target', { path: ':target_id' }, function () { - this.route('host-sets', function () {}); - this.route('add-host-sets'); - this.route('credential-libraries'); - this.route('add-credential-libraries'); + this.route('host-sources', function () {}); + this.route('add-host-sources'); + this.route('credential-sources'); + this.route('add-credential-sources'); }); this.route('new'); }); diff --git a/ui/admin/app/routes/scopes/scope/targets/target/add-credential-libraries.js b/ui/admin/app/routes/scopes/scope/targets/target/add-credential-sources.js similarity index 83% rename from ui/admin/app/routes/scopes/scope/targets/target/add-credential-libraries.js rename to ui/admin/app/routes/scopes/scope/targets/target/add-credential-sources.js index f2cb1eca2..acc333255 100644 --- a/ui/admin/app/routes/scopes/scope/targets/target/add-credential-libraries.js +++ b/ui/admin/app/routes/scopes/scope/targets/target/add-credential-sources.js @@ -5,7 +5,7 @@ import { action } from '@ember/object'; import loading from 'ember-loading/decorator'; import { notifySuccess, notifyError } from 'core/decorators/notify'; -export default class ScopesScopeTargetsTargetAddCredentialLibrariesRoute extends Route { +export default class ScopesScopeTargetsTargetAddCredentialSourcesRoute extends Route { // =services @service intl; @@ -49,13 +49,10 @@ export default class ScopesScopeTargetsTargetAddCredentialLibrariesRoute extends renderTemplate() { super.renderTemplate(...arguments); - this.render( - 'scopes/scope/targets/target/add-credential-libraries/-header', - { - into: 'scopes/scope/targets/target', - outlet: 'header', - } - ); + this.render('scopes/scope/targets/target/add-credential-sources/-header', { + into: 'scopes/scope/targets/target', + outlet: 'header', + }); this.render('-empty', { into: 'scopes/scope/targets/target', @@ -81,7 +78,7 @@ export default class ScopesScopeTargetsTargetAddCredentialLibrariesRoute extends @notifySuccess('notifications.add-success') async save(target, credentialLibraryIDs) { await target.addCredentialLibraries(credentialLibraryIDs); - this.replaceWith('scopes.scope.targets.target.credential-libraries'); + this.replaceWith('scopes.scope.targets.target.credential-sources'); } /** @@ -89,6 +86,6 @@ export default class ScopesScopeTargetsTargetAddCredentialLibrariesRoute extends */ @action cancel() { - this.replaceWith('scopes.scope.targets.target.credential-libraries'); + this.replaceWith('scopes.scope.targets.target.credential-sources'); } } diff --git a/ui/admin/app/routes/scopes/scope/targets/target/add-host-sets.js b/ui/admin/app/routes/scopes/scope/targets/target/add-host-sources.js similarity index 86% rename from ui/admin/app/routes/scopes/scope/targets/target/add-host-sets.js rename to ui/admin/app/routes/scopes/scope/targets/target/add-host-sources.js index 15cb88ddd..18e721233 100644 --- a/ui/admin/app/routes/scopes/scope/targets/target/add-host-sets.js +++ b/ui/admin/app/routes/scopes/scope/targets/target/add-host-sources.js @@ -5,7 +5,7 @@ import { all } from 'rsvp'; import loading from 'ember-loading/decorator'; import { notifySuccess, notifyError } from 'core/decorators/notify'; -export default class ScopesScopeTargetsTargetAddHostSetsRoute extends Route { +export default class ScopesScopeTargetsTargetAddHostSourcesRoute extends Route { // =services @service intl; @@ -48,7 +48,7 @@ export default class ScopesScopeTargetsTargetAddHostSetsRoute extends Route { renderTemplate() { super.renderTemplate(...arguments); - this.render('scopes/scope/targets/target/add-host-sets/-header', { + this.render('scopes/scope/targets/target/add-host-sources/-header', { into: 'scopes/scope/targets/target', outlet: 'header', }); @@ -72,7 +72,7 @@ export default class ScopesScopeTargetsTargetAddHostSetsRoute extends Route { @notifySuccess('notifications.add-success') async save(target, hostSetIDs) { await target.addHostSets(hostSetIDs); - this.replaceWith('scopes.scope.targets.target.host-sets'); + this.replaceWith('scopes.scope.targets.target.host-sources'); } /** @@ -80,6 +80,6 @@ export default class ScopesScopeTargetsTargetAddHostSetsRoute extends Route { */ @action cancel() { - this.replaceWith('scopes.scope.targets.target.host-sets'); + this.replaceWith('scopes.scope.targets.target.host-sources'); } } diff --git a/ui/admin/app/routes/scopes/scope/targets/target/credential-libraries.js b/ui/admin/app/routes/scopes/scope/targets/target/credential-sources.js similarity index 94% rename from ui/admin/app/routes/scopes/scope/targets/target/credential-libraries.js rename to ui/admin/app/routes/scopes/scope/targets/target/credential-sources.js index 66ce6f8ec..a4fd2a7de 100644 --- a/ui/admin/app/routes/scopes/scope/targets/target/credential-libraries.js +++ b/ui/admin/app/routes/scopes/scope/targets/target/credential-sources.js @@ -5,7 +5,7 @@ import loading from 'ember-loading/decorator'; import { confirm } from 'core/decorators/confirm'; import { notifySuccess, notifyError } from 'core/decorators/notify'; -export default class ScopesScopeTargetsTargetCredentialLibrariesRoute extends Route { +export default class ScopesScopeTargetsTargetCredentialSourcesRoute extends Route { // =methods /** diff --git a/ui/admin/app/routes/scopes/scope/targets/target/host-sets.js b/ui/admin/app/routes/scopes/scope/targets/target/host-sources.js similarity index 96% rename from ui/admin/app/routes/scopes/scope/targets/target/host-sets.js rename to ui/admin/app/routes/scopes/scope/targets/target/host-sources.js index 120de013a..8abf4022c 100644 --- a/ui/admin/app/routes/scopes/scope/targets/target/host-sets.js +++ b/ui/admin/app/routes/scopes/scope/targets/target/host-sources.js @@ -6,7 +6,7 @@ import loading from 'ember-loading/decorator'; import { confirm } from 'core/decorators/confirm'; import { notifySuccess, notifyError } from 'core/decorators/notify'; -export default class ScopesScopeTargetsTargetHostSetsRoute extends Route { +export default class ScopesScopeTargetsTargetHostSourcesRoute extends Route { // =services @service intl; diff --git a/ui/admin/app/templates/scopes/scope/targets/target/-actions.hbs b/ui/admin/app/templates/scopes/scope/targets/target/-actions.hbs index 2de077d3d..3e32c0848 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/-actions.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/-actions.hbs @@ -3,14 +3,12 @@ @dropdownRight={{true}} as |dropdown| > - - {{t 'resources.target.actions.add-host-sets'}} + + {{t 'resources.target.actions.add-host-sources'}} {{#if (feature-flag 'credential-store')}} - - {{t 'resources.target.actions.add-credential-libraries'}} + + {{t 'resources.target.actions.add-credential-sources'}} {{/if}} {{#if (can 'delete model' @model)}} diff --git a/ui/admin/app/templates/scopes/scope/targets/target/-navigation.hbs b/ui/admin/app/templates/scopes/scope/targets/target/-navigation.hbs index 55b292b21..8d35a9f03 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/-navigation.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/-navigation.hbs @@ -2,11 +2,11 @@ {{t 'titles.details'}} - + {{t 'resources.target.host-source.title_plural'}} {{#if (feature-flag 'credential-store')}} - + {{t 'resources.target.credential-source.title_plural'}} {{/if}} diff --git a/ui/admin/app/templates/scopes/scope/targets/target/add-credential-libraries.hbs b/ui/admin/app/templates/scopes/scope/targets/target/add-credential-sources.hbs similarity index 90% rename from ui/admin/app/templates/scopes/scope/targets/target/add-credential-libraries.hbs rename to ui/admin/app/templates/scopes/scope/targets/target/add-credential-sources.hbs index cbb836a58..cc0992c50 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/add-credential-libraries.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/add-credential-sources.hbs @@ -1,4 +1,4 @@ -{{page-title (t 'resources.target.actions.add-credential-libraries')}} +{{page-title (t 'resources.target.actions.add-credential-sources')}} {{#if @model.credentialLibraries}} {{t 'resources.target.credential-source.messages.none.description'}} - + {{t 'actions.back'}} diff --git a/ui/admin/app/templates/scopes/scope/targets/target/add-credential-libraries/-header.hbs b/ui/admin/app/templates/scopes/scope/targets/target/add-credential-sources/-header.hbs similarity index 100% rename from ui/admin/app/templates/scopes/scope/targets/target/add-credential-libraries/-header.hbs rename to ui/admin/app/templates/scopes/scope/targets/target/add-credential-sources/-header.hbs diff --git a/ui/admin/app/templates/scopes/scope/targets/target/add-host-sets.hbs b/ui/admin/app/templates/scopes/scope/targets/target/add-host-sources.hbs similarity index 84% rename from ui/admin/app/templates/scopes/scope/targets/target/add-host-sets.hbs rename to ui/admin/app/templates/scopes/scope/targets/target/add-host-sources.hbs index 02cc4c8cc..f846930c6 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/add-host-sets.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/add-host-sources.hbs @@ -1,4 +1,4 @@ -{{page-title (t 'resources.target.actions.add-host-sets')}} +{{page-title (t 'resources.target.actions.add-host-sources')}} {{#if @model.hostSets}} {{t 'resources.target.host-source.messages.none.description'}} - + {{t 'actions.back'}} diff --git a/ui/admin/app/templates/scopes/scope/targets/target/add-host-sets/-header.hbs b/ui/admin/app/templates/scopes/scope/targets/target/add-host-sources/-header.hbs similarity index 68% rename from ui/admin/app/templates/scopes/scope/targets/target/add-host-sets/-header.hbs rename to ui/admin/app/templates/scopes/scope/targets/target/add-host-sources/-header.hbs index dcec19c1c..abbb353fa 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/add-host-sets/-header.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/add-host-sources/-header.hbs @@ -1,5 +1,5 @@

{{t 'resources.target.host-source.messages.add.title'}} - +

{{t 'resources.target.host-source.messages.add.description'}}

\ No newline at end of file diff --git a/ui/admin/app/templates/scopes/scope/targets/target/credential-libraries.hbs b/ui/admin/app/templates/scopes/scope/targets/target/credential-sources.hbs similarity index 94% rename from ui/admin/app/templates/scopes/scope/targets/target/credential-libraries.hbs rename to ui/admin/app/templates/scopes/scope/targets/target/credential-sources.hbs index 7692af1c2..4a2c688b1 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/credential-libraries.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/credential-sources.hbs @@ -79,11 +79,9 @@ {{t 'resources.target.credential-source.messages.welcome.description'}} - + - {{t 'resources.target.actions.add-credential-libraries'}} + {{t 'resources.target.actions.add-credential-sources'}} diff --git a/ui/admin/app/templates/scopes/scope/targets/target/host-sets.hbs b/ui/admin/app/templates/scopes/scope/targets/target/host-sources.hbs similarity index 97% rename from ui/admin/app/templates/scopes/scope/targets/target/host-sets.hbs rename to ui/admin/app/templates/scopes/scope/targets/target/host-sources.hbs index b6d335414..876622e14 100644 --- a/ui/admin/app/templates/scopes/scope/targets/target/host-sets.hbs +++ b/ui/admin/app/templates/scopes/scope/targets/target/host-sources.hbs @@ -67,9 +67,9 @@ {{t 'resources.target.host-source.messages.welcome.description'}} - + - {{t 'resources.target.actions.add-host-sets'}} + {{t 'resources.target.actions.add-host-sources'}} diff --git a/ui/admin/config/environment.js b/ui/admin/config/environment.js index 3b1a8df4b..b515fc76a 100644 --- a/ui/admin/config/environment.js +++ b/ui/admin/config/environment.js @@ -64,7 +64,7 @@ module.exports = function (environment) { session: '/sessions', target: '/targets', 'target.new': '/targets/new', - 'target.add-host-sets': '/targets/add-host-sets', + 'target.add-host-sources': '/targets/add-host-sets', user: '/users', }, }, diff --git a/ui/admin/tests/acceptance/targets/credential-libraries-test.js b/ui/admin/tests/acceptance/targets/credential-sources-test.js similarity index 81% rename from ui/admin/tests/acceptance/targets/credential-libraries-test.js rename to ui/admin/tests/acceptance/targets/credential-sources-test.js index 3e75c8fa2..dd3d0c7ed 100644 --- a/ui/admin/tests/acceptance/targets/credential-libraries-test.js +++ b/ui/admin/tests/acceptance/targets/credential-sources-test.js @@ -72,65 +72,65 @@ module('Acceptance | targets | credential-libraries', function (hooks) { urls.projectScope = `/scopes/${instances.scopes.project.id}`; urls.targets = `${urls.projectScope}/targets`; urls.target = `${urls.targets}/${instances.target.id}`; - urls.credentialLibraries = `${urls.target}/credential-libraries`; + urls.credentialSources = `${urls.target}/credential-sources`; urls.credentialLibrary = `${urls.projectScope}/credential-stores/${instances.credentialLibrary.credentialStoreId}/credential-libraries/${instances.credentialLibrary.id}`; - urls.addCredentialLibraries = `${urls.target}/add-credential-libraries`; + urls.addCredentialSources = `${urls.target}/add-credential-sources`; // Generate resource counter getCredentialLibraryCount = () => this.server.schema.credentialLibraries.all().models.length; authenticateSession({}); }); - test('visiting target credential libraries', async function (assert) { + test('visiting target credential sources', async function (assert) { assert.expect(2); - await visit(urls.credentialLibraries); + await visit(urls.credentialSources); await a11yAudit(); - assert.equal(currentURL(), urls.credentialLibraries); + assert.equal(currentURL(), urls.credentialSources); assert.equal(findAll('tbody tr').length, getCredentialLibraryCount()); }); test('can navigate to a credential library', async function (assert) { assert.expect(1); - await visit(urls.credentialLibraries); + await visit(urls.credentialSources); await click('main tbody .rose-table-header-cell:nth-child(1) a'); await a11yAudit(); assert.equal(currentURL(), urls.credentialLibrary); }); - test('visiting add credential libraries', async function (assert) { + test('visiting add credential sources', async function (assert) { assert.expect(1); - await visit(urls.addCredentialLibraries); + await visit(urls.addCredentialSources); await a11yAudit(); - assert.equal(currentURL(), urls.addCredentialLibraries); + assert.equal(currentURL(), urls.addCredentialSources); }); - test('can select and save credential libraries to add', async function (assert) { + test('can select and save credential sources to add', async function (assert) { assert.expect(4); instances.target.update({ credentialLibraries: [] }); - await visit(urls.credentialLibraries); + await visit(urls.credentialSources); assert.equal(findAll('tbody tr').length, 0); - await visit(urls.addCredentialLibraries); + await visit(urls.addCredentialSources); assert.equal(findAll('tbody tr').length, getCredentialLibraryCount()); await click('tbody label'); await click('form [type="submit"]'); - assert.equal(currentURL(), urls.credentialLibraries); + assert.equal(currentURL(), urls.credentialSources); assert.equal(findAll('tbody tr').length, 1); }); - test('can select and cancel credential libraries to add', async function (assert) { + test('can select and cancel credential sources to add', async function (assert) { assert.expect(4); instances.target.update({ credentialLibraries: [] }); - await visit(urls.credentialLibraries); + await visit(urls.credentialSources); assert.equal(findAll('tbody tr').length, 0); - await visit(urls.addCredentialLibraries); + await visit(urls.addCredentialSources); assert.equal(findAll('tbody tr').length, getCredentialLibraryCount()); await click('tbody label'); await click('form [type="button"]'); - assert.equal(currentURL(), urls.credentialLibraries); + assert.equal(currentURL(), urls.credentialSources); assert.equal(findAll('tbody tr').length, 0); }); - test('adding credential libraries which errors displays error message', async function (assert) { + test('adding credential sources which errors displays error message', async function (assert) { assert.expect(1); this.server.post('/targets/:idMethod', () => { return new Response( @@ -145,7 +145,7 @@ module('Acceptance | targets | credential-libraries', function (hooks) { ); }); instances.target.update({ credentialLibraries: [] }); - await visit(urls.addCredentialLibraries); + await visit(urls.addCredentialSources); await click('tbody label'); await click('form [type="submit"]'); assert.ok(find('[role="alert"]')); @@ -154,7 +154,7 @@ module('Acceptance | targets | credential-libraries', function (hooks) { test('can remove a credential library', async function (assert) { assert.expect(2); const count = getCredentialLibraryCount(); - await visit(urls.credentialLibraries); + await visit(urls.credentialSources); assert.equal(findAll('tbody tr').length, count); await click('tbody tr .rose-dropdown-button-danger'); assert.equal(findAll('tbody tr').length, count - 1); @@ -175,7 +175,7 @@ module('Acceptance | targets | credential-libraries', function (hooks) { ); }); const count = getCredentialLibraryCount(); - await visit(urls.credentialLibraries); + await visit(urls.credentialSources); assert.equal(findAll('tbody tr').length, count); await click('tbody tr .rose-dropdown-button-danger'); assert.ok(find('[role="alert"]')); diff --git a/ui/admin/tests/acceptance/targets/host-sets-test.js b/ui/admin/tests/acceptance/targets/host-sources-test.js similarity index 85% rename from ui/admin/tests/acceptance/targets/host-sets-test.js rename to ui/admin/tests/acceptance/targets/host-sources-test.js index 3ea6f4a07..9cf02a4f4 100644 --- a/ui/admin/tests/acceptance/targets/host-sets-test.js +++ b/ui/admin/tests/acceptance/targets/host-sources-test.js @@ -11,7 +11,7 @@ import { //invalidateSession, } from 'ember-simple-auth/test-support'; -module('Acceptance | targets | host-sets', function (hooks) { +module('Acceptance | targets | host-sources', function (hooks) { setupApplicationTest(hooks); setupMirage(hooks); @@ -60,17 +60,17 @@ module('Acceptance | targets | host-sets', function (hooks) { urls.projectScope = `/scopes/${instances.scopes.project.id}`; urls.targets = `/scopes/${instances.scopes.project.id}/targets`; urls.target = `${urls.targets}/${instances.target.id}`; - urls.targetHostSets = `${urls.target}/host-sets`; - urls.targetAddHostSets = `${urls.target}/add-host-sets`; + urls.targetHostSources = `${urls.target}/host-sources`; + urls.targetAddHostSources = `${urls.target}/add-host-sources`; authenticateSession({}); }); test('visiting target host sets', async function (assert) { assert.expect(3); const targetHostSetCount = instances.target.hostSets.length; - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); await a11yAudit(); - assert.equal(currentURL(), urls.targetHostSets); + assert.equal(currentURL(), urls.targetHostSources); assert.ok(targetHostSetCount); assert.equal(findAll('tbody tr').length, targetHostSetCount); }); @@ -78,7 +78,7 @@ module('Acceptance | targets | host-sets', function (hooks) { test('can remove a host sets', async function (assert) { assert.expect(2); const targetHostSetCount = instances.target.hostSets.length; - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); assert.equal(findAll('tbody tr').length, targetHostSetCount); await click('tbody tr .rose-dropdown-button-danger'); assert.equal(findAll('tbody tr').length, targetHostSetCount - 1); @@ -99,7 +99,7 @@ module('Acceptance | targets | host-sets', function (hooks) { ); }); const targetHostSetCount = instances.target.hostSets.length; - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); assert.equal(findAll('tbody tr').length, targetHostSetCount); await click('tbody tr .rose-dropdown-button-danger'); assert.ok(find('[role="alert"]')); @@ -108,32 +108,32 @@ module('Acceptance | targets | host-sets', function (hooks) { test('select and save host sets to add', async function (assert) { assert.expect(3); instances.target.update({ hostSetIds: [] }); - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); assert.equal(findAll('tbody tr').length, 0); await click('.rose-layout-page-actions a'); - assert.equal(currentURL(), urls.targetAddHostSets); + assert.equal(currentURL(), urls.targetAddHostSources); // Click three times to select, unselect, then reselect (for coverage) await click('tbody label'); await click('tbody label'); await click('tbody label'); await click('form [type="submit"]'); - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); assert.equal(findAll('tbody tr').length, 1); }); test('select and cancel host sets to add', async function (assert) { assert.expect(4); const targetHostSetCount = instances.target.hostSets.length; - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); assert.equal(findAll('tbody tr').length, targetHostSetCount); // first, remove a target host set (otherwise none would be available to add) await click('tbody tr .rose-dropdown-button-danger'); assert.equal(findAll('tbody tr').length, targetHostSetCount - 1); await click('.rose-layout-page-actions a'); - assert.equal(currentURL(), urls.targetAddHostSets); + assert.equal(currentURL(), urls.targetAddHostSources); await click('tbody label'); await click('form [type="button"]'); - await visit(urls.targetHostSets); + await visit(urls.targetHostSources); assert.equal(findAll('tbody tr').length, targetHostSetCount - 1); }); @@ -152,12 +152,12 @@ module('Acceptance | targets | host-sets', function (hooks) { ); }); instances.target.update({ hostSetIds: [] }); - await visit(urls.targetAddHostSets); + await visit(urls.targetAddHostSources); assert.equal(instances.target.hostSets.length, 0); - assert.equal(currentURL(), urls.targetAddHostSets); + assert.equal(currentURL(), urls.targetAddHostSources); await click('tbody label'); await click('form [type="submit"]'); - assert.equal(currentURL(), urls.targetAddHostSets); + assert.equal(currentURL(), urls.targetAddHostSources); assert.equal(instances.target.hostSets.length, 0); }); }); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/add-host-sets-test.js b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/add-host-sources-test.js similarity index 69% rename from ui/admin/tests/unit/controllers/scopes/scope/targets/target/add-host-sets-test.js rename to ui/admin/tests/unit/controllers/scopes/scope/targets/target/add-host-sources-test.js index bd24fcaf8..395717b7a 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/add-host-sets-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/add-host-sources-test.js @@ -2,14 +2,14 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Controller | scopes/scope/targets/target/add-host-sets', + 'Unit | Controller | scopes/scope/targets/target/add-host-sources', function (hooks) { setupTest(hooks); // TODO: Replace this with your real tests. test('it exists', function (assert) { let controller = this.owner.lookup( - 'controller:scopes/scope/targets/target/add-host-sets' + 'controller:scopes/scope/targets/target/add-host-sources' ); assert.ok(controller); }); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/credential-libraries-test.js b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/credential-sources-test.js similarity index 68% rename from ui/admin/tests/unit/controllers/scopes/scope/targets/target/credential-libraries-test.js rename to ui/admin/tests/unit/controllers/scopes/scope/targets/target/credential-sources-test.js index 76a26ff69..e96f06784 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/credential-libraries-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/credential-sources-test.js @@ -2,14 +2,14 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Controller | scopes/scope/targets/target/credential-libraries', + 'Unit | Controller | scopes/scope/targets/target/credential-sources', function (hooks) { setupTest(hooks); // TODO: Replace this with your real tests. test('it exists', function (assert) { let controller = this.owner.lookup( - 'controller:scopes/scope/targets/target/credential-libraries' + 'controller:scopes/scope/targets/target/credential-sources' ); assert.ok(controller); }); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sources-test.js similarity index 71% rename from ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js rename to ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sources-test.js index 46ca085a6..31df17359 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sources-test.js @@ -2,14 +2,14 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Controller | scopes/scope/targets/target/host-sets', + 'Unit | Controller | scopes/scope/targets/target/host-sources', function (hooks) { setupTest(hooks); // TODO: Replace this with your real tests. test('it exists', function (assert) { let controller = this.owner.lookup( - 'controller:scopes/scope/targets/target/host-sets' + 'controller:scopes/scope/targets/target/host-sources' ); assert.ok(controller); }); diff --git a/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-credential-libraries-test.js b/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-credential-sources-test.js similarity index 64% rename from ui/admin/tests/unit/routes/scopes/scope/targets/target/add-credential-libraries-test.js rename to ui/admin/tests/unit/routes/scopes/scope/targets/target/add-credential-sources-test.js index e6279d5b3..90afd3ac1 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-credential-libraries-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-credential-sources-test.js @@ -2,13 +2,13 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Route | scopes/scope/targets/target/add-credential-libraries', + 'Unit | Route | scopes/scope/targets/target/add-credential-sources', function (hooks) { setupTest(hooks); test('it exists', function (assert) { let route = this.owner.lookup( - 'route:scopes/scope/targets/target/add-credential-libraries' + 'route:scopes/scope/targets/target/add-credential-sources' ); assert.ok(route); }); diff --git a/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js b/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sources-test.js similarity index 67% rename from ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js rename to ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sources-test.js index e2a87487e..3f5fbd33a 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sources-test.js @@ -2,13 +2,13 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Route | scopes/scope/targets/target/add-host-sets', + 'Unit | Route | scopes/scope/targets/target/add-host-sources', function (hooks) { setupTest(hooks); test('it exists', function (assert) { let route = this.owner.lookup( - 'route:scopes/scope/targets/target/add-host-sets' + 'route:scopes/scope/targets/target/add-host-sources' ); assert.ok(route); }); diff --git a/ui/admin/tests/unit/routes/scopes/scope/targets/target/credential-libraries-test.js b/ui/admin/tests/unit/routes/scopes/scope/targets/target/credential-sources-test.js similarity index 65% rename from ui/admin/tests/unit/routes/scopes/scope/targets/target/credential-libraries-test.js rename to ui/admin/tests/unit/routes/scopes/scope/targets/target/credential-sources-test.js index 894e3add0..76a6808de 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/targets/target/credential-libraries-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/targets/target/credential-sources-test.js @@ -2,13 +2,13 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Route | scopes/scope/targets/target/credential-libraries', + 'Unit | Route | scopes/scope/targets/target/credential-sources', function (hooks) { setupTest(hooks); test('it exists', function (assert) { let route = this.owner.lookup( - 'route:scopes/scope/targets/target/credential-libraries' + 'route:scopes/scope/targets/target/credential-sources' ); assert.ok(route); }); diff --git a/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js b/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sources-test.js similarity index 68% rename from ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js rename to ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sources-test.js index 214bf28b3..fed9b412e 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sources-test.js @@ -2,13 +2,13 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; module( - 'Unit | Route | scopes/scope/targets/target/host-sets', + 'Unit | Route | scopes/scope/targets/target/host-sources', function (hooks) { setupTest(hooks); test('it exists', function (assert) { let route = this.owner.lookup( - 'route:scopes/scope/targets/target/host-sets' + 'route:scopes/scope/targets/target/host-sources' ); assert.ok(route); });