Thanks, Fredrick for the article and Sergey for that comment.
I have a slightly different setup: I've wrapped RTL render with my redux-dynamic-modules provider, so I think there's no need to mock react-redux or useSelector, and all I need to actually mock is the return value of my selector function.
I'm trying to implement it the way shown in your comment, but I'm getting an error that my selector is undefined.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Thanks, Fredrick for the article and Sergey for that comment.
I have a slightly different setup: I've wrapped RTL render with my
redux-dynamic-modules
provider, so I think there's no need to mockreact-redux
oruseSelector
, and all I need to actually mock is the return value of my selector function.I'm trying to implement it the way shown in your comment, but I'm getting an error that my selector is
undefined
.