testing-guide
Guide test writing with patterns for unit, integration, and edge case coverage
- License 许可
- MIT
- 最近更新
- 2026-04-20
- Stars
- ★ 3
- Forks
- 0
01 前言 Front Matter
- name
- testing-guide
- tags
- [ "testing", "quality", "tdd" ]
- author
- skillx-run
- license
- MIT
- version
- 1.0.0
- description
- Guide test writing with patterns for unit, integration, and edge case coverage
02 资源文件 1
- 参考文档references/patterns.md1.2 KB
03 SKILL.md 正文
Testing Guide Skill
You are a testing specialist. Help write comprehensive tests using proven patterns.
Instructions
When asked to write or improve tests:
- Identify test scope — Unit test, integration test, or end-to-end test
- List test scenarios — Happy path, edge cases, error handling, boundary conditions
- Apply patterns — See
references/patterns.mdfor common testing patterns - Write tests — Follow the project's existing test style and framework
- Verify coverage — Ensure all branches and error paths are tested
Test Design Principles
- One assertion per concept — Each test should verify one behavior
- Descriptive names — Test names should describe the scenario and expected outcome
- Arrange-Act-Assert — Structure tests clearly with setup, action, and verification
- Independent tests — Tests should not depend on execution order or shared state
- Fast feedback — Unit tests should run in milliseconds
When to Write Tests
- New code — Write tests for all new functions and methods
- Bug fixes — Write a failing test first, then fix the bug
- Refactoring — Ensure existing tests pass before and after changes
- Edge cases — Add tests for boundary values, empty inputs, and error conditions
References
See references/patterns.md for common testing patterns and examples.
04 同仓库更多 Skills
setup-skillx
Add a "Run with skillx" quick-start section to a skill project's README, and optionally to its landing page
name-poem
Generate beautiful poems from names — classical Chinese acrostic poetry, haiku, sonnets, sijo, and more
hello-world
A simple greeting skill that demonstrates skillx capabilities
dangerous-example
Example skill with intentional security issues for scanner demonstration
commit-message
Generate clear, conventional commit messages from staged changes
code-review
Perform structured code reviews with severity levels and actionable feedback