Currently, I run ng e2e every time I make a change in my spec files and every time this command rebuilds the entire project ! is there a way to run the tests without rebuilding the entire project, just like ng test does it.
Run angular end-to-end tests in watch mode
Asked Answered
Just don't run ng e2e
directly. It's very slow because it rebuild the whole project every time.
You can try npx protractor e2e/protractor.conf.js
to run protractor
directly.
Remove
devServerTarget
from angular.json e2e section.
This way angular won't run ng serve
when running the end to end. You will have to have them running in a separate terminal.
Protractor won't re-run on file change.
I believe you can do it yourself with a bit of set up by leveraging the powers of Gulp. Just came across this while watching some slides:
© 2022 - 2024 — McMap. All rights reserved.
npx protractor ...
+ vscode's rerun task keyboard shortcut. – Phip