def test_no_upgrade_unless_requested(script):
 script.pip('install', 'INITools==0.1', expect_error=True)
 result = script.pip('install', 'INITools', expect_error=True)
 assert (not result.files_created), 'pip install INITools upgraded when it should not have'

def test_no_upgrade_unless_requested ( script ) : script . pip ( 'install' , 'INITools==0.1' , expect_error = True ) result = script . pip ( 'install' , 'INITools' , expect_error = True ) assert ( not result . files_created ) , 'pip install INITools upgraded when it should not have'
no upgrade if not specifically requested .