How to test two redux related components?

Posted by Jennifer | Updated on

Want to test two redux related components? You should test each component separately for unit testing.

Component1: You should test that when you click a button or something, that Component1 is dispatching the right action.

Component2: You should test that when you provide the props, it behaves as excepted.

You can export the Component2 separately to unit test it.


If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.

Related Questions & Answers