Skip to content

Commit 91f5254

Browse files
Update recommended VS Code debug configuration
1 parent 3f17f8c commit 91f5254

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

docs/recipes/debugging-with-vscode.md

+9-6
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,12 @@ Alternatively you can create a launch configuration, which makes it easier to de
2626
"type": "node",
2727
"request": "launch",
2828
"name": "Debug AVA test file",
29-
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/ava",
30-
"runtimeArgs": [
29+
"program": "${workspaceFolder}/node_modules/ava/entrypoints/cli.mjs",
30+
"args": [
3131
"${file}"
3232
],
3333
"outputCapture": "std",
34+
"console": "integratedTerminal", // optional
3435
"skipFiles": [
3536
"<node_internals>/**/*.js"
3637
]
@@ -55,11 +56,12 @@ Assuming the names of your test files are unique you could try the following con
5556
"type": "node",
5657
"request": "launch",
5758
"name": "Debug AVA test file",
58-
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/ava",
59-
"runtimeArgs": [
59+
"program": "${workspaceFolder}/node_modules/ava/entrypoints/cli.mjs",
60+
"args": [
6061
"build/**/${fileBasenameNoExtension}.*"
6162
],
6263
"outputCapture": "std",
64+
"console": "integratedTerminal", // optional
6365
"skipFiles": [
6466
"<node_internals>/**/*.js"
6567
]
@@ -81,12 +83,13 @@ Or, if you're using a launch configuration, add the `--serial` argument:
8183
"type": "node",
8284
"request": "launch",
8385
"name": "Debug AVA test file",
84-
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/ava",
85-
"runtimeArgs": [
86+
"program": "${workspaceFolder}/node_modules/ava/entrypoints/cli.mjs",
87+
"args": [
8688
"--serial",
8789
"${file}"
8890
],
8991
"outputCapture": "std",
92+
"console": "integratedTerminal", // optional
9093
"skipFiles": [
9194
"<node_internals>/**/*.js"
9295
]

0 commit comments

Comments
 (0)