-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Vue unit test cleanup, removing jquery, mocking ajax calls #10904
Conversation
Oh yeah, unleash the @Nerdinacan! |
08190b6
to
4dc16c4
Compare
…helper which accessed document
4dc16c4
to
65a60d0
Compare
Our client-side unit tests still need a lot of attention, but they'll probably have to be addressed one at a time. These global changes are ready now, however. |
jest-haste-map: duplicate manual mock found: index The following files share their name; please delete one of them: * <rootDir>/src/app/__mocks__/index.js * <rootDir>/src/components/History/caching/__mocks__/index.js
@dannon |
@Nerdinacan Hah, yeah, same -- I just never got around to it and now I'm in "silence all the warnings" mode. |
…ay we can still get other warnings.
mocked directives for bs-vue tips/popovers
…rying to load user). Still not great, but now everything passes and there are zero warnings. Also shallowmount.
I like what you've done with the place. |
This PR was merged without a "kind/" label, please correct. |
There's a lot of client-side unit tests that die or become erratic due to unnecessary 3rd party library usage or unmocked ajax calls.
Jest doesn't run in a browser, it runs in node, and code that expects to talk to native browser objects (like document or XHR) either dies or runs without response. This is particularly problematic when jQuery is used. I'll be removing that first, then moving on to all the multitudes of unmocked ajax calls.
Notable changes: