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
Please note that if you are using Vue 2, `@vue/test-utils` requires a [slightly different configuration](#unit-test-components-vue-2).
106
+
103
107
You can find more examples in [the tests of the testing package](https://github.com/vuejs/pinia/blob/v2/packages/testing/src/testing.spec.ts).
104
108
105
109
## E2E tests
106
110
107
111
When it comes to pinia, you don't need to change anything for e2e tests, that's the whole point of e2e tests! You could maybe test HTTP requests, but that's way beyond the scope of this guide 😄.
112
+
113
+
## Unit test components (Vue 2)
114
+
115
+
When using [Vue Test Utils 1](https://v1.test-utils.vuejs.org/), install Pinia on a `localVue`:
116
+
117
+
```js
118
+
import { PiniaVuePlugin } from'pinia'
119
+
import { createLocalVue, mount } from'@vue/test-utils'
0 commit comments