Method
_prunetraceback
(
self, excinfo: _pytest._code.ExceptionInfo[BaseException]
)
Source from the content-addressed store, hash-verified
| 320 | delattr(self._testcase, self.name) |
| 321 | |
| 322 | def _prunetraceback( |
| 323 | self, excinfo: _pytest._code.ExceptionInfo[BaseException] |
| 324 | ) -> None: |
| 325 | super()._prunetraceback(excinfo) |
| 326 | traceback = excinfo.traceback.filter( |
| 327 | lambda x: not x.frame.f_globals.get("__unittest") |
| 328 | ) |
| 329 | if traceback: |
| 330 | excinfo.traceback = traceback |
| 331 | |
| 332 | |
| 333 | @hookimpl(tryfirst=True) |
Callers
nothing calls this directly
Tested by
no test coverage detected