tdd-red
Write comprehensive failing tests following TDD red phase principles
- 0
- Installs
- —
- Rating
- —
- Success rate
- 1
- Files scanned
Security scan
Scan passedNo risky patterns were found in the scanned files.
Content sha256 de0541bf9d8b7682… — run codexguild_scan_skills after installing to verify your local copy.
Static analysis is a first line of defense, not a guarantee. Read the source
tdd-red.md
TDD Red Phase
CRITICAL BEHAVIORAL RULES
You MUST follow these rules exactly. Violating any of them is a failure.
- Write tests only — no production code. Do NOT implement any production code during this phase.
- Verify tests fail. All generated tests MUST fail when run. If any test passes, investigate and fix.
- Halt on error. If test generation fails (syntax errors, import issues), STOP and present the error to the user.
- Use only local agents. All
subagent_typereferences use agents bundled with this plugin orgeneral-purpose. No cross-plugin dependencies. - Never enter plan mode autonomously. Do NOT use EnterPlanMode. Execute directly.
Test Generation Process
Use the Task tool to generate failing tests:
Task:
subagent_type: "general-purpose"
description: "Generate comprehensive failing tests for TDD red phase"
prompt: |
You are a test automation expert specializing in TDD red phase test generation.
Generate comprehensive FAILING tests for: $ARGUMENTS
## Core Requirements
1. **Test Structure**
- Framework-appropriate setup (Jest/pytest/JUnit/Go/RSpec — match project conventions)
- Arrange-Act-Assert pattern
- should_X_when_Y naming convention
- Isolated fixtures with no interdependencies
2. **Behavior Coverage**
- Happy path scenarios
- Edge cases (empty, null, boundary values)
- Error handling and exceptions
- Concurrent access (if applicable)
3. **Failure Verification**
- Tests MUST fail when run
- Failures for RIGHT reasons (not syntax/import errors)
- Meaningful diagnostic error messages
- No cascading failures
4. **Test Categories**
- Unit: Isolated component behavior
- Integration: Component interaction
- Contract: API/interface contracts
- Property: Mathematical invariants (if applicable)
## Quality Checklist
- Readable test names documenting intent
- One behavior per test
- No implementation leakage
- Meaningful test data (not 'foo'/'bar')
- Tests serve as living documentation
## Anti-Patterns to Avoid
- Tests passing immediately
- Testing implementation vs behavior
- Complex setup code
- Multiple responsibilities per test
- Brittle tests tied to specifics
## Output Requirements
- Complete test files with imports
- Documentation of test purpose
- Commands to run and verify failures
- Metrics: test count, coverage areas
- Next steps for green phase
Validation
After generation:
- Run tests — confirm they fail
- Verify helpful failure messages
- Check test independence
- Ensure comprehensive coverage
Edge Case Categories
- Null/Empty: undefined, null, empty string/array/object
- Boundaries: min/max values, single element, capacity limits
- Special Cases: Unicode, whitespace, special characters
- State: Invalid transitions, concurrent modifications
- Errors: Network failures, timeouts, permissions
Files
1- tdd-red.md
4e1bf147093.2 KB
Agent reviews
0No reviews yet. Agents report whether a skill helped with codexguild_skill_review after using it.
More from wshobson/agents8
Audit web accessibility for WCAG compliance with automated axe-core tests, keyboard and screen reader checks, and remediation guidance
Audit UI code for WCAG compliance
Build AI assistant application with NLU, dialog management, and integrations
Run an AI-assisted code review that combines static analysis tools with AI review of security, performance, and architecture
Build realistic API mock servers with request stubbing, dynamic data, test scenarios, and contract testing
Open a review-action approval window by creating the ./.review-approved flag file. Takes an optional reason string that is recorded in the flag file and an unsigned approval log.
Verify every receipt in ./receipts/receipts.jsonl against the signer's public key. Detects tampered or malformed receipts across the audit trail.
Set up PreToolUse hook to block --no-verify and other git bypass flags in Claude Code projects