Skip to content

Commit

Permalink
Tweak warning text.
Browse files Browse the repository at this point in the history
  • Loading branch information
cjerdonek committed Oct 3, 2017
1 parent 055261d commit e455b36
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/pip/_internal/vcs/git.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ def check_rev_options(self, dest, rev_options):
# the form of a Git commit hash.
if not looks_like_hash(rev):
logger.warning(
"Did not find branch or tag '%s', assuming commit or ref.",
"Did not find branch or tag '%s', assuming ref or revision.",
rev,
)

Expand Down
4 changes: 2 additions & 2 deletions tests/functional/test_install_vcs_git.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,9 @@ def test_check_rev_options_not_found_warning(get_refs_mock, caplog):

# Check that a warning got logged only for the abbreviated hash.
messages = [r.getMessage() for r in caplog.records]
messages = [msg for msg in messages if 'assuming commit' in msg]
messages = [msg for msg in messages if msg.startswith('Did not find ')]
assert messages == [
"Did not find branch or tag 'aaaaaa', assuming commit or ref."
"Did not find branch or tag 'aaaaaa', assuming ref or revision."
]


Expand Down

0 comments on commit e455b36

Please sign in to comment.