forked from vuejs-templates/webpack
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Jest as new unit test runner, keep Karma + Mocha as a fallback (v…
…uejs-templates#824) * refactor: replace karma and mocha with jest * refactor: remove webpack.test.conf * refactor: prompt jest instead of mocha and karma * feat(jest): add coverage reporting * docs(jest): update unit.md with details of jest * docs(jest): remove karma files from structure.md * docs(jest): replace details on Karma with details on Jest * docs: add missing period * docs(jest): replace karma with Jest in commands.md * docs(jest): update npm run unit bullet points * refactor: use module-resolver in place of jest moduleNameMapper * refactor: remove .vue extension from Hello import * test: include src files in test coverage * test: only ignore router/index in coverage if router option selected * chore: fix merge conflicts * chore: add MIT free Jest * Reference dev script in start script instead of copy pasting (vuejs-templates#894) Less duplication FTW. * feat: add karma option * refactor: use const in webpack.test.conf * add version tag to config/index.js * stick to ES5 this file is not transpiled * Bumping Vue+VueRouter versions, some minor fixes. (vuejs-templates#986) * switch hello-world tag to PascalCase (vuejs-templates#951) * fix Es6 code issue. This file is not transpiled, so we should stick to ES5 * Fix bug in dev-server when a proxyTable entry is a string (vuejs-templates#965) `options` can not be a `const` because it is modified if value is a string. * Fix casing * Revert 9befbfc * update to vue and vue-router latest version (vuejs-templates#984) - vue 2.5 - vue-router 3.0 * Fix missing dependency bumps (vuejs-templates#987) * switch hello-world tag to PascalCase (vuejs-templates#951) * fix Es6 code issue. This file is not transpiled, so we should stick to ES5 * Fix bug in dev-server when a proxyTable entry is a string (vuejs-templates#965) `options` can not be a `const` because it is modified if value is a string. * Fix casing * Revert 9befbfc * update to vue and vue-router latest version (vuejs-templates#984) - vue 2.5 - vue-router 3.0 * fix missing dependency updates for * vue-template compiler * vue-loader * bump version string * refactor: use jest module mapping * feat(jest): filter jest setup file * fix: fix trailing comma * docs: add Jest and Karma to unit section * fix: add Jest options if jest option * test: change env in .eslintrc * fix: remove merge trace * fix: merge package.json with develop * docs: split unit test docs into Jest and Karma * docs: add Karma and Jest to README * docs: reimplement karma files in structure.md
- Loading branch information
1 parent
166e5fa
commit 1ce066c
Showing
14 changed files
with
121 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
|
||
'use strict' | ||
// Template version: 1.1.3 | ||
// see http://vuejs-templates.github.io/webpack for documentation. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
{ | ||
"env": { | ||
"mocha": true | ||
}, | ||
"env": {{{#if_eq runner "karma"}} | ||
"mocha": true{{/if_eq}}{{#if_eq runner "jest"}} | ||
"jest"{{/if_eq}} | ||
}{{#if_eq runner "karma"}}, | ||
"globals": { | ||
"expect": true, | ||
"sinon": true | ||
} | ||
"sinon": true, | ||
"jest": true | ||
}{{/if_eq}} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import Vue from 'vue' | ||
|
||
Vue.config.productionTip = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters