Using karma for unit-testing in an Angular project works fine. With a new Chrome version a “search engine selection” windows pops up on each npm run test
.
How to disable this ?
There is a command-line-argument disable-search-engine-choice-screen
that disables that popup.
using that argument is a little bit tricky (use the right number of dashes)
in the file karma.config.js
replace
browsers: ['Chrome'],
with:
browsers: ["MyChromeWithoutSearchSelect"],
customLaunchers: {
MyChromeWithoutSearchSelect: {
base: "Chrome",
flags: ["-disable-search-engine-choice-screen"],
},
},