angular/packages/compiler-cli/test/compliance/test_cases/model_inputs
Doug Parker 05d022d5e6 fix(compiler-cli): ignore generated ngDevMode signal branch for code coverage
The Angular compiler unconditionally adds a debug name transform for signals
which generates a conditional on `ngDevMode` (e.g., `ngDevMode ? { debugName: "xyz" } : []`).
During testing, `ngDevMode` is true, so the true branch executes but the
false branch is never executed. Consequently, coverage tools report the
false branch as an untested line/branch, preventing 100% test coverage.

This commit adds a synthetic `/* istanbul ignore next */` comment to the
generated false branch so that Istanbul ignores it. We only include the
istanbul comment (instead of additionally including c8) to focus on the
established standard for Angular CLI/Karma coverage while maintaining
compatibility with modern Vitest setups, since @vitest/coverage-v8 now
natively respects the fallback istanbul comment.

Fixes #64583

(cherry picked from commit dc4cf649b6)
2026-03-04 22:42:57 +00:00
..
GOLDEN_PARTIAL.js fix(compiler-cli): ignore generated ngDevMode signal branch for code coverage 2026-03-04 22:42:57 +00:00
mixed_model_types.js test(compiler): switch compliance tests to es2022 2026-01-02 08:29:12 +01:00
mixed_model_types.ts refactor(compiler): update compliance tests. (#58238) 2024-10-24 12:44:12 -07:00
model_component_definition.js test(compiler): switch compliance tests to es2022 2026-01-02 08:29:12 +01:00
model_component_definition.ts refactor(compiler): update compliance tests. (#58238) 2024-10-24 12:44:12 -07:00
model_directive_definition.js test(compiler): switch compliance tests to es2022 2026-01-02 08:29:12 +01:00
model_directive_definition.ts refactor(compiler): update compliance tests. (#58238) 2024-10-24 12:44:12 -07:00
TEST_CASES.json refactor(compiler-cli): add tests for model inputs (#54252) 2024-02-07 16:36:08 +00:00