Skip to content

Commit b79f652

Browse files
committed
only raise errors if there are any
1 parent 85594a7 commit b79f652

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/_pytest/unraisableexception.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ def collect_unraisable() -> None:
6363

6464
if len(errors) == 1:
6565
raise errors[0]
66-
else:
66+
if errors:
6767
raise ExceptionGroup("multiple unraisable exception warnings", errors)
6868
finally:
6969
del errors, unraisable

0 commit comments

Comments
 (0)