# launch.json:
{
"version": "0.2.0",
"configurations": [
{
"name": "Python: Debug Tests",
"type": "python",
"request": "launch",
"program": "${file}",
"purpose": ["debug-test"],
"console": "integratedTerminal",
"justMyCode": false
},
]
}
# settings.json
{
"python.testing.pytestArgs": [
"--override-ini",
"addopts=--verbose -vv tests" # <-- this is the directory containing tests.
],
"python.testing.unittestEnabled": false,
"python.testing.pytestEnabled": true,
"python.pythonPath": "/usr/bin/python" # <-- this is you python env with pytest
}
{
"python.pythonPath": "/usr/local/bin/python3", // <--- path to interpreter
"python.testing.pytestArgs": [
"" <-- Search path for the tests , blank would be root
],
"python.testing.unittestEnabled": false,
"python.testing.pytestEnabled": true
}