Last active
February 5, 2019 13:13
-
-
Save pablocattaneo/bf71e7f2ad7706d83389a21cd55312f0 to your computer and use it in GitHub Desktop.
Source: https://github.com/vuejs/vue-cli/issues/2504#issuecomment-421702758
https://www.npmjs.com/package/@vue/cli-plugin-unit-jest
This file contains hidden or 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
1 - sudo vue add @vue/unit-jest | |
2 - Clear Jest cache. You can find the cache location by running `jest --showConfig`. Look for `cacheDirectory` key. Its value is the name of the folder you'll need to remove. | |
3 - Create test files into project_name/tests/unit/. file must have this structure name.spec.js for example /home/pablo/projects/lumbre/lumbre-vue-admin/tests/unit/LmPagination.spec.js | |
4 - In the terminal yarn test:unit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment