cypress-io / cypress

Fast, easy and reliable testing for anything that runs in a browser.
https://cypress.io
MIT License
46.79k stars 3.17k forks source link

Cypress provided browser binaries #19241

Open mjhenkes opened 2 years ago

mjhenkes commented 2 years ago

What would you like?

Cypress consumers install browsers today by separately downloading and installing browsers supported by Cypress either to their local machines or CI. With this project we intend to provide consumers with the ability to download a browser binary for testing through Cypress config. This is similar to, though not the same as, how playwright provides their browser binaries.

For the initial release of this feature we will only support the chromium browser.

Why is this needed?

This is a prerequisite step for providing webkit support since we will have to distribute webkit binaries to enable support.

Other

No response

joshhansen commented 2 years ago

I'd like to request if possible that the browser binaries be statically linked so as to avoid the dependency issues that affect playwright. Or that they be bundled with all dependencies. Playwright's model targets a specific version of Linux (Ubuntu 20.04 I think) that is very limiting for people on other Linux distributions.

weyert commented 2 years ago

I would suggest to just leverage the Playwright packages. I have Playwright Webkit packages working fine on macOs and Linux for months now. I think it's most convenient way and avoids duplicate efforts

joshhansen commented 2 years ago

I've been unable to use Playwright's webkit distribution on Fedora 35 due to lack of specific versions of various dependencies, see this Playwright issue for similar problems.

Relying on dynamic linking to specific versions of frequently updated libraries like libicuuc makes the binary very fragile. From what I can tell, there never was a distribution of version 66 of that library on Fedora, yet that's what Playwright's webkit is depending on, and subbing in neighboring versions doesn't work.

$ ~/.cache/ms-playwright/webkit-1578/pw_run.sh 
/home/josh/.cache/ms-playwright/webkit-1578/minibrowser-gtk/bin/MiniBrowser: error while loading shared libraries: libicuuc.so.66: cannot open shared object file: No such file or directory

I'd like to see Cypress avoid a similar fate in whatever it provides, either by static linking, or a container-based distribution, or enough distribution-specific builds to make this a non-issue.

michalbudzynski commented 2 years ago

whats happen with this task? what is the scope of time for making the functionality available?

jennifer-shehane commented 1 year ago

We've deprioritized this work over other initiatives.