{"name":"@vue/test-utils","version":"2.0.0-alpha.4","license":"MIT","main":"dist/vue-test-utils.cjs.js","browser":"dist/vue-test-utils.browser.js","unpkg":"dist/vue-test-utils.browser.js","types":"dist/index.d.ts","module":"dist/vue-test-utils.esm-bundler.js","dependencies":{"dom-event-types":"^1.0.0","lodash":"^4.17.15"},"devDependencies":{"@babel/core":"^7.9.0","@babel/preset-env":"^7.8.4","@babel/types":"^7.8.3","@rollup/plugin-commonjs":"^11.1.0","@rollup/plugin-json":"^4.0.3","@rollup/plugin-node-resolve":"^7.1.3","@rollup/plugin-replace":"^2.3.2","@types/estree":"^0.0.42","@types/jest":"^24.9.1","@types/lodash":"^4.14.149","@types/node":"12.12.35","@vue/compiler-sfc":"^3.0.0-beta.10","babel-jest":"^25.2.3","babel-preset-jest":"^25.2.1","flush-promises":"^1.0.2","husky":"^4.2.3","jest":"^25.1.0","jsdom":"^16.2.2","jsdom-global":"^3.0.2","lint-staged":"^10.0.9","prettier":"^2.0.2","rollup":"^1.31.1","rollup-plugin-typescript2":"^0.26.0","ts-jest":"^25.0.0","tsd":"0.11.0","typescript":"^3.7.5","vue":"^3.0.0-beta.10","vue-jest":"vuejs/vue-jest#next","vuex":"^4.0.0-beta.1"},"peerDependencies":{"@vue/compiler-sfc":"^3.0.0-beta.10","vue":"^3.0.0-beta.10"},"author":{"name":"Lachlan Miller","email":"lachlan.miller.1990@outlook.com"},"scripts":{"test":"yarn jest --runInBand tests","test:build":"yarn jest --runInBand tests -use-build","tsd":"tsd","build":"yarn rollup -c rollup.config.js","lint":"prettier -c --parser typescript \"(src|tests)/**/*.ts?(x)\"","lint:fix":"yarn lint --write"},"husky":{"hooks":{"pre-commit":"lint-staged"}},"lint-staged":{"*.ts":["prettier --parser=typescript --write"]},"tsd":{"directory":"test-dts","compilerOptions":{"strict":false,"lib":["esnext","dom"]}},"readmeFilename":"README.md","readme":"# vue-test-utils-next\n\nThe next iteration of Vue Test Utils. It targets Vue 3.\n\n## Installation and Usage\n\n- yarn: `yarn add @vue/test-utils@next --dev`\n- npm: `npm install @vue/test-utils@next --save-dev`\n\n## Coming from Vue 2 + Vue Test Utils beta?\n\nWe are working on some documentation to help people migrate. At this point it will you will have better luck trying this out with a brand new Vue 3 app, as opposed to upgrading an existing Vue 2 app. Feedback and bug reports are welcome!\n\n## Working with `.vue` files\n\nThere is [`vue-jest`](https://github.com/vuejs/vue-jest) for loading `.vue` files into Jest. The `next` branch contains support for Vue 3. Install it with `yarn add vue-jest@next`. It lacks support for some things, namely JSX. \n\nIf you don't want to configure things, you can download a repository with Vue 3, `@vue/test-utils@next`, `vue-jest@next` and TypeScript configured [here](https://github.com/lmiller1990/vtu-next-demo).\n\n## Docs\n\nDocs are located in [this repo](https://github.com/vuejs/vue-test-utils-next-docs). Read them [here](https://vuejs.github.io/vue-test-utils-next-docs/guide/introduction.html). They are in a separate repository because running Vuepress alongside a repo with Vue 3 causes conflicts - Vuepress expects to be running against Vue 2. This seems like the most simple solution for now.\n\n## Development\n\nIt's a pretty small codebase at the moment. Get started by running `yarn install`. You can run the tests with `yarn test`. That's it!\n\nThere is a lot of work to do. See issues for some basic TODOs, or the table at the bottom of this page.\n\n## What works?\n\nSee the [docs](https://vuejs.github.io/vue-test-utils-next-docs/guide/introduction.html). Most basic DOM interactions work. Advanced features like `shallowMount` and `stubs` are a work in progress.\n\n## Contributing\n\nThis is still very much alpha - if you want to add a feature, have a hack or ping someone in Discord to chat, or check out the issues and project board.\n\n## Where is shallowMount\n\nIt's coming soon. We are working on it. Stay tuned!\n\n## Comparsion with Vue Test Utils beta (targeting Vue 2)\n\nThis is table for those coming from VTU beta, comparing the two APIs. A lot of things are still a work in progress.\n\n- ✅ - implemented\n- ❌ - not yet implemented\n- ⚰️ - will not be implemented (if you have a compelling use case, please open an issue)\n\n### Mounting Options\n\n| option | status | notes |\n|---------|-------|------|\ndata | ✅\nslots | ✅ | has not been tested vigorously. Please try it out.\nmocks | ✅ | nested in [`global`](https://vuejs.github.io/vue-test-utils-next-docs/api/#global)\npropsData | ✅ | now called `props`\nprovide | ✅ | nested in [`global`](https://vuejs.github.io/vue-test-utils-next-docs/api/#global)\nmixins | ✅ | (new!) nested in [`global`](https://vuejs.github.io/vue-test-utils-next-docs/api/#global)\nplugins | ✅ | (new!) nested in [`global`](https://vuejs.github.io/vue-test-utils-next-docs/api/#global)\ncomponent | ✅ | (new!) nested in [`global`](https://vuejs.github.io/vue-test-utils-next-docs/api/#global)\ndirectives | ✅ | (new!) nested in [`global`](https://vuejs.github.io/vue-test-utils-next-docs/api/#global)\nstubs | ✅ \nattachToDocument |✅| renamed `attachTo`. See [here](https://github.com/vuejs/vue-test-utils/pull/1492)\nattrs | ✅ \nscopedSlots | ⚰️ | scopedSlots are merged with slots in Vue 3\ncontext | ⚰️ | different from Vue 2, does not make sense anymore.\nlocalVue | ⚰️ | may not make sense anymore since we do not mutate the global Vue instance in Vue 3.\nlisteners | ⚰️ | no longer exists in Vue 3\nparentComponent | ⚰️ |\n\n\n### Wrapper API (mount)\n\n| method | status | notes |\n|---------|-------|------|\nattributes | ✅\nclasses | ✅  \nexists | ✅\nfind | ✅ | only `querySelector` syntax is supported. `find(Comp)` under discussion [here](https://github.com/vuejs/vue-test-utils/issues/1498)\nemitted | ✅\nfindAll | ✅ | see above. `.vm` is different to Vue 2. We are exploring options.\nget | ✅\nhtml | ✅\nsetValue | ✅ | works for select, checkbox, radio button, input, textarea. Returns `nextTick`.\ntext | ✅ |\ntrigger | ✅ | returns `nextTick`. You can do `await wrapper.find('button').trigger('click')`\nsetProps | ✅ |\nprops | ✅\nsetData | ❌ | has PR\ndestroy | ✅ | renamed to `unmount` to match Vue 3 lifecycle hook name.\nprops | ✅ \ncontains | ⚰️| use `find` \nemittedByOrder | ⚰️ | use `emitted`\nsetSelected | ⚰️ | now part of `setValue` \nsetChecked | ⚰️| now part of `setValue` \nis | ⚰️ \nisEmpty | ⚰️ | use matchers such as [this](https://github.com/testing-library/jest-dom#tobeempty)\nisVisible | ⚰️ | use matchers such as [this](https://github.com/testing-library/jest-dom#tobevisible)\nisVueInstance | ⚰️ \nname | ⚰️ |\nsetMethods | ⚰️ | \n","description":"The next iteration of Vue Test Utils. It targets Vue 3.","_id":"@vue/test-utils@2.0.0-alpha.4","dist":{"shasum":"591b8ceaa648323fabfcbea48728999e5b33e7de","integrity":"sha512-9fAQx0MNhgqcNdcbh8xhyCywsWMd2zny4qpGCrgyOcB9s3V2xgjjtwUN72VbvaLnpdZk3mBwFOchNNe0oociNw==","tarball":"http://registry-npm.ywwl.com/@vue/test-utils/download/@vue/test-utils-2.0.0-alpha.4.tgz","fileCount":26,"unpackedSize":153260,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJetSU8CRA9TVsSAnZWagAA/BIP/0GTtdPYxoF4URL5epWX\nKOqnYtuXWXPH9s4lYKi0bzsMbBf9WWSdZ6P2S+RnOsJW/Q9sItjrIGfls98c\ngODFnT8HDxSmwxBkXczF+R8TY6GiUuQAUDrguklXCYA75ITuJ13JopIYPMtR\nHd+1I3sXCZNPRcYqJeAB2rK3tBcJn9cK3QNBe9Dh/8YjD+utRh8j+r0MZfH1\nkAccBcKFYlMgAkPNs2BueVm3UzdI3DgNYf/xg9iOEG7BH0YCc4XubZ44F0wW\nZKCtqjUIPMVnIuBkFpcft63DUwTEDYWeoqHiiOb6XPzGY59vqThglrP+TohV\nAwJrQGq6ni6UFK6Hwn3RWNuFdHkvYNUtHwbotwVwmko24/CDYK2FAPFzsTbN\nRewzfTYU3Zd9bfR8/9aMjvDmwDt3y+dFKRgxyaV75C0AcQtFLU/6MsKahxUW\nn/iao5FsAC0QQz06n7xMyffTMulavoI3536KzBDN84xLxTd4obAOOhPeZ/uW\nbB36SWX/Ldem2m0RRqcdv7nsry+WNFB1QCImcMpYZx7EWuKCOfBI2udLv/di\nJxPvK8PT5joUWvmxJOcwaHx2wuiHWbGBQBcj/RloOOCIf/kdDVBO+SZkLBFz\nWDXIXVtlGoQNrSqbEhTAqdJ7EueI5DPZpZU4G8vIGjIjHdKkmMEsVBXyv1xb\nJVHa\r\n=HWEE\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDXGehnC2Mdi67p08OpogbrKY8O5xs4lwJeEbK6z1BLQwIgTeq6FyRWP2/pnnA6osS8bCSSCL0lxHHFCSSoaLqw1pU="}],"size":34951,"noattachment":false,"key":"/@vue/test-utils/-/@vue/test-utils-2.0.0-alpha.4.tgz"},"maintainers":[{"email":"dobri@digital-cult.com","name":"dobromir-hristov"},{"email":"edward.yerburgh@gmail.com","name":"eddyerburgh"},{"email":"lachlan.miller.1990@outlook.com","name":"lmiller1990"}],"_npmUser":{"name":"lmiller1990","email":"lachlan.miller.1990@outlook.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/test-utils_2.0.0-alpha.4_1588929851282_0.782635190854057"},"_hasShrinkwrap":false,"publish_time":1588929851401,"_cnpm_publish_time":1588929851401,"dist-tags":{"2.0.0-alpha.0":"2.0.0-alpha.0","2.0.0-alpha.1":"2.0.0-alpha.1","2.0.0-alpha.2":"2.0.0-alpha.2","2.0.0-alpha.3":"2.0.0-alpha.3","2.0.0-alpha.4":"2.0.0-alpha.4","2.0.0-alpha.8":"2.0.0-alpha.8","2.0.0-beta.1":"2.0.0-beta.1","2.0.0-beta.10":"2.0.0-beta.10","2.0.0-beta.12":"2.0.0-beta.12","2.0.0-beta.13":"2.0.0-beta.13","2.0.0-beta.2":"2.0.0-beta.2","2.0.0-beta.3":"2.0.0-beta.3","2.0.0-beta.4":"2.0.0-beta.4","2.0.0-beta.5":"2.0.0-beta.5","2.0.0-beta.7":"2.0.0-beta.7","2.0.0-beta.8":"2.0.0-beta.8","2.0.0-beta.9":"2.0.0-beta.9","2.0.0-rc.0":"2.0.0-rc.0","2.0.0-rc.1":"2.0.0-rc.1","2.0.0-rc.10":"2.0.0-rc.10","2.0.0-rc.11":"2.0.0-rc.11","2.0.0-rc.12":"2.0.0-rc.12","2.0.0-rc.14":"2.0.0-rc.14","2.0.0-rc.16":"2.0.0-rc.16","2.0.0-rc.18":"2.0.0-rc.18","2.0.0-rc.2":"2.0.0-rc.2","2.0.0-rc.3":"2.0.0-rc.3","2.0.0-rc.4":"2.0.0-rc.4","2.0.0-rc.5":"2.0.0-rc.5","2.0.0-rc.6":"2.0.0-rc.6","2.0.0-rc.7":"2.0.0-rc.7","2.0.0-rc.8":"2.0.0-rc.8","2.0.0-rc.9":"2.0.0-rc.9","2.4.0-alpha.0":"2.4.0-alpha.0","latest":"2.5.1","legacy":"1.3.6","next":"2.4.0-alpha.2","v2.4.0-alpha.2":"2.4.0-alpha.2"}}