Skip to content
This repository was archived by the owner on Nov 2, 2022. It is now read-only.

Commit 3756f42

Browse files
committed
update unit tests.
1 parent 6a8832e commit 3756f42

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

exceptiongroup/_tests/test_exceptiongroup.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,15 @@ def test_exception_group_init():
1414
assert group.sources == [str(memberA), str(memberB)]
1515

1616

17+
def test_exception_group_when_members_are_not_exceptions():
18+
with pytest.raises(TypeError):
19+
ExceptionGroup(
20+
"error",
21+
[RuntimeError("RuntimeError"), "error2"],
22+
["RuntimeError", "error2"],
23+
)
24+
25+
1726
def test_exception_group_init_when_length_of_args_is_less_than_3():
1827
with pytest.raises(ValueError):
1928
ExceptionGroup("error")

0 commit comments

Comments
 (0)