add test case for special chars

This commit is contained in:
JM Faircloth 2023-06-08 08:56:22 -05:00
parent dc4f72debb
commit 83200f4fb1
4 changed files with 36 additions and 0 deletions

View file

@ -207,6 +207,19 @@ describe('exportSecrets', () => {
expect(core.setOutput).toBeCalledWith('key', '1');
});
it('special chars secret retrieval', async () => {
const secret = 'abc$xyz';
mockInput('test key');
mockVaultData({
key: secret
});
await exportSecrets();
expect(core.exportVariable).toBeCalledWith('KEY', secret);
expect(core.setOutput).toBeCalledWith('key', secret);
});
it('encoded secret retrieval', async () => {
mockInput('test key');
mockVaultData({