Closed kiranparajuli589 closed 7 months ago
Looks like you are downloading firefox but the tests want the Chromium browser. Do you maybe launch the browser yourself somewhere hard-coded? Make sure to rely on the browserType fixture, or even better re-use our browser fixture and never launch it manually.
@mxschmitt thx for the response.
I've no any code to launch the browser inside my test base.
The browser is opened by the page.goto()
command, and just the URL to navigate to is provided.
It seems like playwright uses chromium by default.
If I use the project config like:
{name: 'Firefox', use: {...devices['Desktop Firefox'], browserName: 'firefox'}},
And try to run the tests using:
yarn test tests/auth/login.spec.js:19 --project Firefox
Then I get error:
Error: browser.newContext: Unknown permission: camera
Can you help?
Are you able to share a reproduction with us which we can run locally? That might be the best option in order to find out whats happening.
This is pretty much it. I've shared playwright config, GH actions yml.
But, sure I can try setting up a dedicated repo to reproduce this.
Tests would be the interesting counterpart.
Looks also like that you have: browserName: chromium in your global use in your playwright.config. I recommend removing this.
That was the case, thank you @mxschmitt
Version
1.42.0
Steps to reproduce
GitHub Actions like:
Expected behavior
Test should be running using the firefox browser.
Actual behavior
Logs from
npx playwright install --with-deps firefox
Logs from test run command:
Additional context
Playwright config:
Environment