Skip to content

Extend prefer-explicit-assert to report findBy* and waitFor #409

@zaicevas

Description

@zaicevas

With prefer-explicit-assert enabled, getBy* usages without expect are reported, but findBy* and waitFor are not reported:

    screen.getByText('hey') // reported
    await waitFor(() => screen.getByText('hey')) // not reported
    await screen.findByText('hey') // not reported

What if we extended prefer-explicit-assert to report all of the above cases? 🤔

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions