Chapter 16. Unit testing React with Jest
This chapter covers
- Reasons to use Jest
- Unit testing with Jest
- UI testing with Jest and TestUtils
In modern software engineering, testing is important. It’s at least as important as using Agile methods, writing well-documented code, and having enough coffee on hand—sometimes even more so. Proper testing will save you from many hours of debugging later. The code isn’t an asset, it’s a liability, so your goal is to make it as easy to maintain as possible.