Skip to content

Support for jest-angular-test-verifier when using @angular-devkit/build-angular:jest #25696

@Neizan93

Description

@Neizan93

Command

test

Description

As Angular CLI is starting to provide support for Jest in Angular 16, I would like to propose the addition of support for the jest-angular-test-verifier extension or a similar feature. This feature would enable developers to detect files that lack corresponding spec.ts files, helping to ensure comprehensive test coverage in Angular projects.

Benefits

  • Enhance the testing experience in Angular projects by ensuring complete test coverage.
  • Provide a built-in solution for developers to easily identify files without corresponding test files.
  • Reduce the need for external tools or custom scripts to perform this analysis.
  • Align Angular CLI with best practices for maintaining test coverage in Angular applications.

jest-angular-test-verifier npmjs: https://www.npmjs.com/package/jest-angular-test-verifier

Describe the solution you'd like

The proposed solution is to integrate the functionality of jest-angular-test-verifier or a similar tool into Angular CLI. This would involve creating a built-in mechanism that can analyze the project's file structure and identify files that do not have associated spec.ts files. The tool should offer configuration options to customize the file extensions to check, define exclusions, and set exclusion rules based on content.

Describe alternatives you've considered

While the proposed solution suggests integrating jest-angular-test-verifier directly into Angular CLI, an alternative approach could involve developing a dedicated and more sophisticated solution tailored to Angular projects. By leveraging the power and familiarity of Angular's codebase, the CLI team could create an integrated tool that offers more advanced features and optimizations for detecting missing spec.ts files. This approach could lead to a more seamless and tightly integrated experience for Angular developers.

I appreciate your consideration of this feature proposal and look forward to the possibility of seeing this enhancement added to Angular CLI. If you have any questions or need further details, please let me know. Thank you!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions