Skip to content

Conversation

kandros
Copy link
Contributor

@kandros kandros commented Oct 5, 2019

What:

Improve error messages for .toBeInTheDocument

Why:

The current error was hard to understand

How:

Give more context in the error message

Checklist:

  • Documentation N/A
  • Tests N/A
  • Updated Type Definitions N/A
  • Ready to be merged

Before

.toBeInTheDocument
Screenshot 2019-10-05 at 12 29 08

not.toBeInTheDocument
Screenshot 2019-10-05 at 12 28 05

After

.toBeInTheDocument
Screenshot 2019-10-05 at 12 18 15

not.toBeInTheDocument
Screenshot 2019-10-05 at 12 52 13

@gnapse
Copy link
Member

gnapse commented Oct 31, 2019

@kandros I'll be merging this soon. It totally slipped off my mind, sorry for the long delay.

@gnapse
Copy link
Member

gnapse commented Oct 31, 2019

Not sure why the build here is taking forever. Invoking @testing-library/core-maintainers in case someone there can chime in on what went wrong.

@kentcdodds
Copy link
Member

I'm not sure. I wouldn't worry about it. Just merge if you're happy with the changes :)

@gnapse gnapse merged commit c12a476 into testing-library:master Nov 1, 2019
@gnapse
Copy link
Member

gnapse commented Nov 1, 2019

🎉 This PR is included in version 4.2.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants