Skip to content

Retry until  #751

@lvijnck

Description

@lvijnck

Hi,

I'm wondering whether there exists functionality to keep retrying the test under certain condition. This is especially relevant for APIs with long running 'asynchronous' tasks, i.e., consider the following endpoints:

  1. /create endpoint that accepts the task and immediately yields a 200 status
  2. /status endpoint that returns the status of the job, e.g., IN_PROGRESS, SUCCESS and FAILED

I'd like to express a test that keeps re-trying the /status endpoint until the status is either SUCCESS or FAILED. This could indeed be achieved with the retry functionality, but that would result in a rather flaky test as the duration of the task varies heavily.

P.S. Happy to contribute after discussion.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions