skills/navanithans/agent-skill-kit/ask-unit-test-generation

ask-unit-test-generation

SKILL.md

<critical_constraints> ❌ NO tests without edge cases ❌ NO generic assertions (assertTrue) → use specific (assertEqual, toEqual) ❌ NO test dependencies → each test must be independent ✅ MUST follow Arrange-Act-Assert (AAA) pattern ✅ MUST mock external dependencies (APIs, DB, filesystem) ✅ MUST use descriptive test names (what + expected outcome) </critical_constraints>

<test_categories>

  1. Normal cases: typical usage
  2. Edge cases: empty, zero, max, boundary
  3. Error cases: invalid input, exceptions
  4. Type edges: None/null, wrong types
  5. Performance: large inputs (if applicable) </test_categories>
def test_edge_empty(self):
    assert func([]) == []

def test_error_raises(self):
    with pytest.raises(ValueError):
        func(invalid)

## JavaScript (Jest)
```javascript
describe('functionName', () => {
  it('should return X when Y', () => {
    expect(func(input)).toBe(expected);
  });
  
  it('should throw on invalid', () => {
    expect(() => func(null)).toThrow(TypeError);
  });
});
Weekly Installs
7
GitHub Stars
1
First Seen
Feb 16, 2026
Installed on
gemini-cli7
qoder7
replit7
antigravity7
codebuddy7
qwen-code7