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

Tests failing locally in open/headed mode #236

Closed
drecali opened this issue Feb 15, 2022 · 1 comment · May be fixed by #237
Closed

Tests failing locally in open/headed mode #236

drecali opened this issue Feb 15, 2022 · 1 comment · May be fixed by #237

Comments

@drecali
Copy link
Contributor

drecali commented Feb 15, 2022

Many tests in are failing in click.spec.ts, hover.spec.ts, and mouse.spec.ts when I run them locally in the Cypress Test Runner using the yarn run cypress open command. Please see the screenshots below.

All tests pass in headless mode.

The reason for the headed failures are that the top offset of the element is expected to be an integer but the actual value has a decimal of usually 0.1875.

Is this issue reproducible? Is it a serious issue?

The fix seems quite easy and works well for me locally. We can just change the Cypress comparison to allow for the small deviation. It seems like a relatively safe change.

image

image

image

image

image

@dmtrKovalenko
Copy link
Owner

Yes, I do think there is not a problem, especially for this plugin which is trying to take the value through the cypress UI that renders the app in iframe. I actually don't know how to make it more stable, so using closeTo is a way to go.

If you have any idea please provide a PR :)

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

Successfully merging a pull request may close this issue.

2 participants