@pytest.mark.network
def test_pip_wheel_fail_cause_of_previous_build_dir(script, data):
 script.pip('install', 'wheel')
 build = ((script.venv_path / 'build') / 'simple')
 os.makedirs(build)
 write_delete_marker_file((script.venv_path / 'build'))
 build.join('setup.py').write('#')
 result = script.pip('wheel', '--no-index', ('--find-links=%s' % data.find_links), '--build', (script.venv_path / 'build'), 'simple==3.0', expect_error=True)
 assert (result.returncode == PREVIOUS_BUILD_DIR_ERROR), result

@ pytest . mark . network def test_pip_wheel_fail_cause_of_previous_build_dir ( script , data ) : script . pip ( 'install' , 'wheel' ) build = ( ( script . venv_path / 'build' ) / 'simple' ) os . makedirs ( build ) write_delete_marker_file ( ( script . venv_path / 'build' ) ) build . join ( 'setup.py' ) . write ( '#' ) result = script . pip ( 'wheel' , '--no-index' , ( '--find-links=%s' % data . find_links ) , '--build' , ( script . venv_path / 'build' ) , 'simple==3.0' , expect_error = True ) assert ( result . returncode == PREVIOUS_BUILD_DIR_ERROR ) , result
test when pip wheel tries to install a package that has a previous build directory .