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(launcher): Provide option to run puppeteer with different browsers #5137
Conversation
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here with What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
d26ff10
to
8c8c37d
Compare
@mathiasbynens Hi! This is ready for review. My CLA is in the works. I looked at the results of the checks and it seems the failures are known to be intermittent... Let me know. |
This change introduces a PUPPETEER_PRODUCT environment variable as a first step toward using Puppeteer with many different browsers. Setting PUPPETEER_PRODUCT=firefox, for example, enables Firefox-specific Launcher settings. The state is also exposed as `puppeteer.product` in the API to support adding other product-specific behaviour as needed. The bulk of the change is a refactoring in Launcher to decouple generic browser start-up from product-specific configuration.
The funit script is renamed to fjunit (j for Juggler, which is used only by the experimental puppeteer-firefox package. In contrast, the funit script now refers to running Puppeteer unit tests against the main puppeteer package with Firefox. To do so with Firefox Nightly, run: `BINARY=path/to/firefox npm run funit` A number of changes in this patch make it easier to run Puppeteer unit tests in Mozilla's CI.
8c8c37d
to
16d36fb
Compare
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
@googlebot I signed it! |
Yay, thanks for sending this over! Just as a heads-up, I won’t be able to review this as soon as I’d like, since I’m traveling for ChromeDevSummit and BlinkOn this week. I’ll get back to y’all as soon as I can. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I left some initial comments and questions. I want to do a more thorough second pass after BlinkOn, but figured this should get the conversation started.
Thanks again for your work on this!
We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for all the commit author(s) or Co-authors. If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google. ℹ️ Googlers: Go here for more info. |
fc5e2f3
to
419cd76
Compare
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
Have the documents been updated on how to use this new feature? i.e. do you still need |
|
@chrisLovesCode it doesn't say if |
okay , i got your point! ..yes i agree, would be nice to get some informations, currently i have not tried out to use firefox, but would like to do it soon, since i will write e2e tests with puppeteer |
- product option support as per 2.1 - version bump - test updated https://github.com/puppeteer/puppeteer/releases/tag/v2.1.0 puppeteer/puppeteer#5137 Thanks!
- product option support as per 2.1 - version bump - test updated https://github.com/puppeteer/puppeteer/releases/tag/v2.1.0 puppeteer/puppeteer#5137 Thanks!
- product option support as per 2.1 - version bump - test updated https://github.com/puppeteer/puppeteer/releases/tag/v2.1.0 puppeteer/puppeteer#5137 Thanks!
…erblazejewicz - product option support as per 2.1 - version bump - test updated https://github.com/puppeteer/puppeteer/releases/tag/v2.1.0 puppeteer/puppeteer#5137 Thanks!
…support by @peterblazejewicz - product option support as per 2.1 - version bump - test updated https://github.com/puppeteer/puppeteer/releases/tag/v2.1.0 puppeteer/puppeteer#5137 Thanks!
…support by @peterblazejewicz - product option support as per 2.1 - version bump - test updated https://github.com/puppeteer/puppeteer/releases/tag/v2.1.0 puppeteer/puppeteer#5137 Thanks!
This is an initial refactoring of Launcher to enable run-time browser selection in Puppeteer, starting with Firefox. On our side, we're tracking this and related work at https://bugzilla.mozilla.org/show_bug.cgi?id=1590467
/cc @whimboo @andreastt @AutomatedTester