Skip to content

Commit

Permalink
Fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
igrek51 committed Jul 11, 2024
1 parent 949fe83 commit f8c0911
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/asserts.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
from nuclear.utils.strings import strip_ansi_colors


def assert_error(action, error_type: Type[Exception] = RuntimeError, expected_msg: str | None = None):
def assert_error(action, error_type: Type[Exception] = RuntimeError, expected_msg: Optional[str] = None):
try:
action()
assert False, 'should raise error'
Expand All @@ -21,7 +21,7 @@ def assert_error(action, error_type: Type[Exception] = RuntimeError, expected_ms
assert expected_msg in str(e), 'unexpected error message'


def assert_cli_error(action, expected_error: str | None = None):
def assert_cli_error(action, expected_error: Optional[str] = None):
assert_error(action, CliError, expected_error)


Expand Down

0 comments on commit f8c0911

Please sign in to comment.