From f317154b949984b9030b0dafcd9923e3f53a6a70 Mon Sep 17 00:00:00 2001 From: Matthew Irish Date: Wed, 23 May 2018 16:51:19 -0500 Subject: [PATCH] review feedback --- .../access/identity/_shared-alias-tests.js | 2 -- .../unit/components/identity/edit-form-test.js | 18 ++++++++---------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/ui/tests/acceptance/access/identity/_shared-alias-tests.js b/ui/tests/acceptance/access/identity/_shared-alias-tests.js index 3ef416a91c5e..284c50f7e90a 100644 --- a/ui/tests/acceptance/access/identity/_shared-alias-tests.js +++ b/ui/tests/acceptance/access/identity/_shared-alias-tests.js @@ -74,6 +74,4 @@ export const testAliasDeleteFromForm = (name, itemType, assert) => { assert.equal(aliasIndexPage.items.filterBy('id', aliasID).length, 0, `${itemType}: the row does not show in the list`); aliasIndexPage.flashMessage.latestMessage.startsWith('Successfully deleted', `${itemType}: shows flash message`); }); - - }; diff --git a/ui/tests/unit/components/identity/edit-form-test.js b/ui/tests/unit/components/identity/edit-form-test.js index 157627af7ec0..82aae87cdb3a 100644 --- a/ui/tests/unit/components/identity/edit-form-test.js +++ b/ui/tests/unit/components/identity/edit-form-test.js @@ -54,22 +54,20 @@ let testCases = [ expected: 'vault.cluster.access.identity.aliases.show', }, ]; -test('it computes cancelLink properly', function(assert) { - let component = this.subject(); - let model; - - testCases.forEach(testCase => { - model = Ember.Object.create({ - identityType: testCase.identityType, - rollbackAttributes: sinon.spy(), - }); +testCases.forEach(function(testCase) { + let model = Ember.Object.create({ + identityType: testCase.identityType, + rollbackAttributes: sinon.spy(), + }); + test(`it computes cancelLink properly: ${testCase.identityType} ${testCase.mode}`, function(assert) { + let component = this.subject(); component.set('mode', testCase.mode); component.set('model', model); assert.equal( component.get('cancelLink'), testCase.expected, - `${testCase.identityType} ${testCase.mode}: cancel link is correct` + 'cancel link is correct' ); }); });