Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
corona10 committed Oct 22, 2023
1 parent 691e5a7 commit d4f42d8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions pyperformance/tests/test_pythoninfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,12 @@ def test_venv(self):
expected = _pythoninfo._build_info(CURRENT)
if IS_VENV:
python = sys.executable
real_python = os.path.realpath(python)
else:
venv, python, cleanup = tests.create_venv()
real_python = os.path.realpath(python)
self.addCleanup(cleanup)
expected.sys.executable = python
expected.sys.executable = real_python
realpath = os.path.realpath(os.path.normpath(sys.executable))
if os.name == 'nt':
# It isn't a symlink.
Expand All @@ -78,7 +80,7 @@ def test_venv(self):
) = tuple(expected.sys.implementation.version)
expected.is_venv = True

info = _pythoninfo.get_info(python)
info = _pythoninfo.get_info(real_python)

# We have to work around a possible bug.
if not info.base_executable:
Expand Down

0 comments on commit d4f42d8

Please sign in to comment.