Skip to content

Commit

Permalink
pr stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
olamothe committed Oct 16, 2023
1 parent 8543c92 commit 191e622
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions packages/cli/core/src/commands/auth/token.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ describe('auth:token', () => {
test
.stdout()
.stderr()
.stub(CliUx.ux, 'prompt', () => async () => 'someToken')
.stub(CliUx.ux, 'prompt', () => () => 'someToken')
.command(['auth:token', '-e', environment])
.it(`writes the -e=${environment} flag to the configuration`, () => {
expect(mockConfigSet).toHaveBeenCalledWith('environment', environment);
Expand All @@ -80,7 +80,7 @@ describe('auth:token', () => {
test
.stdout()
.stderr()
.stub(CliUx.ux, 'prompt', () => async () => 'someToken')
.stub(CliUx.ux, 'prompt', () => () => 'someToken')
.command(['auth:token', '-r', region])
.it(`writes the -r=${region} flag and configuration`, () => {
expect(mockConfigSet).toHaveBeenCalledWith(
Expand All @@ -94,7 +94,7 @@ describe('auth:token', () => {
test
.stdout()
.stderr()
.stub(CliUx.ux, 'prompt', () => async () => 'this-is-the-token')
.stub(CliUx.ux, 'prompt', () => () => 'this-is-the-token')
.command(['auth:token'])
.it('save token from oauth service', () => {
expect(mockConfigSet).toHaveBeenCalledWith(
Expand All @@ -111,7 +111,7 @@ describe('auth:token', () => {
.do(() => {
mockGetHasAccessToOrg.mockReturnValueOnce(Promise.resolve(true));
})
.stub(CliUx.ux, 'prompt', () => async () => 'some-token')
.stub(CliUx.ux, 'prompt', () => () => 'some-token')
.command(['auth:token'])
.it(
'succeed when the organization and the token flags are valid',
Expand All @@ -128,7 +128,7 @@ describe('auth:token', () => {
})
.stdout()
.stderr()
.stub(CliUx.ux, 'prompt', () => async () => 'some-token')
.stub(CliUx.ux, 'prompt', () => () => 'some-token')
.command(['auth:token'])
.it(
'find the org associated with the token and saves it in the config',
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/core/src/commands/auth/token.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default class Token extends CLICommand {
stdin: Flags.boolean({
char: 's',
description:
'Read the token from stdin. Default to true when running in a CI environment.',
'Whether to read the token from stdin. Default to true when running in a CI environment.',
default: process.env.CI === 'true',
}),
};
Expand Down

0 comments on commit 191e622

Please sign in to comment.