Skip to content

Commit 951e57e

Browse files
committed
Attempt to workaround yet another problem with PyPy tests
1 parent 19bfd4d commit 951e57e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

setuptools/tests/test_build_meta.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import os
2+
import sys
23
import shutil
34
import signal
45
import tarfile
@@ -14,6 +15,7 @@
1415

1516

1617
TIMEOUT = int(os.getenv("TIMEOUT_BACKEND_TEST", "180")) # in seconds
18+
IS_PYPY = '__pypy__' in sys.builtin_module_names
1719

1820

1921
class BuildBackendBase:
@@ -44,6 +46,10 @@ def method(*args, **kw):
4446
self.pool.shutdown(wait=False) # doesn't stop already running processes
4547
self._kill(pid)
4648
pytest.xfail(f"Backend did not respond before timeout ({TIMEOUT} s)")
49+
except (futures.process.BrokenProcessPool, MemoryError):
50+
if IS_PYPY:
51+
pytest.xfail("PyPy frequently fails tests with ProcessPoolExector")
52+
raise
4753

4854
return method
4955

0 commit comments

Comments
 (0)