@pytest.mark.network
def test_git_with_branch_name_as_revision(script):
 version_pkg_path = _create_test_package(script)
 script.run('git', 'checkout', '-b', 'test_branch', expect_stderr=True, cwd=version_pkg_path)
 _change_test_package_version(script, version_pkg_path)
 script.pip('install', '-e', ('%s@test_branch#egg=version_pkg' % ('git+file://' + version_pkg_path.abspath.replace('\\', '/'))))
 version = script.run('version_pkg')
 assert ('some different version' in version.stdout)

@ pytest . mark . network def test_git_with_branch_name_as_revision ( script ) : version_pkg_path = _create_test_package ( script ) script . run ( 'git' , 'checkout' , '-b' , 'test_branch' , expect_stderr = True , cwd = version_pkg_path ) _change_test_package_version ( script , version_pkg_path ) script . pip ( 'install' , '-e' , ( '%s@test_branch#egg=version_pkg' % ( 'git+file://' + version_pkg_path . abspath . replace ( '\\' , '/' ) ) ) ) version = script . run ( 'version_pkg' ) assert ( 'some different version' in version . stdout )
git backend should be able to install from branch names .