60-test-coverage

Enforce test coverage and lint checks on changed code with npm scripts.

Updated Jan 30, 2025
One-click install
npx skills add https://github.com/MykhailoDmytriakha/my-preacher-helper --skill 60-test-coverage
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: 60-test-coverage
Source: https://github.com/MykhailoDmytriakha/my-preacher-helper/tree/main/.codex/skills/60-test-coverage
Command: npx skills add https://github.com/MykhailoDmytriakha/my-preacher-helper --skill 60-test-coverage

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides a strict workflow to ensure all changed code paths are tested and linted, preventing regressions and guaranteeing code quality before merging.

Core Features & Use Cases

  • Phase-based approach guiding: identify changed files, measure baseline coverage, add regression tests, and re-lint until green.
  • Generates a final report comparing baseline vs final coverage and lists uncovered changed lines for remediation.
  • Works with root-level npm scripts: test:coverage and lint:full to ensure end-to-end quality.

Quick Start

Run the full validation sequence in the root to verify test coverage and lint are green.

Frequently Asked Questions about 60-test-coverage

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce a minimum 80% Jest test coverage threshold for changed TypeScript files?

To enforce test coverage for changed TypeScript files, you need a workflow that identifies changed paths, measures baseline coverage, and blocks merges until the 80% threshold is met. This skill automates that exact phase-based enforcement process.

How does a CI workflow prevent regressions by checking test coverage on changed code?

A CI workflow prevents regressions by measuring baseline coverage, recommending regression tests for uncovered changed lines, and re-linting until checks pass. This skill generates a final report comparing baseline versus final coverage for remediation.

Can I use this test coverage enforcement skill with my existing GitHub and npm scripts?

Yes, this test coverage enforcement works with existing GitHub workflows and requires root-level npm scripts for test:coverage and lint:full to ensure end-to-end quality validation before merging code changes.

What is the best way to document required test coverage thresholds and report uncovered lines?

The best way to document required test coverage thresholds is through an automated phase-based workflow that reports uncovered changed lines for remediation. This skill provides baseline measurement, regression test recommendations, and final reporting.

Why does my test coverage enforcement fail when lint checks are not green?

Test coverage enforcement fails when lint checks are not green because strict quality assurance requires both testing and linting to pass. This skill ensures all changed code paths are tested and linted, running re-lint phases until validation succeeds.