Description
I'm submitting a...
[ ] Regression (a behavior that used to work and stopped working in a new release)
[X] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/NationalBankBelgium/stark/blob/master/CONTRIBUTING.md#got-a-question-or-problem
Current behavior
In Stark 10, the CHROME_BIN env var was set to require("puppeteer").executablePath()
when executing test:ci.
In Stark 12, this env var is no longer set and so the Chrome installed on the machine is used instead.
Expected behavior
Since we install puppeteer, it should be used by default as the Chrome browser to execute Karma tests all the time (not only in CI).
We should adapt the following code
stark/packages/stark-testing/karma.conf.js
Lines 1 to 8 in 91547b0
like this:
// Helpers
const helpers = require("./helpers");
const ciDetect = require("@npmcli/ci-detect");
const isCI = process.argv.indexOf("--watch=false") > -1 || !!ciDetect();
// Puppeteer: https://github.com/GoogleChrome/puppeteer/
// takes care of download Chrome and making it available (can do much more :p)
process.env.CHROME_BIN = require("puppeteer").executablePath();
const rawKarmaConfig = {
// base path that will be used to resolve all patterns (e.g. files, exclude)
basePath: "",
Minimal reproduction of the problem with instructions
What is the motivation / use case for changing the behavior?
Fix CI environment.
Environment
Angular version: 12.x+
Stark version: 12.x
Browser:
- [ ] Chrome (desktop) version XX
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [ ] Firefox version XX
- [ ] Safari (desktop) version XX
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX
For Tooling issues:
- Node version: XX
- Platform:
Others: