You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm migrating vue2 to vue3 (test utils too)
In vue2 if I had global plugin that was installed with createLocalVue then it was accessible under wrapper.vm (e.g wrapper.vm.$logger), in vue3 if i pass plugin to global.plugins then it is passed correctly to tested component, but in the test itself I don't have access to it so e.g I can't mock it
It works though for external provider plugins like vuetify (wrapper.vm.$vuetify is there)
Do you think you could look into it and open a PR? We would gladly review it and merge it. The test file I mentioned is a good place to try to add your repro and see if you still reproduce the issue.
Describe the bug
I'm migrating vue2 to vue3 (test utils too)
In vue2 if I had global plugin that was installed with
createLocalVue
then it was accessible underwrapper.vm
(e.gwrapper.vm.$logger
), in vue3 if i pass plugin toglobal.plugins
then it is passed correctly to tested component, but in the test itself I don't have access to it so e.g I can't mock itIt works though for external provider plugins like vuetify (
wrapper.vm.$vuetify
is there)To Reproduce
https://stackblitz.com/edit/github-guxdre-g64fcl?file=src%2Fcomponents%2F__tests__%2FHelloWorld.spec.ts
In test file see console.log
Expected behavior
Global plugin is accessible e.g
wrapper.vm.$logger
The text was updated successfully, but these errors were encountered: