1
1
Fork 0
mirror of https://github.com/pypa/pip synced 2023-12-13 21:30:23 +01:00

Test that parse_requirements does not require a finder

This commit is contained in:
Donald Stufft 2014-08-30 17:20:21 -04:00
parent c53cfa1e28
commit e4d1228e47

View file

@ -257,3 +257,23 @@ def test_req_file_parse_egginfo_end_of_line_with_url(tmpdir):
assert len(reqs) == 1
assert reqs[0].name == "wat"
def test_req_file_no_finder(tmpdir):
"""
Test parsing a requirements file without a finder
"""
with open(tmpdir.join("req.txt"), "w") as fp:
fp.write("""
--find-links https://example.com/
--index-url https://example.com/
--extra-index-url https://two.example.com/
--no-use-wheel
--no-index
--allow-external foo
--allow-all-external
--allow-insecure foo
--allow-unverified foo
""")
parse_requirements(tmpdir.join("req.txt"), session=PipSession())