forked from TrueCloudLab/frostfs-testlib
Rename neofs to frostfs
Signed-off-by: Yulia Kovshova <y.kovshova@yadro.com>
This commit is contained in:
parent
5a2c7ac98d
commit
6d3b6f0f2f
83 changed files with 330 additions and 338 deletions
28
src/frostfs_testlib/reporter/interfaces.py
Normal file
28
src/frostfs_testlib/reporter/interfaces.py
Normal file
|
@ -0,0 +1,28 @@
|
|||
from abc import ABC, abstractmethod
|
||||
from contextlib import AbstractContextManager
|
||||
from typing import Any
|
||||
|
||||
|
||||
class ReporterHandler(ABC):
|
||||
"""Interface of handler that stores test artifacts in some reporting tool."""
|
||||
|
||||
@abstractmethod
|
||||
def step(self, name: str) -> AbstractContextManager:
|
||||
"""Register a new step in test execution.
|
||||
|
||||
Args:
|
||||
name: Name of the step.
|
||||
|
||||
Returns:
|
||||
Step context.
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
def attach(self, content: Any, file_name: str) -> None:
|
||||
"""Attach specified content with given file name to the test report.
|
||||
|
||||
Args:
|
||||
content: Content to attach. If content value is not a string, it will be
|
||||
converted to a string.
|
||||
file_name: File name of attachment.
|
||||
"""
|
Loading…
Add table
Add a link
Reference in a new issue