-
Notifications
You must be signed in to change notification settings - Fork 6.8k
test(material-experimental/mdc-slider): try to reduce test flakes #19987
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
Conversation
@devversion this is a bit of a shot in the dark since I wasn't able to reproduce the failures locally against a device. I think that it might help, because I've re-run the CI checks 5 times now and it hasn't flaked yet. |
The test failures I was looking at had incorrect transform assertions too, but the interesting thing was that the computed transform was always larger as if the slider had an uneven width of ~ |
The ones I was looking at had to do with the transform too. I was thinking of setting the height explicitly as well, but there doesn't seem to be anything that would push it to be that wide. Also the 1000px+ difference is much wider than the screen of the device that the failures were showing up on. My theory is that MDC is trying to measure something while it's animating which throws things off. |
yeah, looks like we both are just guessing here. I briefly looked at the MDC slider foundation code but couldn't find anything suspicious. They just get the bounding client rectangle, use the Either way, I'd be fine in trying this too. Seems like disabling animations would be good anyway (though the non-MDC slider doesn't seem to do it IIRC) |
We've been seeing more test flakes from the MDC slider recently. These changes try to address them by disabling animations and adding an extra change detection after flushing `requestAnimationFrame`.
613f84a
to
603d567
Compare
…gular#19987) We've been seeing more test flakes from the MDC slider recently. These changes try to address them by disabling animations and adding an extra change detection after flushing `requestAnimationFrame`.
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
We've been seeing more test flakes from the MDC slider recently. These changes try to address them by disabling animations and adding an extra change detection after flushing
requestAnimationFrame
.