From 6e02043ca68d7c00962247a41c6f9183fd556713 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Thu, 27 Jan 2022 06:09:53 -0500 Subject: test: bpo 46028 only is a problem under very specific circumstances --- tests/test_venv.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/test_venv.py b/tests/test_venv.py index c90ac76a..6e997be2 100644 --- a/tests/test_venv.py +++ b/tests/test_venv.py @@ -6,6 +6,7 @@ import os import os.path import shutil +import sys import pytest @@ -160,7 +161,11 @@ def coverage_command_fixture(request): # https://bugs.python.org/issue46028 -@pytest.mark.xfail((3, 11, 0, 'alpha', 4, 0) == env.PYVERSION, reason="avoid 3.11 bug: bpo46028") +@pytest.mark.xfail( + (3, 11, 0, 'alpha', 4, 0) == env.PYVERSION and + not os.path.exists(sys._base_executable), + reason="avoid 3.11 bug: bpo46028" +) class VirtualenvTest(CoverageTest): """Tests of virtualenv considerations.""" -- cgit v1.2.1