<s> """<STR_LIT>""" <EOL> import os <EOL> import pytest <EOL> from tests . lib import pyversion , assert_all_changes <EOL> @ pytest . mark . network <EOL> def test_debian_egg_name_workaround ( script ) : <EOL> """<STR_LIT>""" <EOL> result = script . pip ( '<STR_LIT>' , '<STR_LIT>' , expect_error = True ) <EOL> egg_info = os . path . join ( <EOL> script . site_packages , "<STR_LIT>" % pyversion ) <EOL> assert egg_info in result . files_created , "<STR_LIT>" % egg_info <EOL> mangled = os . path . join ( script . site_packages , "<STR_LIT>" ) <EOL> assert mangled not in result . files_created , "<STR_LIT>" % mangled <EOL> full_egg_info = os . path . join ( script . base_path , egg_info ) <EOL> assert os . path . isdir ( full_egg_info ) <EOL> full_mangled = os . path . join ( script . base_path , mangled ) <EOL> os . renames ( full_egg_info , full_mangled ) <EOL> assert os . path . isdir ( full_mangled ) <EOL> result2 = script . pip ( "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" ) <EOL> assert_all_changes ( result , result2 , [ script . venv / '<STR_LIT>' , '<STR_LIT>' ] ) <EOL> def test_setup_py_with_dos_line_endings ( script , data ) : <EOL> """<STR_LIT>""" <EOL> to_install = data . packages . join ( "<STR_LIT>" ) <EOL> script . pip ( '<STR_LIT>' , to_install , expect_error = False ) </s>
