Using Angular/CLI within VS Code, can I run Tests at same time as Builds?

Viewed 799

I've been using Angular/CLI from within the context of VS Code.

From the Terminal prompt within VS Code one can invoke ng serve or ng test -- but is there a way to combine the two (eg: something like ng serve test) so that as I TDD, and develop tests first, I see the Terminal show failed tests, then go green as i write code to meet the tests, AND see the web page results on another screen?

Thanks!

3 Answers

2020-02-12, win 10, VSC 1.42.0. Project has node/Express API and Angular UI, want to debug both API and UI. No, you can only debug either one, not simultaneously. Here is how:

1, open a cmd for the part you can't debug.

For example, run ng serve to debug node/Express. Or, npm start to debug Angular UI.

2, inside VSC's terminal, run ng serve if to debug Angular UI. Else skip to 3

3, Launch the corresponding debugger

Related