-
Notifications
You must be signed in to change notification settings - Fork 76
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
We should refactor the agent cli output #311
Conversation
Signed-off-by: chen hui <[email protected]>
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.
Can we write a test for -h
or --help
command?
Yes, it will help us to avoid such a bug again. Done. Please review it again. |
Signed-off-by: chen hui <[email protected]>
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
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.
Could we keep all flag-related tests in a single test file.?
We already have label_flag_test.go. And If we put label_flag_test.go and help_flag_test.go together, it would be huge file. And if we have any other flag test in the future, and all put in one file, it will became a super huge file. Don't think it is a good idea. |
Again no strong opinions, but IMO we are keeping a single test file for a package, here for agent |
Fixes #253
There are a lot of wrong flag for byoh-hostagent
After fix this, byoh-hostagent only has the following flags:
Plus, In order to avoid such a bug again, I add a test for --help command. Any unexpected option will caused the test failure.