Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[router]: cancel ExpoRouter SplashScreen during test teardown (#27620)
# Why #27512 is causing extra console logging due to the `requestAnimationFrame` used by Expo Router to hide the splash screen. Previously this logic was never invoked as we were using fake timers, but now we need to cancel the timeout so it doesn't run after the tests have ended. # How Added a `cleanup()` to `expo-router/testing-library` that removes the `requestAnimationFrame` if it has not run yet. # Test Plan <!-- Please describe how you tested this change and how a reviewer could reproduce your test, especially if this PR does not include automated tests! If possible, please also provide terminal output and/or screenshots demonstrating your test/reproduction. --> # Checklist <!-- Please check the appropriate items below if they apply to your diff. This is required for changes to Expo modules. --> - [ ] Documentation is up to date to reflect these changes (eg: https://docs.expo.dev and README.md). - [ ] Conforms with the [Documentation Writing Style Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md) - [ ] This diff will work correctly for `npx expo prebuild` & EAS Build (eg: updated a module plugin). --------- Co-authored-by: Expo Bot <34669131+expo-bot@users.noreply.github.com>
- Loading branch information