5
0
Fork 0
mirror of https://github.com/hashicorp/vault-action.git synced 2025-11-14 18:13:45 +00:00

Fix tests

This commit is contained in:
Jason O'Donnell 2020-08-10 11:07:39 -04:00
parent 2eff75fabd
commit c53d9e76fe
2 changed files with 12 additions and 16 deletions

View file

@ -151,9 +151,9 @@ jobs:
url: http://localhost:8200 url: http://localhost:8200
token: testtoken token: testtoken
secrets: | secrets: |
secret/data/test altSecret ; my-secret/test altSecret ;
secret/data/test altSecret | NAMED_ALTSECRET ; my-secret/test altSecret | NAMED_ALTSECRET ;
secret/data/nested/test otherAltSecret ; my-secret/nested/test otherAltSecret ;
- name: Test Vault Action (cubbyhole) - name: Test Vault Action (cubbyhole)
uses: ./ uses: ./

View file

@ -56,7 +56,7 @@ describe('integration', () => {
}); });
it('get simple secret', async () => { it('get simple secret', async () => {
mockInput('test secret'); mockInput('secret/data/test secret');
await exportSecrets(); await exportSecrets();
@ -64,7 +64,7 @@ describe('integration', () => {
}); });
it('re-map secret', async () => { it('re-map secret', async () => {
mockInput('test secret | TEST_KEY'); mockInput('secret/data/test secret | TEST_KEY');
await exportSecrets(); await exportSecrets();
@ -72,7 +72,7 @@ describe('integration', () => {
}); });
it('get nested secret', async () => { it('get nested secret', async () => {
mockInput('nested/test otherSecret'); mockInput('secret/data/nested/test otherSecret');
await exportSecrets(); await exportSecrets();
@ -81,9 +81,9 @@ describe('integration', () => {
it('get multiple secrets', async () => { it('get multiple secrets', async () => {
mockInput(` mockInput(`
test secret ; secret/data/test secret ;
test secret | NAMED_SECRET ; secret/data/test secret | NAMED_SECRET ;
nested/test otherSecret ;`); secret/data/nested/test otherSecret ;`);
await exportSecrets(); await exportSecrets();
@ -95,9 +95,7 @@ describe('integration', () => {
}); });
it('get secret from K/V v1', async () => { it('get secret from K/V v1', async () => {
mockInput('test secret'); mockInput('my-secret/test secret');
mockEngineName('my-secret');
mockVersion('1');
await exportSecrets(); await exportSecrets();
@ -105,9 +103,7 @@ describe('integration', () => {
}); });
it('get nested secret from K/V v1', async () => { it('get nested secret from K/V v1', async () => {
mockInput('nested/test otherSecret'); mockInput('my-secret/nested/test otherSecret');
mockEngineName('my-secret');
mockVersion('1');
await exportSecrets(); await exportSecrets();
@ -229,7 +225,7 @@ describe('authenticate with approle', () => {
}); });
it('authenticate with approle', async() => { it('authenticate with approle', async() => {
mockInput('test secret'); mockInput('secret/data/test secret');
await exportSecrets(); await exportSecrets();