diff --git a/allure-python-commons/src/_allure.py b/allure-python-commons/src/_allure.py index 05e01dbd..04092385 100644 --- a/allure-python-commons/src/_allure.py +++ b/allure-python-commons/src/_allure.py @@ -1,5 +1,5 @@ from functools import wraps -from typing import Any, Callable, TypeVar +from typing import Any, Callable, TypeVar, Union from allure_commons._core import plugin_manager from allure_commons.types import LabelType, LinkType, ParameterMode @@ -161,7 +161,7 @@ def manual(): return Dynamic.label(LabelType.MANUAL, True) -def step(title): +def step(title: Union[str, _TFunc]): if callable(title): return StepContext(title.__name__, {})(title) else: