def METHOD_NAME(self):
    self.assertRaises(TypeError, resource.getrusage)
    self.assertRaises(TypeError, resource.getrusage, 42, 42)
    usageself = resource.getrusage(resource.RUSAGE_SELF)
    usagechildren = resource.getrusage(resource.RUSAGE_CHILDREN)
    # May not be available on all systems.
    try:
        usageboth = resource.getrusage(resource.RUSAGE_BOTH)
    except (ValueError, AttributeError):
        pass
    try:
        usage_thread = resource.getrusage(resource.RUSAGE_THREAD)
    except (ValueError, AttributeError):
        pass