Closed bhavnahari27 closed 3 years ago
component.js
Please don’t delete the issue template - it’s there for a reason.
this is because shallow rendering doesn’t dig into MyComponent. Use the wrappingComponent option instead of directly wrapping it with Provider, and then look at wrapper.debug()
if you’re still having trouble. dive()
is your friend.
Thanks ljharb.Please help with sample code on how to implement in my case.
Please first read the docs - about the wrappingComponent option and about dive.
I am using redux in my react project. Also i see that the basic MatchSnapShot function is not working for me . even though the snapshot file is created and testcase is passing,i dont see the html contents in that. Below is my component code.
It( 'matches snapshot', () => { expect( shallow(
)
).toMatchSnapshot(); });
Please help , is there something i missing?
@bhavnahari27 please fill out the issue template in #2491 and I’ll be happy to reopen it.
Facing error - Method “simulate” is meant to be run on 1 node. 0 found instead for simulating select onchange . Below is my test case and the select of the component. Please help me and i stuck with this issue .
test case.js