Skip to content

Commit

Permalink
Removing config command and replacing single usage in integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
willvedd committed Nov 29, 2022
1 parent ba9eb4d commit 2851b6f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 135 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ test-unit: ## Run unit tests
test-integration: $(GO_BIN)/commander ## Run integration tests. To run a specific test pass the FILTER var. Usage: `make test-integration FILTER="attack protection"`
${call print, "Running integration tests"}
@$(MAKE) install # ensure fresh install prior to running test
auth0 config init && commander test ./test/integration/test-cases.yaml --filter "$(FILTER)"; \
auth0 tenants add $\AUTH0_CLI_CLIENT_DOMAIN --client-id $\AUTH0_CLI_CLIENT_ID --client-secret $\AUTH0_CLI_CLIENT_SECRET && commander test ./test/integration/test-cases.yaml --filter "$(FILTER)"; \
exit_code=$$?; \
bash ./test/integration/scripts/test-cleanup.sh; \
exit $$exit_code
Expand Down
133 changes: 0 additions & 133 deletions internal/cli/config.go

This file was deleted.

1 change: 0 additions & 1 deletion internal/cli/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@ func addSubcommands(rootCmd *cobra.Command, cli *cli) {
// relevance or relation with other commands:
rootCmd.AddCommand(loginCmd(cli))
rootCmd.AddCommand(logoutCmd(cli))
rootCmd.AddCommand(configCmd(cli))
rootCmd.AddCommand(tenantsCmd(cli))
rootCmd.AddCommand(appsCmd(cli))
rootCmd.AddCommand(usersCmd(cli))
Expand Down
5 changes: 5 additions & 0 deletions internal/cli/tenants.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,8 @@ func addTenantCmd(cli *cli) *cobra.Command {
inputs.Domain = args[0]
}

fmt.Println(inputs)

if err := tenantClientID.Ask(cmd, &inputs.ClientID, nil); err != nil {
return err
}
Expand All @@ -203,6 +205,9 @@ func addTenantCmd(cli *cli) *cobra.Command {
},
}

tenantClientID.RegisterString(cmd, &inputs.ClientID, "")
tenantClientSecret.RegisterString(cmd, &inputs.ClientSecret, "")

return cmd
}

Expand Down

0 comments on commit 2851b6f

Please sign in to comment.