def METHOD_NAME(self, func):
    """Calls func and succeeds if and only if no exception is raised
    (i.e. converts exception raising into a failed testcase). Returns
    the return value of func."""
    try:
        return func()
    except Exception as exc:
        self.fail(str(exc))