Skip to content

output

TmuxOutput(func, timeout, delay)

Bases: object

Sucharge some operator to add @retry property

Parameters:

Name Type Description Default
func Callable[..., str]

function used to get the value to use when required

required
timeout Union[int, float]

how long to wait for the operator call to fail

required
delay Union[int, float]

how long before retrying the operator call

required

Returns:

Type Description

a TmuxOutput instance

Source code in pytest_tmux/output.py
45
46
47
48
49
50
51
52
53
54
def __init__(
    self,
    func: Callable[..., str],
    timeout: Union[int, float],
    delay: Union[int, float],
) -> None:
    self.func = func
    self.value = self.func()
    self.__timeout = timeout
    self.__delay = delay