faust.livecheck.runners

LiveCheck - Test runner.

class faust.livecheck.runners.TestRunner(case: faust.livecheck.runners._Case, test: faust.livecheck.models.TestExecution, started: float) → None[source]

Execute and keep track of test instance.

state = 'INIT'
report = None
error = None
async execute() → None[source]

Execute this test.

Return type

None

async skip(reason: str) → NoReturn[source]

Skip this test execution.

Return type

_NoReturn

async on_skipped(exc: faust.livecheck.exceptions.TestSkipped) → None[source]

Call when a test execution was skipped.

Return type

None

async on_start() → None[source]

Call when a test starts executing.

Return type

None

async on_signal_wait(signal: faust.livecheck.signals.BaseSignal, timeout: float) → None[source]

Call when the test is waiting for a signal.

Return type

None

async on_signal_received(signal: faust.livecheck.signals.BaseSignal, time_start: float, time_end: float) → None[source]

Call when a signal related to this test is received.

Return type

None

async on_failed(exc: BaseException) → None[source]

Call when an invariant in the test has failed.

Return type

None

async on_error(exc: BaseException) → None[source]

Call when test execution raises error.

Return type

None

async on_timeout(exc: BaseException) → None[source]

Call when test execution times out.

Return type

None

async on_pass() → None[source]

Call when test execution returns successfully.

Return type

None

log_info(msg: str, *args: Any) → None[source]

Log information related to the current execution.

Return type

None

end() → None[source]

End test execution.

Return type

None