Skip to content

Instantly share code, notes, and snippets.

@carlohcs
Last active October 2, 2018 22:27
Show Gist options
  • Save carlohcs/45f63ed68b11ed61a92a2c5fa962372e to your computer and use it in GitHub Desktop.
Save carlohcs/45f63ed68b11ed61a92a2c5fa962372e to your computer and use it in GitHub Desktop.
Run jest file in vscode
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Jest All",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"args": ["--runInBand"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"windows": {
"program": "${workspaceFolder}/node_modules/jest/bin/jest",
}
},
{
"type": "node",
"request": "launch",
"name": "Jest Current File",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"args": ["${relativeFile}"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"windows": {
"program": "${workspaceFolder}/node_modules/jest/bin/jest",
}
}
]
}
no package.json:
"jest": {
"testEnvironment": "node"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment