Unit tests verify small, isolated parts of your code like components, services, and pipes by testing them independently without external dependencies. They execute quickly, help find bugs early, and are straightforward to maintain. Focus on testing business logic, data transformations, and component behavior while avoiding external API calls, UI styling, and third-party library tests.
In this series, I'll share practical examples of testing different parts of an Angular application using Jest.
While these tests aren't exhaustive or mandatory and there are certainly other aspects you could test they aim to serve as a helpful guide when writing unit tests for your own projects.
Find other examples and documentation on angular.dev