diff --git a/tmt/steps/report/junit.py b/tmt/steps/report/junit.py index 1e204d4a39..89a742569b 100644 --- a/tmt/steps/report/junit.py +++ b/tmt/steps/report/junit.py @@ -100,11 +100,6 @@ def __getattr__(self, name: str) -> Any: return getattr(self._wrapped, name) -def _add_result_properties(result_instance: tmt.Result) -> ResultWrapper: - """ Dynamically decorate the :py:class:`tmt.Result` instance - add ``properties`` attribute """ - return ResultWrapper(result_instance) - - class ResultsContext: """ The results context for Jinja templates. @@ -115,7 +110,7 @@ class ResultsContext: def __init__(self, results: list[tmt.Result]) -> None: # Decorate all the tmt.Results with more attributes - self._results: list[ResultWrapper] = [_add_result_properties(r) for r in results] + self._results: list[ResultWrapper] = [ResultWrapper(r) for r in results] def __iter__(self) -> Iterator[ResultWrapper]: """ Possibility to iterate over results by iterating an instance """