Skip to content

Commit

Permalink
tests:utils - update ExceptionManager tests
Browse files Browse the repository at this point in the history
  • Loading branch information
MatteoCampinoti94 committed Nov 21, 2023
1 parent 011c096 commit cf67268
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,11 @@ def test_helpers():
assert isinstance(raises.value, FileNotFoundError)
assert isinstance(context.exception, FileNotFoundError)

with ExceptionManager(BaseException, FileNotFoundError, allow=[OSError]) as context:
raise FileNotFoundError

assert isinstance(context.exception, FileNotFoundError)

with ExceptionManager() as context:
pass

Expand Down

0 comments on commit cf67268

Please sign in to comment.