Skip to content

Commit

Permalink
Get virtualenv location from output
Browse files Browse the repository at this point in the history
The Project class's implementation is a fucking mess. Avoid that.
  • Loading branch information
uranusjr committed Jul 12, 2018
1 parent b8dbe78 commit f711678
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/integration/test_install_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -359,10 +359,16 @@ def test_install_venv_project_directory(PipenvInstance, pypi):
os.environ["WORKON_HOME"] = workon_home.name
if "PIPENV_VENV_IN_PROJECT" in os.environ:
del os.environ["PIPENV_VENV_IN_PROJECT"]

c = p.pipenv("install six")
assert c.return_code == 0
project = Project()
assert Path(project.virtualenv_location).joinpath(".project").exists()

venv_loc = None
for line in c.err.splitlines():
if line.startswith("Virtualenv location:"):
venv_loc = Path(line.split(":", 1)[-1].strip())
assert venv_loc is not None
assert venv_loc.joinpath(".project").exists()


@pytest.mark.deploy
Expand Down

0 comments on commit f711678

Please sign in to comment.