Angular 2 Karma tests have started to fail can't capture browser

Viewed 1134

This seems like a project setup problem in someway. This was working previously. I don't have the knowledge that these error messages help me to start. Does anyone have some advice on where to start diagnosing the problem?

21 05 2017 07:42:55.094:WARN [karma]: No captured browser, open http://localhost:9876/
21 05 2017 07:42:55.110:INFO [karma]: Karma v1.4.1 server started at http://0.0.0.0:9876/
21 05 2017 07:42:55.110:INFO [launcher]: Launching browser Chrome with unlimited concurrency
21 05 2017 07:42:55.118:INFO [launcher]: Starting browser Chrome                                                                                                                                                                                                        ERROR in /Users/jgreenaw/WebstormProjects/legalcoveapp/node_modules/@angular/core/src/testability/testability.d.ts (41,33): Cannot find name 'Node'.

ERROR in /Users/jgreenaw/WebstormProjects/legalcoveapp/node_modules/@angular/forms/src/directives/ng_form.d.ts (69,22): Cannot find name 'Event'.

ERROR in /Users/jgreenaw/WebstormProjects/legalcoveapp/node_modules/@angular/forms/src/directives/reactive_directives/form_group_directive.d.ts (74,22): Cannot find name 'Event'.

ERROR in /Users/jgreenaw/WebstormProjects/legalcoveapp/node_modules/@ng-bootstrap/ng-bootstrap/rating/rating.d.ts (58,26): Cannot find name 'KeyboardEvent'.

ERROR in /Users/jgreenaw/WebstormProjects/legalcoveapp/node_modules/@ng-bootstrap/ng-bootstrap/typeahead/typeahead.d.ts (81,26): Cannot find name 'KeyboardEvent'.
3 Answers

If running karma test from your IDE (for example, IntelliJ IDEA) and your solution doesn't build/has lint errors, karma seems to not connect and just hang.

Run your tests with something like ng test and get that working before running from your IDE.

Related