Skip to content

How can I determine immediately after a check if it passed or failed? #187

@ALPA-Industry-and-Technology

Description

Hi,

I’m using pytest-check and I would like to know if there is a way to determine right after calling a check (e.g. check.equal(a, b)) whether that check succeeded or failed, so that I can react in my test logic immediately.

check.any_failures() only gives me a global status for the whole test, but I need to know the result of each individual check right after it runs.

Is there a recommended way to achieve this? Or would I need to wrap the check functions myself (e.g. with check.fail() and a custom return value)?

Thanks!

With best regards
Alex

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions