Skip to content

Commit 7179d49

Browse files
authored
fix
1 parent 66a097c commit 7179d49

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/_pytest/recwarn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ def __enter__(self) -> Self:
265265
if isinstance(message, str):
266266
kw.update(message=message)
267267
if module is not None:
268-
module = cast(str, re.Pattern, module)
268+
module = cast(str | re.Pattern, module)
269269
if isinstance(module, re.Pattern):
270270
module = getattr(module, "pattern", None)
271271
if isinstance(module, str):

0 commit comments

Comments
 (0)