Skip to content

Conversation

@kii-dot
Copy link
Contributor

@kii-dot kii-dot commented Mar 3, 2019

Test cases written to test useState and useEffect

@kii-dot kii-dot mentioned this pull request Mar 3, 2019
14 tasks
@kii-dot
Copy link
Contributor Author

kii-dot commented Mar 5, 2019

@ljharb

Copy link

@pgangwani pgangwani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@k3ithl1m : Could you please add testcase to simulate wrapper.setProps() to get new initial state from props (simulate to test concepts : getDerivedStateFromProps or componentWillReceiveProps) passing initialFooVal
act(() => { wrapper.setProps({ initialFooVal: "HELLO" }); });

@kii-dot
Copy link
Contributor Author

kii-dot commented Mar 6, 2019

@pgangwani Sounds like a plan

Copy link
Member

@ljharb ljharb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this is a great start.

@ljharb ljharb mentioned this pull request Mar 7, 2019
7 tasks
@kii-dot
Copy link
Contributor Author

kii-dot commented Mar 9, 2019

@pgangwani @ljharb I've added the component will receive props test case. Let me know if there are any other changes

@pgangwani
Copy link

@k3ithl1m there is #2041 also open. Lets wait for it getting merged then I would work with you ( and whoever else intrested) to implement all remaining test cases specifically for react hooks.

@ljharb ljharb merged commit 01d2fda into enzymejs:master Jun 11, 2019
@kii-dot kii-dot deleted the hooksTestCases branch August 30, 2019 08:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants