-
Notifications
You must be signed in to change notification settings - Fork 127
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
[Enhancement] Make next() call of testSaga implicit #148
Comments
Have you tried the expectSaga? With expectSaga you just need to write the assertions for the effects that you are interested. http://redux-saga-test-plan.jeremyfairbank.com/integration-testing/ |
@hidalgofdz: Hmm, I assumed it would involve more mocking and stuff to do integration type tests, but it doesn't seem too too bad. I will mess around and write some tests with both I did manage to implement the use of implicit nexts, and can put in a PR if its something that @jfairbank thinks wouldn't be a bad addition. |
Hi @hedgerh! Thanks for the idea. I like the spirit behind it, but I'm thinking it might be better to have a new method name instead of |
Just came across this library, and I'm trying out testSaga. The first thing that stood out is the need to call
.next()
repeatedly after each effect. It'd be nice if that were optional, and you only needed to explicitly call.next()
if you are passing a value back in:Would it be possible to implement this with the way testSaga is currently designed? Would you be open to this? I'd be willing to work on it if I could get a little direction, since I've just started digging in the codebase, and I'm not really familiar with it yet.
Edit: I just walked through the code, and think I understand how testSaga works now. It seems that methods like
next
return the effects api, and calling one of those returns the other api withnext
and other methods.The text was updated successfully, but these errors were encountered: