Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion lib/oidc-utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,6 @@ class OidcUtils {
}
static setOidcStepOutputs(username, accessToken) {
core.setSecret(accessToken);
core.setSecret(username);
core.setOutput('oidc-token', accessToken);
core.setOutput('oidc-user', username);
}
Expand Down
1 change: 0 additions & 1 deletion src/oidc-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,6 @@ export class OidcUtils {

public static setOidcStepOutputs(username: string, accessToken: string): void {
core.setSecret(accessToken);
core.setSecret(username);
core.setOutput('oidc-token', accessToken);
core.setOutput('oidc-user', username);
}
Expand Down
4 changes: 2 additions & 2 deletions test/oidc-utils.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,10 @@ describe('OidcUtils', (): void => {
});

describe('setOidcStepOutputs', (): void => {
it('should export user/token as step output and secret', (): void => {
it('should export user/token as step output and mark token as secret', (): void => {
OidcUtils.setOidcStepOutputs('foo', 'bar');
expect(core.setSecret).toHaveBeenCalledWith('bar');
expect(core.setSecret).toHaveBeenCalledWith('foo');
expect(core.setSecret).not.toHaveBeenCalledWith('foo');
expect(core.setOutput).toHaveBeenCalledWith('oidc-token', 'bar');
expect(core.setOutput).toHaveBeenCalledWith('oidc-user', 'foo');
});
Expand Down
Loading