Chapter 7: Component Harnesses
Testing is a fundamental part of software development. It helps ensure that the code that's delivered covers the feature requirements and is free of implementation issues. Sometimes, when testing UI code, it is hard to avoid performing tightly coupled tests on the DOM structure. However, Angular Ivy brings a new solution for this. Component testing harnesses make it possible to develop a testing API for our components using the industry-standard Page Object pattern, but on a more granular level.
To top this off, component harnesses for the Angular Material directives and components are already included in Angular Ivy. In this chapter, we will learn how to use the component testing harnesses in Angular Components and how to implement custom component harnesses to make it easier to test our components.
We will cover the following topics in this chapter:
- Using Angular Material's component harnesses
- Creating a component harness...