Skip to content

Include actionability waits in before commands #270

@Andarist

Description

@Andarist

I've noticed some flaky tests in our codebase and I think that I've diagnosed them to be related to the fact that cypress-real-events do not wait for "actionability" of the item.

There is no related logic in the realClick's implementation:
https://github.com/dmtrKovalenko/cypress-real-events/blob/660025b0dac4e69ef6a982eeb0a26e025d3a7696/src/commands/realClick.ts
but we can see in Cypress' click implementation that it includes such logic by default:
https://github.com/cypress-io/cypress/blob/380f4e7d6036fc4fbd8c1443c011cb8414b231a7/packages/driver/src/cy/commands/actions/click.ts#L193

I've spotted this in my Cypress report and it seems to verify my conclusion:
Screenshot 2022-06-14 at 10 29 25

I could work on adding the actionability waits if you agree that this is something that should be included by default. The API of $actionability.verify looks a little bit weird and perhaps you would have some tips as to how I could actually use it here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions