dashboard icon indicating copy to clipboard operation
dashboard copied to clipboard

Configure minimum viewport resolution for Cypress e2e tests

Open momesgin opened this issue 6 months ago • 2 comments

Is your feature request related to a problem? Please describe.

We should define a minimum resolution for our E2E tests, right now Cypress uses its default resolution of 1000×660, that is smaller than a typical desktop screen, we should set it to 1280×720 at least, which is a common minimum for desktop environments. We already override the resolution in individual tests (e.g., 1280×720 or 1440×900) based on specific scenarios, it would be better to update the global default to avoid relying on the lower 1000×660 baseline.

Describe the solution you'd like

We can easily set the viewport resolution in the Cypress defineConfig object.

Describe alternatives you've considered

Additional context

This suggestion has already been approved by the QA team in a slack thread.

momesgin avatar Jun 26 '25 03:06 momesgin

@momesgin I think this is a duplicate of https://github.com/rancher/dashboard/issues/11806

nwmac avatar Jun 26 '25 09:06 nwmac

@momesgin I think this is a duplicate of #11806

Thanks for finding it. I'm still thinking we might keep the other one and close this issue when the PR gets merged? since this issue is only about setting the default minimum resolution(1280x720). The other resolutions(1440x900 & 1380x720) need more investigation.

momesgin avatar Jun 26 '25 16:06 momesgin