-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Closed
Description
HI,
I have been experimenting playwright for our product UI automation.
I have a package.json and login page script. When I run it, it works well and launches Chromium and Firefox for me. I am on Ubuntu.
When I ask my team members to try the code. For 2 users firefox does not launch on their machines. One user is on Ubuntu and one is on Windows. ESame code works for other 2 users without any issue.
Error is -
Failed to launch browser!
TROUBLESHOOTING: https://github.com/Microsoft/
at onClose (node_modules/playwright-core/lib/server/processLauncher.js:151:20)
at Interface.<anonymous> (node_modules/playwright-core/lib/server/processLauncher.js:144:65)
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.241s
Ran all test suites.
/home/ui-automation/node_modules/playwright-core/lib/server/firefox.js:107
if (browserServer)
^
ReferenceError: Cannot access 'browserServer' before initialization
at Object.onkill (/home/ui-automation/node_modules/playwright-core/lib/server/firefox.js:107:17)
at ChildProcess.<anonymous> (/home/ui-automation/node_modules/playwright-core/lib/server/processLauncher.js:77:21)
at Object.onceWrapper (events.js:417:26)
at ChildProcess.emit (events.js:310:20)
at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] test:firefox: `BROWSER='firefox' jest`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] test:firefox script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Below is my package.json
{
"name": "ui-automation",
"version": "1.0.0",
"description": "UI Testing Framework",
"main": "index.js",
"scripts": {
"test:webkit": "BROWSER='webkit' jest",
"test:chrome": "BROWSER='chromium' jest",
"test:firefox": "BROWSER='firefox' jest",
"test:debug": "node --inspect node_modules/.bin/jest --runInBand"
},
"keywords": [
"jest",
"playwright",
"jest-playwright",
"example"
],
"dependencies": {
"dotenv": "^8.2.0",
"jest-cli": "^26.0.1",
"regex": "^0.1.1",
"jest-environment-node": "^25.2.3",
"jest-playwright-preset": "^0.1.3"
},
"jest": {
"preset": "jest-playwright-preset"
},
"devDependencies": {
"jest": "^26.0.1",
"playwright": "^1.0.1"
}
}
Can someone help me understand what could be the issue here?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels