| 240 | raise_exc_info(failure) |
| 241 | |
| 242 | def run( |
| 243 | self, result: Optional[unittest.TestResult] = None |
| 244 | ) -> Optional[unittest.TestResult]: |
| 245 | ret = super().run(result) |
| 246 | # As a last resort, if an exception escaped super.run() and wasn't |
| 247 | # re-raised in tearDown, raise it here. This will cause the |
| 248 | # unittest run to fail messily, but that's better than silently |
| 249 | # ignoring an error. |
| 250 | self.__rethrow() |
| 251 | return ret |
| 252 | |
| 253 | def _callTestMethod(self, method: Callable) -> None: |
| 254 | """Run the given test method, raising an error if it returns non-None. |