-
Notifications
You must be signed in to change notification settings - Fork 313
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
Facet by Meta Range E2E tests #3365
Conversation
/** | ||
* Ignore ResizeObserver error. | ||
* | ||
* @see {@link https://stackoverflow.com/questions/49384120/resizeobserver-loop-limit-exceeded} | ||
*/ | ||
Cypress.on('uncaught:exception', (err) => { | ||
if (err.message?.includes('ResizeObserver loop limit exceeded')) { | ||
return false; | ||
} | ||
|
||
return err; | ||
}); |
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.
@felipeelia I was running into this issue, which is described at the link. It was happening in the test before the block was even inserted, but the library used by the block does appear to use ResizeObserver, so it might be related. The problem is that it's in the library so I can't do anything about it, however the various answers at that link seem to suggest that ignoring the issue is safe. I'd be curious to hear your thoughts though.
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.
Yeah, we are already using this solution for Instant Results: https://github.com/10up/ElasticPress/blob/develop/tests/cypress/integration/features/instant-results.cy.js#L241
I wonder if we should merge those two in a more generic function or something. Thoughts?
Description of the Change
Adds E2E tests for the Facet by Meta Range block.
Closes #3357
How to test the Change
Tests should pass in Cypress and on GitHub.
Changelog Entry
N/A
Credits
Props @JakePT
Checklist: