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

React hooks test cases part 1 -- useLayoutEffect #2121

merged 1 commit into from May 11, 2019


2 participants
Copy link

commented May 11, 2019

Related to #2011 .

Added useLayoutEffect tests with almost the same flow except that the component using useLayoutEffect instead useEffect.

The shallow test is also skipped due to facebook/react#15275 . After that resolves we should reopen those skipped tests.

Also reset the timeout of setTimeout in test from 1e3 to 100 -- hope to make tests a little sooner.

[Tests] Add `useLayoutEffect` tests for mount
Also reduce the timeout from 1e3 to 100.

Skip shallow tests until [shallow renderer can run useEffect](facebook/react#15275) is fixed.

@chenesan chenesan referenced this pull request May 11, 2019


React hooks support checklist #2011

0 of 11 tasks complete

@ljharb ljharb force-pushed the chenesan:react-hooks-use-layout-effect branch from 3d0983b to 1b85181 May 11, 2019

@ljharb ljharb added this to v16.8+: Hooks in React 16 May 11, 2019

@ljharb ljharb merged commit 1b85181 into airbnb:master May 11, 2019

2 of 3 checks passed

continuous-integration/travis-ci/push The Travis CI build is in progress
continuous-integration/travis-ci/pr The Travis CI build passed
coverage/coveralls Coverage remained the same at 91.691%
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.