-
Notifications
You must be signed in to change notification settings - Fork 136
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
migrate unittest to pytest #438
Conversation
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.
Looks great! Just a few small things 🎉
NOTE: It looks like pytest
isn't picking up test files that don't contain the test_
prefix. Could files without the prefix have one added?
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!
@@ -41,7 +40,7 @@ def mock_cli( | |||
# We need this to suppress warnings for operations that don't | |||
# have access to the cli.suppress_warnings attribute. | |||
# e.g. operation defaults | |||
sys.argv.append("--suppress-warnings") | |||
# sys.argv.append("--suppress-warnings") |
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 we can add a bit context on why it needs to be removed here for visibility.
""" | ||
Test if the bash completion renders correctly | ||
""" | ||
# mocker = mocker.patch('linodecli-completion.get_bash_completions', return_value=self.bash_expected) |
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.
nit: it seems can be cleaned up.
Changed the file naming instead for consistency. E.g. configuration.py -> test_configuration.py |
📝 Description
removed unittest library dependencies in all unit tests
removed unittest command from Makefile
✔️ How to Test
What are the steps to reproduce the issue or verify the changes?
make testunit
📷 Preview
If applicable, include a screenshot or code snippet of this change. Otherwise, please remove this section.