Commit d6b2430b authored by Peter Astrand's avatar Peter Astrand

Make it possible to run test_subprocess.py on Python 2.2, which lacks...

Make it possible to run test_subprocess.py on Python 2.2, which lacks test_support.is_resource_enabled.
parent 978ec9a8
......@@ -384,7 +384,8 @@ class ProcessTestCase(unittest.TestCase):
def test_no_leaking(self):
# Make sure we leak no resources
if test_support.is_resource_enabled("subprocess") and not mswindows:
if not hasattr(test_support, "is_resource_enabled") \
or test_support.is_resource_enabled("subprocess") and not mswindows:
max_handles = 1026 # too much for most UNIX systems
else:
max_handles = 65
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment