Is there any way to mock or stub $refs when using shallow to render a component?
I have a child component that takes quite a bit to get set up for testing, so using shallow is a nice way to make my tests less brittle. What I've now run into is that the child component is not recognized inside the $refs object. Is there a way to stub or mock a ref when using shallow?
I would happily accept a PR that added a refs option where you could pass an object. Unfortunately I don't have time at the moment to implement it myself 😞
Is there any way to mock or stub $refs when using shallow to render a component?
I have a child component that takes quite a bit to get set up for testing, so using shallow is a nice way to make my tests less brittle. What I've now run into is that the child component is not recognized inside the $refs object. Is there a way to stub or mock a ref when using shallow?