I'm new to unittesting a Action of Redux-thunk use Jest.
Here is following Code :
export const functionA = (a,b) => (dispatch) =>{
dispatch ({type: CONSTANT_A, payload: a});
dispatch ({type: CONSTANT_B, payload: b});
}
How can i test for the function use Unit-Test Jest ? Anyone can help me ^^. Thank in advance :)
Also, for more more convenience, you can use this module: https://www.npmjs.com/package/redux-thunk-tester
Exmaple:
You have an example in the Redux docs: http://redux.js.org/docs/recipes/WritingTests.html#async-action-creators