-
Notifications
You must be signed in to change notification settings - Fork 668
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
Use of Array.prototype.includes breaks unit tests in browsers that do not support this. #608
Comments
Thanks for the issue. Would you like to make a PR replacing |
@eddyerburgh Sure I will. I found |
We can't run tests against ie11 on CircleCI. One solution would be to use eslint-compat to check for methods that aren't supported in ie11. |
I think it resolve this issue to use babel instead of buble. |
The decision to use buble was because it generates more readable output. We could revisit and compare the output to seen if babel output is readable enough. |
This issue is fixed and will be in the next release. I think we should keep buble for now, although we can reinvestigate when we move the repo to typescript. |
Version
1.0.0-beta.16
Reproduction link
https://codesandbox.io/s/7ykvrxrw0
Steps to reproduce
What is expected?
Tests should pass or fail, but not be terminated.
What is actually happening?
Test is terminated due to "TypeError: Object doesn't support property or method 'includes"
Same as #499 which reports use of 'Array.prototype.find'.
The specific line is:
https://github.com/vuejs/vue-test-utils/blob/v1.0.0-beta.16/packages/test-utils/src/wrapper.js#L519
Array.prototype.includes supported browsers:
https://caniuse.com/#search=Array.prototype.includes
The text was updated successfully, but these errors were encountered: