targeted-regression-test-workflow

Runs minimal regression tests targeting changed files and verifies builds.

Updated Jul 21, 2026
One-click install
npx skills add https://github.com/masakinihirota/2026src-ni --skill targeted-regression-test-workflow-masakinihirota
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: targeted-regression-test-workflow
Source: https://github.com/masakinihirota/2026src-ni/tree/main/.agents/skills/targeted-regression-test-workflow
Command: npx skills add https://github.com/masakinihirota/2026src-ni --skill targeted-regression-test-workflow-masakinihirota

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Running the full test suite after every small fix wastes time and slows iteration. This Skill narrows testing to the files directly affected by a change, so regressions are caught quickly without redundant test runs. ## Core Features & Use Cases - Targeted Test Selection: Prioritizes tests in the same directory as changed files, then adds boundary tests via public APIs. - Two-Stage Execution Templates: Provides pnpm/vitest command templates for running change-related tests first, then related boundary tests, finishing with a build check. - RED-GREEN Discipline: Enforces confirming a failing test before fixing, and prohibits blind full-suite reruns. - Use Case: After fixing a bug in a React component, run only that component's test file plus one boundary test, confirm both pass, then run pnpm build to verify overall integrity. ## Quick Start Ask the agent to apply the targeted regression test workflow to verify your recent code changes with minimal test runs.

Frequently Asked Questions about targeted-regression-test-workflow

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

FAQPage Schema
How do I run only tests related to my code changes?▼

Run the test file in the same directory as the changed file first, using a command like pnpm test:run -- path/to/changed-feature.test.tsx. Then add one related boundary test to cover the feature's public API surface.

How to run a single test file with vitest and pnpm?▼

Use pnpm test:run -- followed by the test file path, for example pnpm test:run -- src/components/debug-links/debug-links-page.test.tsx. This executes only that file instead of the entire suite.

When should I avoid running the full test suite?▼

Avoid full-suite runs for small, well-scoped bug fixes where the impact area is clear and full runs are too slow. Targeted tests plus a final build check provide adequate safety in these cases.

Why confirm a failing test before fixing a bug?▼

Confirming the RED state proves the test actually reproduces the bug, so the fix is verified by a real GREEN transition. Fixing without a failing test risks shipping an unverified change.

What defines completion for a targeted regression test workflow?▼

Completion requires the change-related test passing, one related boundary test passing, a successful build, and clear separation between known warnings and any new warnings introduced by the change.