Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Global custom query setup example breaks screen #1486

Open
@bogden1

Description

The setup example for adding custom queries globally for (at least) React seems to break screen-specific functionality such as screen.debug().

If I understand correctly (via testing-library/dom-testing-library#516 (comment)) this bit:

const customScreen = within(document.body, allQueries)

should be something like this:

const customScreen = { ...screen, ...within(document.body, allQueries) };

And of course that means you have to import screen, too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /