@pytest.mark.network
def test_uninstall_from_reqs_file(script, tmpdir):
 script.scratch_path.join('test-req.txt').write((textwrap.dedent('\n            -e %s#egg=initools-dev\n            # and something else to test out:\n            PyLogo<0.4\n        ') % local_checkout('svn+http://svn.colorstudy.com/INITools/trunk', tmpdir.join('cache'))))
 result = script.pip('install', '-r', 'test-req.txt')
 script.scratch_path.join('test-req.txt').write((textwrap.dedent('\n            # -f, -i, and --extra-index-url should all be ignored by uninstall\n            -f http://www.example.com\n            -i http://www.example.com\n            --extra-index-url http://www.example.com\n\n            -e %s#egg=initools-dev\n            # and something else to test out:\n            PyLogo<0.4\n        ') % local_checkout('svn+http://svn.colorstudy.com/INITools/trunk', tmpdir.join('cache'))))
 result2 = script.pip('uninstall', '-r', 'test-req.txt', '-y')
 assert_all_changes(result, result2, [(script.venv / 'build'), (script.venv / 'src'), (script.scratch / 'test-req.txt'), (script.site_packages / 'easy-install.pth')])

@ pytest . mark . network def test_uninstall_from_reqs_file ( script , tmpdir ) : script . scratch_path . join ( 'test-req.txt' ) . write ( ( textwrap . dedent ( '\n            -e %s#egg=initools-dev\n            # and something else to test out:\n            PyLogo<0.4\n        ' ) % local_checkout ( 'svn+http://svn.colorstudy.com/INITools/trunk' , tmpdir . join ( 'cache' ) ) ) ) result = script . pip ( 'install' , '-r' , 'test-req.txt' ) script . scratch_path . join ( 'test-req.txt' ) . write ( ( textwrap . dedent ( '\n            # -f, -i, and --extra-index-url should all be ignored by uninstall\n            -f http://www.example.com\n            -i http://www.example.com\n            --extra-index-url http://www.example.com\n\n            -e %s#egg=initools-dev\n            # and something else to test out:\n            PyLogo<0.4\n        ' ) % local_checkout ( 'svn+http://svn.colorstudy.com/INITools/trunk' , tmpdir . join ( 'cache' ) ) ) ) result2 = script . pip ( 'uninstall' , '-r' , 'test-req.txt' , '-y' ) assert_all_changes ( result , result2 , [ ( script . venv / 'build' ) , ( script . venv / 'src' ) , ( script . scratch / 'test-req.txt' ) , ( script . site_packages / 'easy-install.pth' ) ] )
test uninstall from a requirements file .