NG.X · Angular 22 practice question

A team has finished setting up unit testing for their Angular application and wants to enforce minimum test coverage thresholds in CI. Which testing topic addresses measuring coverage and configuring required thresholds?

Choose one answer
Check answer and explanation

Correct answer: Code coverage

Explanation

Code coverage tracks how much of the application is exercised by tests and explains how to configure required coverage amounts.

Common trap

This is tempting because CI pipelines often run browser tests, but browser mode controls the execution environment rather than coverage thresholds. This is tempting because DOM tests increase coverage of templates, but component DOM testing does not define coverage reporting or threshold rules.

Source: Angular docs: Unit testing — More information on testing
Checked against the cited text on 2026-11-25.

Report an error in this question