.vscode/launch.json
{
// Use IntelliSense to find out which attributes exist for node debugging
// Use hover for the description of the existing attributes
// For further information visit https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Debug test suite",
"type": "node2",
"request": "launch",
"program": "${workspaceRoot}/node_modules/jest/bin/jest.js",
"args": ["--runInBand"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"env": {
"NODE_ENV": "test"
},
"cwd": "${workspaceRoot}",
"smartStep": true
},
{
"name": "Debug current file",
"type": "node2",
"request": "launch",
"program": "${workspaceRoot}/node_modules/jest/bin/jest.js",
"args": ["--runInBand", "--detectOpenHandles", "-i", "${file}"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"env": {
"NODE_ENV": "test"
},
"cwd": "${workspaceRoot}",
"smartStep": true
}
]
}