Fix Glean.js selenium-webdriver configuration to avoid patching
Categories
(Data Platform and Tools :: Glean: SDK, enhancement, P4)
Tracking
(Not tracked)
People
(Reporter: brosa, Unassigned, Mentored)
Details
(Whiteboard: gleanjs)
Glean.js uses the selenium-webdriver npm package for running our browserstack tests. For a long time there was a breaking change going from version 4.4.0 -> 4.5.0 of the package that caused our browserstack tests to stop working. The error that I was seeing was not reported anywhere and no one else seemed to have the same issue. I "fixed" this by copying in a line of code that was removed in 4.5.0 into the package code using patch-package.
My guess is that no one else saw this problem because our selenium configuration is not set up correctly. We configure the webdriver here https://github.com/mozilla/glean.js/blob/main/automation/compat/tests/browserstack.test.js#L58
The ideal outcome is that we update the webdriver configuration and we remove the patch and the patch-package package entirely. Whatever changes we need to make should be on the webdriver.Builder().
Additional notes
For testing, you can just delete the patch file inside of automation/patches.
To run the browserstack tests locally, you need to add the browserstack variables to your env. I do this by
- Signing into browser stack and copying my username and access_key
export BROWSERSTACK_USER_NAME=<your_username>export BROWSERSTACK_ACCESS_KEY=<your_key>npm run compat:test:browserstackfrom within theautomationfolder
| Reporter | ||
Updated•2 years ago
|
Updated•1 year ago
|
Description
•