Skip to content
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

Update WritingTests.md #2654

Merged
merged 1 commit into from
Oct 9, 2017
Merged

Update WritingTests.md #2654

merged 1 commit into from
Oct 9, 2017

Conversation

mattmilburn
Copy link
Contributor

@mattmilburn mattmilburn commented Oct 9, 2017

Example for middleware testing should destructure the store param that is being passed through invoke(). Currently, the example shows invoke((dispatch, getState) => { ... }) on LINE 456, but it should read as invoke(({ dispatch, getState }) => { ... }).

Example for middleware testing needs to destructure the `store` param that is being passed in to `invoke()`. Currently, the example shows `invoke((dispatch, getState) => { ... })` on LINE 456, but it should read as `invoke(({ dispatch, getState }) => { ... })`.
@timdorr
Copy link
Member

timdorr commented Oct 9, 2017

Thanks!

@timdorr timdorr merged commit 953983b into reduxjs:master Oct 9, 2017
@mattmilburn mattmilburn deleted the patch-1 branch October 9, 2017 20:46
@mattmilburn
Copy link
Contributor Author

@timdorr Actually... I was wrong. I was using the middleware+thunk example to write a test for custom middleware and I was handling the inner logic differently. The example on the website is already correct. Can I take this back, haha? 😅

@timdorr
Copy link
Member

timdorr commented Oct 11, 2017

No worries. That tripped me up too! I'll revert.

timdorr added a commit that referenced this pull request Oct 11, 2017
timdorr added a commit that referenced this pull request Oct 11, 2017
seantcoyote pushed a commit to seantcoyote/redux that referenced this pull request Jan 14, 2018
Example for middleware testing needs to destructure the `store` param that is being passed in to `invoke()`. Currently, the example shows `invoke((dispatch, getState) => { ... })` on LINE 456, but it should read as `invoke(({ dispatch, getState }) => { ... })`.
seantcoyote pushed a commit to seantcoyote/redux that referenced this pull request Jan 14, 2018
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.

None yet

2 participants