def test_finder_deplink():
 req = InstallRequirement.from_line('gmpy==1.15', None)
 finder = PackageFinder([], [], process_dependency_links=True, session=PipSession())
 finder.add_dependency_links(['https://pypi.python.org/packages/source/g/gmpy/gmpy-1.15.zip'])
 link = finder.find_requirement(req, False)
 assert link.url.startswith('https://pypi'), link

def test_finder_deplink ( ) : req = InstallRequirement . from_line ( 'gmpy==1.15' , None ) finder = PackageFinder ( [ ] , [ ] , process_dependency_links = True , session = PipSession ( ) ) finder . add_dependency_links ( [ 'https://pypi.python.org/packages/source/g/gmpy/gmpy-1.15.zip' ] ) link = finder . find_requirement ( req , False ) assert link . url . startswith ( 'https://pypi' ) , link
test packagefinder with dependency links only .