-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: closing isolated vue #1627
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, this is a lot of great stuff! I've left couple of minor comments and questions.
@@ -26,49 +26,46 @@ exports[`should filter list when search field contains a query 1`] = ` | |||
searchTerm="" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's get rid of these snashots — they aren't really testing anything ;-/ We used to have way too many but there's no reason to keep them ;-)
I think it's fine ;-) |
Codecov Report
|
Hello @sapegin, I hope you are well. |
The code is good now but I still see changes in a gigantic snapshot that I'd love to remove entirely ;-) |
Snapshots replaced with real RTL tests. I hope you like them. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is much better! Couple of suggestions.
expect(getAllByTestId('rsg-toc-link').length).toBe(6); | ||
fireEvent.change(getByPlaceholderText('Filter by name'), { target: { value: searchTerm } }); | ||
expect(getAllByTestId('rsg-toc-link').length).toBe(1); | ||
expect(getByTestId('rsg-toc-link').innerHTML).toBe('Forms'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
expect(getByTestId('rsg-toc-link').innerHTML).toBe('Forms'); | |
expect(getByTestId('rsg-toc-link')).toHaveTextContent('Forms'); |
expect(actual).toMatchSnapshot(); | ||
expect(getAllByTestId('rsg-toc-link').length).toBe(6); | ||
fireEvent.change(getByPlaceholderText('Filter by name'), { target: { value: searchTerm } }); | ||
expect(getAllByTestId('rsg-toc-link').length).toBe(1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
expect(getAllByTestId('rsg-toc-link').length).toBe(1); | |
expect(getAllByTestId('rsg-toc-link')). toHaveLength(1); |
); | ||
|
||
expect(actual).toMatchSnapshot(); | ||
expect(getAllByTestId('rsg-toc-link').length).toBe(6); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
expect(getAllByTestId('rsg-toc-link').length).toBe(6); | |
expect(getAllByTestId('rsg-toc-link')).toHaveLength(6); |
Agreed! Updated a few matchers |
Yay, merging! 🦄 |
🎉 This PR is included in version 11.0.9 🎉 The release is available on: Your semantic-release bot 📦🚀 |
fixes #1479
Remark For technical reasons, I had to remove the return from isolate button here: I could not access
href
without going through a context or a prop train.It looked logical to me: If there was only one action it should not be in two places.
With this change, it would be only on the top right. Tell me if you need a fix for it.