#NEWLINE# @ patch ( 'pybuilder.plugins.python.install_dependencies_plugin.get_package_version' , return_value = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) #NEWLINE# @ patch ( 'pybuilder.plugins.python.install_dependencies_plugin.execute_command' , return_value = 0 ) #NEWLINE# def test_should_install_dependency_with_url_even_if_version_is_given( self , exec_command , get_package_version ) : #NEWLINE# #INDENT# dependency = Dependency ( 'spam' , version = '0.1.2' , url = 'some_url' ) #NEWLINE# install_dependency ( self . logger , self . project , get_package_version ) #NEWLINE# exec_command ( ( PIP_EXEC_STANZA + [ 'install' , '--force-reinstall' , 'some_url' ] ) , ANY , env = ANY , shell = False )