Not sure if this is a bug in Angular CLI, Karma, or Kendo. I wrote up a bug for Angular CLI for this as well: https://github.com/angular/angular-cli/issues/20449
Issue only tested on Windows 10 x64 with Chrome 89 installed.
ng new <app-name> --strict=true --style=scss --routing=true@progress/kendo-theme-defaultnpm install @progress/kendo-theme-default --savestyles.scss, add the following line:@import "~@progress/kendo-theme-default/scss/all";karma.conf.js and change the following properties: autoWatch: false
browsers: ['ChromeHeadlessCI'],
customLaunchers: {
ChromeHeadlessCI: {
base: 'ChromeHeadless',
flags: ['--no-sandbox']
}
},
singleRun: true
ng testAfter 2+ minutes, warning in console shows: WARN [launcher]: ChromeHeadless have not captured in 60000 ms, killing.
Then, NFO [launcher]: Trying to start ChromeHeadless again (1/2).
The second time launches without issue.
If you remove the line from styles.scss and repeat ng test, the problem is not visible.
Alternatively, check out this repo and run ng test :https://github.com/acohenOT/unit-testing
Warning indicated below:
Karma v6.1.2 server started at http://localhost:9876/
05 04 2021 12:20:05.510:INFO [launcher]: Launching browsers ChromeHeadlessCI with concurrency unlimited
05 04 2021 12:20:05.536:INFO [launcher]: Starting browser ChromeHeadless
- Generating browser application bundles (phase: building)...05 04 2021 12:22:32.075:WARN [launcher]: ChromeHeadless have not captured in 60000 ms, killing.
/ Generating browser application bundles (phase: building)...05 04 2021 12:22:32.986:INFO [launcher]: Trying to start ChromeHeadless again (1/2).
√ Browser application bundle generation complete.
05 04 2021 12:22:39.009:INFO [Chrome Headless 89.0.4389.114 (Windows 10)]: Connected on socket 6ClQVkn2c_tOxxhlAAAB with id 89607273
Chrome Headless 89.0.4389.114 (Windows 10): Executed 3 of 3 SUCCESS (0.305 secs / 0.217 secs)
TOTAL: 3 SUCCESS