mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
Issue #10440: Support RUSAGE_THREAD as a constant in the resource module.
Patch by Robert Collins.
This commit is contained in:
parent
dc817b229c
commit
b6d4ee5361
4 changed files with 22 additions and 4 deletions
|
@ -102,6 +102,10 @@ class ResourceTest(unittest.TestCase):
|
|||
usageboth = resource.getrusage(resource.RUSAGE_BOTH)
|
||||
except (ValueError, AttributeError):
|
||||
pass
|
||||
try:
|
||||
usage_thread = resource.getrusage(resource.RUSAGE_THREAD)
|
||||
except (ValueError, AttributeError):
|
||||
pass
|
||||
|
||||
def test_main(verbose=None):
|
||||
support.run_unittest(ResourceTest)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue