Added canonicalize_name() to console/commands/init.py#5076
Merged
finswimmer merged 9 commits intopython-poetry:masterfrom Jan 29, 2022
evanrittenhouse:master
Merged
Added canonicalize_name() to console/commands/init.py#5076finswimmer merged 9 commits intopython-poetry:masterfrom evanrittenhouse:master
finswimmer merged 9 commits intopython-poetry:masterfrom
evanrittenhouse:master
Conversation
finswimmer
requested changes
Jan 21, 2022
Member
finswimmer
left a comment
There was a problem hiding this comment.
Thanks a lot. Looks good to me 👍
As discussed here my suggestion for a test:
You can take the test_interactive_with_dependencies as an example and play around with adding packages to the repo, give different spelling (upper/lower cases) of the package you search and always expect to find it in the first position.
neersighted
previously requested changes
Jan 21, 2022
finswimmer
requested changes
Jan 24, 2022
finswimmer
reviewed
Jan 25, 2022
finswimmer
reviewed
Jan 28, 2022
finswimmer
reviewed
Jan 29, 2022
added 9 commits
January 29, 2022 12:40
Used canonicalize_name to standardize the names of all packages in poetry init with interactive dependencies. Given its importance, added a test_canoncalize_name() test to tests/utils/test_helpers.py
For testing purposes
Parameterized a _generate_choice_list_packages fixture in order to call the test with both > 10 and < 10 cases, verifying that output is <= 10 and the package_name has the desired package first in choices
Also added cases for truncation and non-truncation in test_generate_choice_list to ensure the message is printed in only the correct cases
Moved info_string generation logic out of init._generate_choice_list
finswimmer
approved these changes
Jan 29, 2022
Member
finswimmer
left a comment
There was a problem hiding this comment.
Thanks a lot for your contribution. Looks good to me 👍
Merged
3 tasks
|
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Pull Request Check List
Resolves: #5035
Resolves: #5033