By now, you must have created a number of React components. Some of them are quite straightforward, but some are sophisticated enough. Having built both, you might have gained a certain confidence, which makes you believe that no matter how complex the user interface is you can build it with React, without any major pitfalls. This is a good confidence to have. After all that's why we're investing time in learning React. However, there is a trap that many confident React developers fall into; the act of not writing unit tests.
What is a unit test? As the name suggests, it's a test for a single unit of your application. A single unit in your application is often a function, which suggests that writing unit tests means writing tests for your functions.