Skip to content

Commit 1dd211e

Browse files
authored
feat(unit-jest): add jest as a peer dependency (#6625)
Eventually we need to update to Jest 27 + vue2-jest / vue3-jest So let's make it a peer dependency to ease the pain of breaking changes. To not surprise existing beta users, jest 26 is still listed as a direct dependency in the next release.
1 parent cf1022d commit 1dd211e

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

packages/@vue/cli-plugin-unit-jest/generator/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ module.exports = (api, options, rootOptions, invoking) => {
1212
'test:unit': 'vue-cli-service test:unit'
1313
},
1414
devDependencies: {
15+
'jest': '^26.6.3',
1516
'vue-jest': isVue3 ? '^5.0.0-0' : '^4.0.1',
1617
'@vue/test-utils': isVue3 ? '^2.0.0-0' : '^1.1.3'
1718
},

packages/@vue/cli-plugin-unit-jest/migrator/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
/** @param {import('@vue/cli/lib/MigratorAPI')} api MigratorAPI */
22
module.exports = (api) => {
33
api.extendPackage(pkg => {
4-
const newDevDeps = {}
4+
const newDevDeps = {
5+
'jest': '^26.6.3'
6+
}
57

68
const allDeps = {
79
...pkg.dependencies,

packages/@vue/cli-plugin-unit-jest/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
},
4242
"peerDependencies": {
4343
"@vue/cli-service": "^3.0.0 || ^4.0.0 || ^5.0.0-0",
44+
"jest": "^26.3.3",
4445
"ts-jest": "^26.5.3",
4546
"vue-jest": "^4.0.1 || ^5.0.0-0"
4647
},

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy