(
self: AbstractRaises[BaseExcT_1],
exception: BaseExcT_1,
)
| 461 | return self._fail_reason |
| 462 | |
| 463 | def _check_check( |
| 464 | self: AbstractRaises[BaseExcT_1], |
| 465 | exception: BaseExcT_1, |
| 466 | ) -> bool: |
| 467 | if self.check is None: |
| 468 | return True |
| 469 | |
| 470 | if self.check(exception): |
| 471 | return True |
| 472 | |
| 473 | check_repr = "" if self._nested else " " + repr_callable(self.check) |
| 474 | self._fail_reason = f"check{check_repr} did not return True" |
| 475 | return False |
| 476 | |
| 477 | # TODO: harmonize with ExceptionInfo.match |
| 478 | def _check_match(self, e: BaseException) -> bool: |
no test coverage detected