mirror of
https://github.com/kennethreitz/pipenv.git
synced 2026-06-05 06:46:15 +00:00
Allow the use of many sources instead of just 2
- Fixes #2130 Signed-off-by: Dan Ryan <dan@danryan.co>
This commit is contained in:
@@ -111,3 +111,35 @@ def test_maintain_file_line_endings(PipenvInstance, pypi, newlines):
|
||||
actual_newlines, newlines, fn,
|
||||
)
|
||||
# message because of https://github.com/pytest-dev/pytest/issues/3443
|
||||
|
||||
|
||||
@pytest.mark.project
|
||||
@pytest.mark.sources
|
||||
def test_many_indexes(PipenvInstance, pypi):
|
||||
with PipenvInstance(pypi=pypi, chdir=True) as p:
|
||||
with open(p.pipfile_path, 'w') as f:
|
||||
contents = """
|
||||
[[source]]
|
||||
url = "{0}"
|
||||
verify_ssl = false
|
||||
name = "testindex"
|
||||
|
||||
[[source]]
|
||||
url = "https://pypi.org/simple"
|
||||
verify_ssl = "true"
|
||||
name = "pypi"
|
||||
|
||||
[[source]]
|
||||
url = "https://pypi.python.org/simple"
|
||||
verify_ssl = "true"
|
||||
name = "legacy"
|
||||
|
||||
[packages]
|
||||
pytz = "*"
|
||||
six = {{version = "*", index = "pypi"}}
|
||||
|
||||
[dev-packages]
|
||||
""".format(os.environ['PIPENV_TEST_INDEX']).strip()
|
||||
f.write(contents)
|
||||
c = p.pipenv('install')
|
||||
assert c.return_code == 0
|
||||
|
||||
Reference in New Issue
Block a user