vscode-jest
vscode-jest copied to clipboard
vscode-jest doesn't shows in extension tab, and test files.
Environment
-
vscode-jest version
: [v4.4.0] -
node -v
: [v14.17.1] -
npm -v
oryarn --version
: npm [8.5.1] -
npm ls jest
ornpm ls react-scripts
(if you haven’t ejected): [empty] - your vscode-jest settings if customized:
- jest.jestCommandLine? [fill]
- jest.autoRun? [fill]
- anything else that you think might be relevant? [fill]
- Operating system: [fill] macos
Prerequisite
- are you able to run jest test from the command line? [yes]
- how do you run your tests from the command line? (for example:
npm run test
ornode_modules/.bin/jest
) [npm run test]
Expected Behavior
I have two projects using jest in my macOS, first project looks work well with vscode-jest,
[ create-react-app
[fill]
]
Actual Behavior
[
but second one is not. ( vitejs react-ts template)
I reloaded my vs-code several times, but test extension icon doesn't show up.
]
The fastest (and the most fun) way to resolve the issue is to submit a pull-request yourself. If you are interested, feel free to check out the contribution guide, we look forward to seeing your PR...
from your screenshot, the second project's root directory seems to be one level above the actual jest config file, thus not triggering the activation events: see activationEvents.
If there are multiple projects/folders under the root, consider converting your workspace to vscode's multi-root workspace, otherwise, create the vscode project in the fontend
folder, not one above.
If none of the above worked, you might need to provide a sample project for a more detailed investigation.
@connectdotz thank you for responding! I'll check multi-root workspace and see what's could be changed