From long-task
Dispatches SubAgent to enforce coverage gate, mutation gate, and verification gates after TDD cycle in long-task projects before marking features passing.
npx claudepluginhub suriyel/longtaskforagent --plugin long-taskThis skill uses the workspace's default tool permissions.
Delegate quality gate execution to a SubAgent with fresh context. The main Agent only dispatches and parses the structured result — it never reads coverage reports, mutation output, or test runner output directly.
Orchestrates multi-session projects by implementing one feature per cycle from feature-list.json through TDD pipeline with quality gates and code review.
Executes Phase 4 test verification: checks receipt completeness, detects plan drift via git diff, auto-runs tests from package.json/pyproject.toml/Makefile, retries to implement on failure.
Runs mutation testing on test suites using stack-specific tools like Stryker (JS), Infection (PHP), Mutmut (Python), and go-mutesting (Go) to validate test quality. Use for verifying test effectiveness.
Share bugs, ideas, or general feedback.
Delegate quality gate execution to a SubAgent with fresh context. The main Agent only dispatches and parses the structured result — it never reads coverage reports, mutation output, or test runner output directly.
Announce at start: "I'm using the long-task-quality skill to run quality gates via SubAgent."
Build the prompt from current session state. Do NOT read any source code, test output, or coverage reports yourself.
You are a Quality Gates execution SubAgent.
## Your Task
1. Read the execution rules: Read {skills_root}/long-task-quality/references/quality-execution.md
2. Read long-task-guide.md in the project root for test/coverage/mutation commands and environment activation
3. Execute all 4 gates in order (Gate 0 → 1 → 2 → 3)
- **Note**: Static analysis tools (Design §13.4) are enforced during TDD Refactor, not here. If Design doc §13.7 documents code generation directories, exclude them from coverage measurement in Gate 1.
4. If a gate fails, fix and retry per the rules (max 3 attempts per gate)
5. Return your result using the Structured Return Contract at the end of the execution rules
## Input Parameters
- Feature ID: {feature_id}
- Feature: {feature_json}
- quality_gates thresholds: {quality_gates_json}
- tech_stack: {tech_stack_json}
- Working directory: {working_dir}
- Feature test files: {feature_test_files} (test files written/modified during TDD for this feature — used for mutation_feature scoping)
- Active feature count: {active_feature_count} (total non-deprecated features — compared against mutation_full_threshold to decide mutation scope)
## Key Constraint
- Do NOT mark the feature as "passing" in feature-list.json — only report results
- If a tool/environment error cannot be resolved after 1 retry, set Verdict to BLOCKED
Replace {skills_root} with the path to the skills directory (e.g., skills in the project or the installed plugin path).
Claude Code: Use the Agent tool:
Agent(
description = "Quality Gates for feature #{feature_id}",
prompt = [the constructed prompt above]
)
OpenCode: Use @mention syntax or the platform's native subagent mechanism with the same prompt content.
Read the SubAgent's returned text and locate the ### Verdict: line:
### Verdict: PASS
task-progress.md: "Quality Gates: PASS (line {X}%, branch {Y}%, mutation {Z}%)"### Verdict: FAIL
AskUserQuestion with the failure details### Verdict: BLOCKED
AskUserQuestion with the blocker details and what was attemptedCalled by: long-task-work (Step 8) Requires: TDD cycle completed (long-task-tdd passed — tests exist and pass) Produces: Structured summary (coverage %, mutation %, per-gate pass/fail) Chains to: long-task-feature-st (via Work Step 9)