diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 24d643b96bc..5488c3472de 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -60,6 +60,21 @@ }, "problemMatcher": [] }, + { + "label": "Code Coverage", + "detail": "Generate code coverage report for a given integration.", + "type": "shell", + "command": "pytest ./tests/components/${input:integrationName}/ --cov=homeassistant.components.${input:integrationName} --cov-report term-missing", + "group": { + "kind": "test", + "isDefault": true + }, + "presentation": { + "reveal": "always", + "panel": "new" + }, + "problemMatcher": [] + }, { "label": "Generate Requirements", "type": "shell", @@ -102,5 +117,12 @@ }, "problemMatcher": [] } + ], + "inputs": [ + { + "id": "integrationName", + "type": "promptString", + "description": "For which integration should the task run?" + } ] }