-
Notifications
You must be signed in to change notification settings - Fork 669
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
Always store selector in Wrapper created by wrapper.find(...) #1135
Comments
This is a great idea :) Would you like to implement it @gitlab-winnie ? |
I can't make any Promise yet but have to await my workload for the next month. Definitely interested in getting my feet wet at the Vue test utils beach though. 🏖 |
I started working on this in #1248. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What problem does this feature solve?
When using
wrapper.find(...)
, the returned new wrapper only knows the selector if nothing was found. This makes it difficult to debug tests with dynamic selectors and to create custom matchers likeexpect(wrapper.find('.something')).toExist()
.What does the proposed API look like?
Make Wrapper always have a
selector
property when created with.find(...)
—not onlyErrorWrapper
(vue-test-utils/packages/test-utils/src/error-wrapper.js
Line 9 in 36adbf3
The text was updated successfully, but these errors were encountered: