mirror of
https://github.com/pypa/pip
synced 2023-12-13 21:30:23 +01:00
Add a test that checks for mixed upper and lower case letters
in pip show Remove useless import in stubs for named tests
This commit is contained in:
parent
9b6c0ea8ff
commit
a05de613fc
4 changed files with 26 additions and 1 deletions
|
@ -0,0 +1 @@
|
|||
#
|
6
tests/data/src/required_by_mixed_capitalization/setup.py
Normal file
6
tests/data/src/required_by_mixed_capitalization/setup.py
Normal file
|
@ -0,0 +1,6 @@
|
|||
from setuptools import setup
|
||||
|
||||
setup(name='requires_Capitalized',
|
||||
version='0.1',
|
||||
install_requires=['simple==1.0']
|
||||
)
|
|
@ -1,4 +1,4 @@
|
|||
from setuptools import find_packages, setup
|
||||
from setuptools import setup
|
||||
|
||||
setup(name='Requires_Capitalized',
|
||||
version='0.1',
|
||||
|
|
|
@ -236,3 +236,21 @@ def test_show_required_by_packages_capitalized(script, data):
|
|||
|
||||
assert 'Name: simple' in lines
|
||||
assert 'Required-by: Requires-Capitalized' in lines
|
||||
|
||||
|
||||
def test_show_required_by_with_mixed_capitalization(script, data):
|
||||
"""
|
||||
Test that installed packages that depend on this package are shown
|
||||
where the package requires a name with a mix of
|
||||
lower and upper case letters
|
||||
"""
|
||||
editable_path = os.path.join(data.src, 'required_by_mixed_capitalization')
|
||||
script.pip(
|
||||
'install', '--no-index', '-f', data.find_links, editable_path
|
||||
)
|
||||
|
||||
result = script.pip('show', 'Requires_CapitalizeD')
|
||||
lines = result.stdout.splitlines()
|
||||
|
||||
assert 'Name: Requires-Capitalized' in lines
|
||||
assert 'Required-by: simple' in lines
|
||||
|
|
Loading…
Reference in a new issue