Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the audience flag required in test token #221

Merged
merged 3 commits into from
Apr 2, 2021

Conversation

Widcket
Copy link
Contributor

@Widcket Widcket commented Apr 1, 2021

Description

In the test token command, if the --audience flag is missing, the command will produce no tokens unless there is a default audience set in the tenant.
This PR makes that flag required, so that the command will always produce a token.

Testing

  • This change adds test coverage for new/changed/fixed functionality

Checklist

  • I have added documentation for new/changed functionality in this PR or in auth0.com/docs
  • All active GitHub checks for tests, formatting, and security are passing
  • The correct base branch is being used, if not master

@Widcket Widcket requested a review from a team April 1, 2021 23:15
@@ -157,7 +165,7 @@ func testTokenCmd(cli *cli) *cobra.Command {
Short: "Fetch a token for the given client and API",
Long: `Fetch an access token for the given client.
If --client-id is not provided, the default client "CLI Login Testing" will be used (and created if not exists).
Additionally, you can also specify the --audience and --scope to use.`,
Additionally, you can also specify the --audience (API Identifer) and --scope to use.`,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO Additionally, you can also specify makes it sound like this isn't required.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! Thanks

@Widcket Widcket requested a review from as-herzog April 2, 2021 17:56
Copy link
Contributor

@cyx cyx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@Widcket Widcket merged commit fbce21f into main Apr 2, 2021
@Widcket Widcket deleted the required-audience-test-token branch April 2, 2021 18:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants