Skip to content

Commit

Permalink
chore: update config for debuggin in Visual Studio Code
Browse files Browse the repository at this point in the history
  • Loading branch information
josecelano committed Sep 15, 2023
1 parent 52926a3 commit 50cef81
Showing 1 changed file with 186 additions and 27 deletions.
213 changes: 186 additions & 27 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,35 +1,194 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in library 'torrust-index-backend'",
"cargo": {
"args": [
"test",
"--no-run",
"--lib",
"--package=torrust-index-backend"
],
"filter": {
"name": "torrust-index-backend",
"kind": "lib"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'main'",
"cargo": {
"args": [
"build",
"--bin=main",
"--package=torrust-index-backend"
],
"filter": {
"name": "main",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'main'",
"cargo": {
"args": [
"test",
"--no-run",
"--bin=main",
"--package=torrust-index-backend"
],
"filter": {
"name": "main",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'import_tracker_statistics'",
"cargo": {
"args": [
"build",
"--bin=import_tracker_statistics",
"--package=torrust-index-backend"
],
"filter": {
"name": "import_tracker_statistics",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'import_tracker_statistics'",
"cargo": {
"args": [
"test",
"--no-run",
"--bin=import_tracker_statistics",
"--package=torrust-index-backend"
],
"filter": {
"name": "import_tracker_statistics",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'parse_torrent'",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/target/debug/parse_torrent",
"args": ["./tests/fixtures/torrents/MC_GRID.zip-3cd18ff2d3eec881207dcc5ca5a2c3a2a3afe462.torrent"],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
],
"preLaunchTask": "cargo build",
"miDebuggerPath": "/usr/bin/gdb",
"linux": {
"miDebuggerPath": "/usr/bin/gdb"
},
"windows": {
"miDebuggerPath": "C:\\MinGW\\bin\\gdb.exe"
},
"osx": {
"miDebuggerPath": "/usr/local/bin/gdb"
}
"cargo": {
"args": [
"build",
"--bin=parse_torrent",
"--package=torrust-index-backend"
],
"filter": {
"name": "parse_torrent",
"kind": "bin"
}
},
"args": ["./tests/fixtures/torrents/not-working-with-two-nodes.torrent"],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'parse_torrent'",
"cargo": {
"args": [
"test",
"--no-run",
"--bin=parse_torrent",
"--package=torrust-index-backend"
],
"filter": {
"name": "parse_torrent",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'upgrade'",
"cargo": {
"args": [
"build",
"--bin=upgrade",
"--package=torrust-index-backend"
],
"filter": {
"name": "upgrade",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'upgrade'",
"cargo": {
"args": [
"test",
"--no-run",
"--bin=upgrade",
"--package=torrust-index-backend"
],
"filter": {
"name": "upgrade",
"kind": "bin"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug integration test 'mod'",
"cargo": {
"args": [
"test",
"--no-run",
"--test=mod",
"--package=torrust-index-backend"
],
"filter": {
"name": "mod",
"kind": "test"
}
},
"args": [],
"cwd": "${workspaceFolder}"
}
]
}

0 comments on commit 50cef81

Please sign in to comment.