auto-test-execution
FreeNo executable scriptsNot checkedAutomatically execute tests when code-generating agents modify source files, enforcing the execute-before-return pattern
by jmagly★ 233 GitHub starsAbout this skill
auto-test-execution
Automatically execute tests when code-generating agents write to source files, enforcing the execute-before-return pattern.
Triggers
Primary phrases matched automatically from skill description. No additional alternate expressions defined.
Purpose
This skill enforces the MetaGPT executable feedback pattern: code-generating agents must execute tests before returning results to the user. It activates automatically when agents modify source code files.
Behavior
When triggered, this skill:
Detect modified files:
- Track which source files the agent has written to
- Identify the relevant test framework
Find related tests:
- Look for test files matching the modified source
- Convention:
src/foo/bar.ts->test/unit/foo/bar.test.ts - If no tests exist, prompt agent to generate them
Execute tests:
- Run the project's test command focused on relevant tests
- Capture results: passed, failed, errors
Handle results:
- All pass: Allow agent to return results
- Failures: Trigger debug-and-retry loop (max 3 attempts)
- Persistent failures: Escalate with debug memory context
Update debug memory:
- Record session in
.aiwg/ralph/debug-memory/sessions/ - Extract patterns for future reference
- Record session in
Activation Conditions
activation:
always_active_for:
- software-implementer
- debugger
- test-engineer
triggered_by:
- file_write:
patterns:
- "src/**/*.ts"
- "src/**/*.js"
- "src/**/*.py"
- "**/*.go"
- "**/*.rs"
skip_when:
- test_files_only: true
- documentation_only: true
- configuration_only: true
Integration
This skill uses:
project-awareness: Detect test framework and configuration- Debug memory at
.aiwg/ralph/debug-memory/for pattern learning
References
- @$AIWG_ROOT/agentic/code/frameworks/sdlc-complete/rules/executable-feedback.md - Feedback rules
- @$AIWG_ROOT/agentic/code/addons/agent-loop/docs/executable-feedback-guide.md - Guide
- @$AIWG_ROOT/agentic/code/addons/agent-loop/schemas/debug-memory.yaml - Memory schema
- @.aiwg/research/findings/REF-013-metagpt.md - Research foundation
Install auto-test-execution in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
FAQ
What does the auto-test-execution skill do?
Automatically execute tests when code-generating agents modify source files, enforcing the execute-before-return pattern
How do I install the auto-test-execution skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the auto-test-execution skill run scripts?
No, this skill is instructions only (SKILL.md) with no executable scripts.
Related skills
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
by Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
by Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
by Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
by Anthropic