-
Notifications
You must be signed in to change notification settings - Fork 11
Isolate tests #131
Isolate tests #131
Conversation
main.go
Outdated
} | ||
|
||
for _, command := range []*cobra.Command{removeCmd} { | ||
command.PersistentFlags().Bool("suppress", false, "Suppress confirm") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe extend the description a little e.g. Suppress all confirmation dialogues
test/corectl_integration_test.go
Outdated
teardownTest := setupTest(t, tt) | ||
defer teardownTest(t, tt) | ||
|
||
// |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should there be a comment here? 😉
main.go
Outdated
confirmed = askForConfirmation(fmt.Sprintf("Do you really want to delete the app: %s?", app)) | ||
} | ||
|
||
if confirmed || viper.GetString("suppress") == "true" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe its easier if we let askForConfirmation
handle the suppress
flag? That way we don't need to implement this logic in all methods that would require a confirm dialog later on.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, good work! 🌮
No description provided.