Skip to content

Commit

Permalink
Add warning for test token when scopes are given to the cmd
Browse files Browse the repository at this point in the history
  • Loading branch information
sergiught committed Nov 14, 2023
1 parent a4b2a20 commit 51687a9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions internal/cli/test.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,10 @@ func testTokenCmd(cli *cli) *cobra.Command {
cli.renderer.Newline()

if client.GetAppType() == appTypeNonInteractive {
if len(inputs.Scopes) != 0 {
cli.renderer.Warnf("Passed in scopes do not apply to Machine to Machine applications.\n")
}

tokenResponse, err := runClientCredentialsFlow(cmd.Context(), cli, client, inputs.Audience, cli.tenant)
if err != nil {
return fmt.Errorf(
Expand Down

0 comments on commit 51687a9

Please sign in to comment.