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

Add window to jest setup #28067

Closed
wants to merge 1 commit into from
Closed

Add window to jest setup #28067

wants to merge 1 commit into from

Commits on Aug 12, 2021

  1. Add global window to jest setup

    `window` exists in the React Native runtime, but not inside the test
    environment. Many libraries use `typeof window === 'undefined'` to
    check if code is running in SSR. Because of the difference in the real
    environment and test environment, tests can behave different than the
    real app, which is an unwanted behavior.
    timomeh committed Aug 12, 2021
    Configuration menu
    Copy the full SHA
    bef051d View commit details
    Browse the repository at this point in the history