This extension adds the ability to run and debug Jest tests using the Angular CLI directly from test/spec files through codelenses. There are options for setting the path to both the project and ng executable, see further instructions in the settings.
The extension will automatically activate when it detects an angular.json file in the workspace and will add codelenses to all files following this pattern **/*.{spec,test}.{ts,js}
.
Enables/disables the Codelens (inline commands in the test files)
"angular-jest-test-runner.codelens.enable": true
Allows you to set the label for the run test codelens, supports octicons.
"angular-jest-test-runner.codelens.runLabel": "$(beaker) Run Test"
Allows you to set the label for the debug test codelens, supports octicons.
"angular-jest-test-runner.codelens.debugLabel": "$(bug) Debug Test"
If your Angular project is not in the workspace root, please specify your absolute project path.
"angular-jest-test-runner.debug.projectPath": "/absolute/path/to/project"
Specify Angular CLI executable path, defaults to ./node_modules/@angular/cli/bin/ng
"angular-jest-test-runner.debug.ngPath": "./node_modules/@angular/cli/bin/ng"
If you run into any issues, please feel free to report them here: https://github.com/janeriklysander/angular-jest-test-runner/issues