feat: Seed commands tests, rework projects internals#189
Merged
Conversation
cacd044 to
8aa1211
Compare
The focus of this diff is to seed example tests using the responses library for the commands.py file, which currently has no test coverage. The `projects` and `submit` command, which are among the more utilized functions are used here as examples. In the process of adding tests, the projects internals in commands.py was found to be confusing and made to be more intuitive. A deprecation warning is attached to the `-i` option in the `projects` command. Instead of requiring an input which is unused, this turns out into a flag and renamed to `--names`.
8aa1211 to
f77bd5e
Compare
ramu-phanimukla
suggested changes
Jan 20, 2021
Contributor
ramu-phanimukla
left a comment
There was a problem hiding this comment.
Looks good with few nits and questions/clarifications.
Contributor
Author
|
@ramu-phanimukla I reworked this slightly to separate out the responsibilities of Let me know what you think, I can roll it out to the submit function as well if that makes sense. |
Contributor
Author
|
@ramu-phanimukla CI wasn't passing due to an unfixed dependency causing a regression. I've fixed it and it passes now. Other than that, no other changes, would appreciate a re-review. thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The focus of this diff is to seed example tests using the responses
library for the commands.py file, which currently has no test coverage.
The
projectsandsubmitcommand, which are among the more utilizedfunctions are used here as examples.
In the process of adding tests, the projects internals in commands.py
was found to be confusing and made to be more intuitive.
A deprecation warning is attached to the
-ioption in theprojectscommand. Instead of requiring an input which is unused, this turns out
into a flag and renamed to
--names.