Mandatory Testing & Linting Guard

Enforce npm test and npm run lint after every code change.

6|2|Updated Jul 29, 2025
One-click install
npx skills add https://github.com/spartDev/My-Prompt-Manager --skill mandatory-testing-linting-guard
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Mandatory Testing & Linting Guard
Source: https://github.com/spartDev/My-Prompt-Manager/tree/main/.claude/skills/test-lint-guard
Command: npx skills add https://github.com/spartDev/My-Prompt-Manager --skill mandatory-testing-linting-guard

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill enforces critical code quality standards by ensuring that npm test and npm run lint are executed and pass after every single code modification. It prevents regressions, maintains high code quality, and ensures compliance with project standards, eliminating the risk of "small changes" breaking the build.

Core Features & Use Cases

  • Mandatory Execution: Explicitly requires running npm test and npm run lint after every code change, enforcing a strict quality gate.
  • Comprehensive Test Suite Overview: Provides insights into the project's 875+ tests, coverage, and testing frameworks for informed development.
  • Troubleshooting & Auto-Fix Strategies: Offers solutions for common test failures, linting issues, and low code coverage, including npm run lint:fix and coverage-driven testing.
  • Use Case: A developer has just implemented a new feature. Before committing, this Skill reminds them to run all tests and lint checks, guiding them through fixing any failures to ensure the new code integrates flawlessly and adheres to project standards.

Quick Start

I've just finished making code changes. Guide me through the mandatory testing and linting process to ensure code quality before I commit.

Frequently Asked Questions about Mandatory Testing & Linting Guard

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

FAQPage Schema
How do I enforce testing and linting on every code change?

Enforce testing and linting by running `npm test` and `npm run lint` after every code modification. This Skill ensures both commands execute and pass before you commit, preventing regressions and maintaining code quality standards across TypeScript, JavaScript, CSS, and configuration files.

What happens if tests or linting checks fail?

Failed tests or linting checks block progression and report clear FAIL outcomes. The Skill provides troubleshooting guidance and auto-fix strategies, including `npm run lint:fix` for linting issues and coverage-driven testing approaches to resolve failures before committing.

Can I use this workflow with pre-commit and pull request checks?

Yes. This Skill integrates with pre-commit hooks and CI/PR checks to enforce mandatory test and lint validation. It prevents deployment of non-compliant changes by gating progression on passing both `npm test` and `npm run lint` at each workflow stage.

Does this Skill cover all file types in my project?

This Skill applies to all code edits including TypeScript, JavaScript, CSS, component updates, service modifications, and configuration file changes. It enforces the same testing and linting requirements comprehensively across your entire npm-based project.

How do I understand my project's test coverage?

This Skill provides comprehensive insights into your project's 875+ tests, coverage metrics, and testing frameworks. It helps you identify coverage gaps and guides test-driven approaches to improve code quality and compliance with project standards.

What's the fastest way to fix linting errors before committing?

Run `npm run lint:fix` to automatically resolve fixable linting issues. This Skill guides you through identifying, fixing, and verifying that both tests pass and lint checks succeed before you proceed with committing changes.