Move shared code to testlib

Signed-off-by: Andrey Berezin <a.berezin@yadro.com>
This commit is contained in:
Andrey Berezin 2023-05-14 13:43:59 +03:00
parent d97a02d1d3
commit 997e768e92
69 changed files with 9213 additions and 64 deletions

View file

@ -1,6 +1,6 @@
from abc import ABC, abstractmethod
from contextlib import AbstractContextManager
from typing import Any
from typing import Any, Callable
class ReporterHandler(ABC):
@ -17,6 +17,17 @@ class ReporterHandler(ABC):
Step context.
"""
@abstractmethod
def step_decorator(self, name: str) -> Callable:
"""A step decorator from reporter.
Args:
name: Name of the step.
Returns:
decorator for the step
"""
@abstractmethod
def attach(self, content: Any, file_name: str) -> None:
"""Attach specified content with given file name to the test report.