tdd
SolidEnforce test-driven development — write tests FIRST, then implement. Mandatory for new features and bug fixes.
Testing & QA 55 stars
28 forks Updated today MIT
Install
Quality Score: 85/100
Stars 20%
Recency 20%
Frontmatter 20%
Documentation 15%
Issue Health 10%
License 10%
Description 5%
Skill Content
# TDD — Test-Driven Development (Enforced)
**This is not a suggestion. This is the workflow.**
When adding features or fixing bugs in claude-code-discord-bridge, you MUST write tests before writing implementation code. No exceptions.
## When to Activate
- Adding any new feature or functionality
- Fixing a bug (write a test that reproduces the bug FIRST)
- Refactoring code (ensure existing tests pass, add missing ones)
- Adding a new Cog, parser rule, UI component, or database operation
## The Cycle: RED → GREEN → REFACTOR
### Step 1: RED — Write Failing Tests
Write tests that describe the desired behavior. Run them. **They must fail.**
```bash
uv run pytest tests/test_new_feature.py -v
# Expected: FAILED (because the code doesn't exist yet)
```
If tests pass before you write any implementation, your tests are wrong.
### Step 2: GREEN — Write Minimal Implementation
Write the **minimum code** to make the tests pass. No more.
```bash
uv run pytest tests/test_new_feature.py -v
# Expected: PASSED
```
### Step 3: REFACTOR — Clean Up
Improve the implementation while keeping all tests green. Then run the full suite:
```bash
uv run pytest tests/ -v --cov=claude_discord --cov-report=term-missing
```
### Step 4: VERIFY — Lint + Format + Full Suite
```bash
uv run ruff check claude_discord/
uv run ruff format claude_discord/
uv run pytest tests/ -v --cov=claude_discord
```
## What to Test First (by module type)
### New Parser Rule
```python
# tests/test_parser.py — Wri...
Details
- Author
- ebibibi
- Repository
- ebibibi/ebi-agent-chat-relay
- Created
- 6 months ago
- Last Updated
- today
- Language
- Python
- License
- MIT
Integrates with
Similar Skills
Semantically similar based on skill content — not just same category
Testing & QA Listed
test-driven-development
Use when implementing any feature or bugfix, before writing implementation code
2 Updated yesterday
vijaysai1102 Testing & QA Listed
test-driven-development
Use when implementing any feature or bugfix, before writing implementation code
0 Updated today
iamtatsuki05 Testing & QA Listed
test-driven-development
Use when implementing any feature or bugfix, before writing implementation code
0 Updated 2 days ago
RubyEyedReaper