Skip to content

Commit

Permalink
First setuptools, then wheel - not both at once.
Browse files Browse the repository at this point in the history
  • Loading branch information
jsirois committed Oct 2, 2018
1 parent fc82496 commit b2a2121
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions tests/test_environment.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,16 @@ def bad_interpreter(include_site_extras=True):

interpreter = bad_interpreter(include_site_extras=False)
with ENV.patch(PEX_VERBOSE='9'):
with temporary_dir()as cache:
with temporary_dir() as cache:
# We need to run the bad interpreter with a modern, non-Apple-Extras setuptools in order to
# successfully install psutil.
for dist in resolver.resolve([SETUPTOOLS_REQUIREMENT, WHEEL_REQUIREMENT],
cache=cache,
# We can't use wheels since we're bootstrapping them.
precedence=(SourcePackage, EggPackage),
interpreter=interpreter):
interpreter = interpreter.with_extra(dist.key, dist.version, dist.location)
for requirement in (SETUPTOOLS_REQUIREMENT, WHEEL_REQUIREMENT):
for dist in resolver.resolve([requirement],
cache=cache,
# We can't use wheels since we're bootstrapping them.
precedence=(SourcePackage, EggPackage),
interpreter=interpreter):
interpreter = interpreter.with_extra(dist.key, dist.version, dist.location)

with nested(yield_pex_builder(installer_impl=WheelInstaller, interpreter=interpreter),
temporary_filename()) as (pb, pex_file):
Expand Down

0 comments on commit b2a2121

Please sign in to comment.