Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support spawnOpts for geckodriver child process #552

Conversation

AtofStryker
Copy link
Contributor

I am currently migrating Cypress to use webdriver and geckodriver for our firefox automation. We have the needs to propagate some environment variables to the geckodriver process (better outlined in this bugzilla comment), which we are patching this package to accomplish now. This PR is to move this patch upstream as a contribution.

In order to propagate environment variables to the firefox process started with geckodriver, the environment variables need to be passed to the geckodriver process directly in order to be passed to firefox. This is important for setting MOZ_ prefixed variables, like MOZ_HEADLESS_HEIGHT or MOZ_HEADLESS_WIDTH. This PR allows spawn options to be passed into the geckodriver process.

Copy link
Contributor

@christian-bromann christian-bromann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we document the new user parameter? Maybe including an example as well?

src/types.ts Outdated Show resolved Hide resolved
@AtofStryker AtofStryker force-pushed the feat/add_spawn_option_to_gecko branch from 893750d to ec9e561 Compare September 26, 2024 22:04
src/types.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@christian-bromann christian-bromann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great stuff, LGTM 👍

@AtofStryker
Copy link
Contributor Author

Great stuff, LGTM 👍

awesome I will get the docs updated then we should be good to go!

@AtofStryker
Copy link
Contributor Author

docs updated @christian-bromann . Thank you for the really fast review on this!

@christian-bromann christian-bromann merged commit 3edaf8e into webdriverio-community:main Sep 27, 2024
5 checks passed
@wdio-bot
Copy link
Contributor

Hey AtofStryker 👋

Thank you for your contribution to WebdriverIO! Your pull request has been marked as an "Expensable" contribution.

We've sent you an email with further instructions on how to claim your expenses from our development fund.
Please make sure to check your spam folder as well. If you have any questions, feel free to reach out to us at [email protected] or in the contributing channel on Discord.

We are looking forward to more contributions from you in the future 🙌

Have a nice day,
The WebdriverIO Team 🤖

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants