Commit c9301355 authored by Benjamin Peterson's avatar Benjamin Peterson

remove uneeded function

parent 2dc90fdf
......@@ -373,14 +373,14 @@ class TestCase(object):
result.addSkip(self, str(e))
return
except Exception:
result.addError(self, self._exc_info())
result.addError(self, sys.exc_info())
return
success = False
try:
testMethod()
except self.failureException:
result.addFailure(self, self._exc_info())
result.addFailure(self, sys.exc_info())
except _ExpectedFailure as e:
result.addExpectedFailure(self, e.exc_info)
except _UnexpectedSuccess:
......@@ -388,14 +388,14 @@ class TestCase(object):
except SkipTest as e:
result.addSkip(self, str(e))
except Exception:
result.addError(self, self._exc_info())
result.addError(self, sys.exc_info())
else:
success = True
try:
self.tearDown()
except Exception:
result.addError(self, self._exc_info())
result.addError(self, sys.exc_info())
success = False
if success:
result.addSuccess(self)
......@@ -411,13 +411,6 @@ class TestCase(object):
getattr(self, self._testMethodName)()
self.tearDown()
def _exc_info(self):
"""Return a version of sys.exc_info() with the traceback frame
minimised; usually the top level of the traceback frame is not
needed.
"""
return sys.exc_info()
def skip(self, reason):
"""Skip this test."""
raise SkipTest(reason)
......
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