Skip to content
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

Added canonicalize_name() to console/commands/init.py #5076

Merged
merged 9 commits into from
Jan 29, 2022
Merged

Added canonicalize_name() to console/commands/init.py #5076

merged 9 commits into from
Jan 29, 2022

Commits on Jan 29, 2022

  1. Added canonicalize_name() to console/commands/init.py

    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    fe6ffe6 View commit details
    Browse the repository at this point in the history
  2. Removed unnecessary helper function calls

    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    773b4ec View commit details
    Browse the repository at this point in the history
  3. Fixed capitalized package bug on poetry init

    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
    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    d3ffb97 View commit details
    Browse the repository at this point in the history
  4. Split out _get_choice_list to a separate function

    For testing purposes
    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    9a194d9 View commit details
    Browse the repository at this point in the history
  5. Tests working with canonicalized_name assigned outside of _generate_c…

    …hoice_list()
    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    6b2b88c View commit details
    Browse the repository at this point in the history
  6. Changed test_generate_choice_list

    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
    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    a5ada29 View commit details
    Browse the repository at this point in the history
  7. Added output message if choice_list is truncated

    Also added cases for truncation and non-truncation in
    test_generate_choice_list to ensure the message is printed in only the
    correct cases
    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    814aede View commit details
    Browse the repository at this point in the history
  8. Removed info_string calls

    Moved info_string generation logic out of init._generate_choice_list
    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    88f3cc4 View commit details
    Browse the repository at this point in the history
  9. Removed type hint for info_string

    Evan Rittenhouse committed Jan 29, 2022
    Configuration menu
    Copy the full SHA
    82d4b11 View commit details
    Browse the repository at this point in the history