[#132] Add steps logger and refactor reporter usage

Signed-off-by: Andrey Berezin <a.berezin@yadro.com>
This commit is contained in:
Andrey Berezin 2023-11-28 12:28:44 +03:00 committed by Andrey Berezin
parent 47414eb866
commit 39a17f3634
9 changed files with 163 additions and 16 deletions

View file

@ -1,5 +1,5 @@
from abc import ABC, abstractmethod
from contextlib import AbstractContextManager
from contextlib import AbstractContextManager, ContextDecorator
from typing import Any, Callable
@ -7,7 +7,7 @@ class ReporterHandler(ABC):
"""Interface of handler that stores test artifacts in some reporting tool."""
@abstractmethod
def step(self, name: str) -> AbstractContextManager:
def step(self, name: str) -> AbstractContextManager | ContextDecorator:
"""Register a new step in test execution.
Args: