From c53d9e76feb6ff0ff0236762dfe482787969bffa Mon Sep 17 00:00:00 2001 From: Jason O'Donnell <2160810+jasonodonnell@users.noreply.github.com> Date: Mon, 10 Aug 2020 11:07:39 -0400 Subject: [PATCH] Fix tests --- .github/workflows/build.yml | 6 ++--- .../enterprise/enterprise.test.js | 22 ++++++++----------- 2 files changed, 12 insertions(+), 16 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 784ca86..c587940 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -151,9 +151,9 @@ jobs: url: http://localhost:8200 token: testtoken secrets: | - secret/data/test altSecret ; - secret/data/test altSecret | NAMED_ALTSECRET ; - secret/data/nested/test otherAltSecret ; + my-secret/test altSecret ; + my-secret/test altSecret | NAMED_ALTSECRET ; + my-secret/nested/test otherAltSecret ; - name: Test Vault Action (cubbyhole) uses: ./ diff --git a/integrationTests/enterprise/enterprise.test.js b/integrationTests/enterprise/enterprise.test.js index 90ad22c..b791022 100644 --- a/integrationTests/enterprise/enterprise.test.js +++ b/integrationTests/enterprise/enterprise.test.js @@ -56,7 +56,7 @@ describe('integration', () => { }); it('get simple secret', async () => { - mockInput('test secret'); + mockInput('secret/data/test secret'); await exportSecrets(); @@ -64,7 +64,7 @@ describe('integration', () => { }); it('re-map secret', async () => { - mockInput('test secret | TEST_KEY'); + mockInput('secret/data/test secret | TEST_KEY'); await exportSecrets(); @@ -72,7 +72,7 @@ describe('integration', () => { }); it('get nested secret', async () => { - mockInput('nested/test otherSecret'); + mockInput('secret/data/nested/test otherSecret'); await exportSecrets(); @@ -81,9 +81,9 @@ describe('integration', () => { it('get multiple secrets', async () => { mockInput(` - test secret ; - test secret | NAMED_SECRET ; - nested/test otherSecret ;`); + secret/data/test secret ; + secret/data/test secret | NAMED_SECRET ; + secret/data/nested/test otherSecret ;`); await exportSecrets(); @@ -95,9 +95,7 @@ describe('integration', () => { }); it('get secret from K/V v1', async () => { - mockInput('test secret'); - mockEngineName('my-secret'); - mockVersion('1'); + mockInput('my-secret/test secret'); await exportSecrets(); @@ -105,9 +103,7 @@ describe('integration', () => { }); it('get nested secret from K/V v1', async () => { - mockInput('nested/test otherSecret'); - mockEngineName('my-secret'); - mockVersion('1'); + mockInput('my-secret/nested/test otherSecret'); await exportSecrets(); @@ -229,7 +225,7 @@ describe('authenticate with approle', () => { }); it('authenticate with approle', async() => { - mockInput('test secret'); + mockInput('secret/data/test secret'); await exportSecrets();